GNOME Bugzilla – Bug 404571
Scroll arrow backgrounds should be painted with different detail
Last modified: 2008-05-28 01:31:10 UTC
Painting the scroll arrow backgrounds with the same details as the menu background confuses the theming as there's no way to distinguish between the two paintings in gtkrc (all parameters except coordinates are the same.) As a result the menu looks really bad with pixmap engine when you try to paint a nice border around the menu. The arrows background should be painted with different detail parameter.
Created attachment 81923 [details] [review] proposed patch * gtk/gtkmenu.c (gtk_menu_paint): Paint the scroll arrow backgrounds using 'menu_scroll_arrow_up' and 'menu_scroll_arrow_down' details instead of generic 'menu'
shouldn't "menu-scroll-arrow" be good enough, considering the up/down is already provided for the direction of the arrow ? Also, have you verified that this does not cause regressions with exisiting theme engines ?
(In reply to comment #2) > shouldn't "menu-scroll-arrow" be good enough, considering the up/down is > already provided for the direction of the arrow ? Not really as the arrow direction is not known while painting the background. Of course one could do interesting hacks based on coordinates inside the theme engine, but that would be awkward. > Also, have you verified that this does not cause regressions with exisiting > theme engines ? Unfortunately no.
I think we should just live with this possible minor breakage of theme engines, it's IMHO less worse than the current state where the theme engine has no chance whatsoever to draw the buttons differently from the menu's main background box.
Patch 81923 doesn't apply cleanly. Reviewing it would take little time. (Working on http://mail.gnome.org/archives/gtk-devel-list/2007-March/msg00148.html)
Created attachment 111275 [details] [review] New diff against trunk The original patch indeed doesn't apply on trunk. This is a new diff wit the same changes. I share the opinion that this little change won't do much harm while it helps theme authors.
Ok, given the fact that scrolling menus are relatively rare (and basically a ui glitch whenever they occur), I'm not going to consider minor theme breakage to be a problem.
Bug 404571 – Scroll arrow backgrounds should be painted with different detail * gtk/gtkmenu.c (gtk_menu_paint): Use "menu_scroll_arrow_up/down" as detail when drawing scroll arrow backgrounds. Proposed by Tommi Komulainen.