Abdelrazak Younes wrote:
On 12/10/2008 21:24, Vincent van Ravesteijn wrote:
Vincent van Ravesteijn wrote:
This patch solves some problems with painting selections in Insets.
These are:
- multiline selections paint in left margin of the main text
(bug 5270),
- the margins to the left and right side of the inset are not correct,
- wrong painting of e.g. a multiline selection of a caption in a
float.

I renamed the Row::left_margin_sel back to Row::begin_margin_sel
because
of RTL text.


Is there yet a verdict for this patch ?

+    if (row.end_margin_sel) {
         if (text_->isRTL(buffer, beg.paragraph())) {
-            int rm = bv_->rightMargin();
- pi.pain.fillRectangle(x + rm, y1, x2 - rm, y2 - y1, Color_selection);
+            pi.pain.fillRectangle(x + lm, y1, x2 - lm, y2 - y1,
+                Color_selection);
         } else {
-            int lm = bv_->leftMargin();
- pi.pain.fillRectangle(x + x2, y1, width() - lm - x2, y2 - y1, Color_selection);
+            pi.pain.fillRectangle(x + x2, y1, width() - rm - x2, y2 - y1,
+                Color_selection);


Are you sure? You just replaced left with right and right with left here...

Otherwise the patch is just renaming and cosmetics so, provided that you explain the above, I am OK with the patch. Putting Dov in copy so that he is aware of your activity.

Abdel

Hi!

I'm not familiar enough with the painting code in order to be able to provide any intelligent input. Best I can do at the moment is just to test this to make sure that it works correctly also for RTL text. What exactly should I look at?

Thanks for keeping me posted, though! I'm still lurking on the list, but I've just been very busy lately, and don't have much LyX-time...

Dov

Reply via email to