forked from AuroraMiddleware/gtk
Make expanders prelight
This commit is contained in:
parent
8b6112b6e0
commit
21a193ad02
@ -3436,6 +3436,10 @@ gtk_css_provider_get_default (void)
|
||||
" color: @selected_fg_color;\n"
|
||||
"}\n"
|
||||
"\n"
|
||||
".expander:prelight {\n"
|
||||
" color: @selected_fg_color\n"
|
||||
"}\n"
|
||||
"\n"
|
||||
"*:insensitive {\n"
|
||||
" background-color: shade (@bg_color, 0.9);\n"
|
||||
" color: shade (@bg_color, 0.7);\n"
|
||||
|
@ -3215,6 +3215,8 @@ gtk_default_draw_expander (GtkStyle *style,
|
||||
if (detail)
|
||||
transform_detail_string (detail, context);
|
||||
|
||||
gtk_style_context_add_class (context, "expander");
|
||||
|
||||
switch (state_type)
|
||||
{
|
||||
case GTK_STATE_PRELIGHT:
|
||||
|
@ -1748,7 +1748,7 @@ gtk_theming_engine_render_expander (GtkThemingEngine *engine,
|
||||
gdouble height)
|
||||
{
|
||||
GtkStateFlags flags;
|
||||
GdkRGBA *bg_color, *fg_color;
|
||||
GdkRGBA *outline_color, *fg_color;
|
||||
double vertical_overshoot;
|
||||
int diameter;
|
||||
double radius;
|
||||
@ -1764,7 +1764,9 @@ gtk_theming_engine_render_expander (GtkThemingEngine *engine,
|
||||
|
||||
gtk_theming_engine_get (engine, flags,
|
||||
"color", &fg_color,
|
||||
"background-color", &bg_color,
|
||||
NULL);
|
||||
gtk_theming_engine_get (engine, 0,
|
||||
"color", &outline_color,
|
||||
NULL);
|
||||
|
||||
line_width = 1;
|
||||
@ -1834,13 +1836,13 @@ gtk_theming_engine_render_expander (GtkThemingEngine *engine,
|
||||
|
||||
cairo_fill_preserve (cr);
|
||||
|
||||
gdk_cairo_set_source_rgba (cr, fg_color);
|
||||
gdk_cairo_set_source_rgba (cr, outline_color);
|
||||
cairo_stroke (cr);
|
||||
|
||||
cairo_restore (cr);
|
||||
|
||||
gdk_rgba_free (fg_color);
|
||||
gdk_rgba_free (bg_color);
|
||||
gdk_rgba_free (outline_color);
|
||||
}
|
||||
|
||||
static void
|
||||
|
Loading…
Reference in New Issue
Block a user