GNOME Bugzilla – Bug 96631
Support RTL flipping for option menus
Last modified: 2011-02-04 16:11:52 UTC
the arrow should be on the other side in RTL mode.
Moving all the RTL flipping bugs to the 2.4.0 milestone; in some cases the changes should be easy to do. (GtkPaned comes to mind) In those cases, we can move the bugs back to 2.2.0 if patches occur.
This one was relatively easy as well, but it turns out that a paint function has to be changed (gtk_paint_box (..."optionmenu"...)). I guess that means that existing theme engines will need some RTL love after this change, but thats probably ok.
Created attachment 11795 [details] [review] patch
Created attachment 11902 [details] [review] Here is the corresponding patch for gtk-engines
I very much doubt that current theme engines are RTL-clean even for the current flipping, so I don't mind adding a bit more. Patch looks fine.
Hmm, drawing seems to be a bit misaligned with the default theme.
This is because the default indicator_spacing is asymmetric. It has left == 7 and right == 5. Seeing that almost all of gtkoptionmenu.c depends only on the sum of the two, I tried to change them to 6 and 6, but that unfortunately causes both rtl and ltr to come out slightly misaligned. The following "obviously wrong" patch looks ok with the default spacing.
Created attachment 12080 [details] [review] wrong fix
Chunky seems reasonable to me ... it's a little funky to flip the indicator spacing, but clearly right since the indicator spacing is defined in terms of the relationship of the indicator to other elements of the optionmenu.
In case it isn't clear "Chunky" was meant to be "Patch". I think it's some sort of bizarre blend of the "funky" that I used later in the sentence and "Chunk" as a synonym for "Patch".
Committed the chunky to HEAD now...