GNOME Bugzilla – Bug 719861
Menu separators aren't selectable independently from the widget's border
Last modified: 2013-12-05 11:51:56 UTC
GtkMenuItem draws its separator using gtk_render_frame() with the same style context configuration that GtkWidget uses to draw the widget's frame. Thus, setting a border for ".menuitem.separator" results in a border style for both the widget and the separator itself. The attached patch is a proposed solution: to add a widget region "separator-line" with which the separator itself is drawn. I don't know if this is the best solution thouhg, or if widget regions were even meant for this purpose.
Created attachment 263525 [details] [review] Add "separator-line" widget region A region used by GtkMenuItem to make its separator line distinguishable from the widget's normal border in css.
Created attachment 263579 [details] [review] GtkMenuItem: only set 'separator' class on the separator line To make the separator line distinguishable from the widget's normal border from css.
Comment on attachment 263579 [details] [review] GtkMenuItem: only set 'separator' class on the separator line Looks good.
Comment on attachment 263579 [details] [review] GtkMenuItem: only set 'separator' class on the separator line Attachment 263579 [details] pushed as d736e8b - GtkMenuItem: only set 'separator' class on the separator line