Comment #5 on issue 6133 by [email protected]: Chrome search history results not formatted correctly for RTL locales http://code.google.com/p/chromium/issues/detail?id=6133
Following is the root cause analysis: Basically, the problem is in SnippetRenderer::ProcessRun(), when snippet word is drawn by calling canvas->DrawStringInt(), the X-axis should be mirrored. Instead of "x + total_width", the X-axis should be "MirroredXCoordinateInsideView(x + total_width) - width" to work correctly for pure Hebrew snippets. But there is a bit complication on this issue. 1. We need to correctly handle a snippet with mixture of LTR/RTL words. 2. We need to handle RTL snippet or mixture of LTR/RTL snippet correctly in LTR locales as well. (Currently, we do not. I assume we should display the Hebrew snippet in RTL order even in English Chrome). For example, a snippet containing the following words (in logical order, e stands for English word, h stands for Hebrew word): e1 e2 h1 h2 e3 e4 h3 h4 In RTL locale, the correct visual order should be: h4 h3 e3 e4 h2 h1 e1 e2 In LTR locale, the correct visual order should be: e1 e2 h2 h1 e3 e4 h4 h3 So, I am thinking, within SnippetRenderer::ProcessRun(), instead of drawing snippet piece by piece, it would be better to construct the snippet visual order first, and draw the whole snippet at once without adjust X-axis. -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings --~--~---------~--~----~------------~-------~--~----~ Automated mail from issue updates at http://crbug.com/ Subscription options: http://groups.google.com/group/chromium-bugs -~----------~----~----~----~------~----~------~--~---
