mirror of https://github.com/daleclack/My_GtkUi
Add style for dock
This commit is contained in:
parent
90fe34c940
commit
e28b4ca062
|
@ -15,6 +15,10 @@
|
|||
background-color: alpha(white, 0.5);
|
||||
}
|
||||
|
||||
.dock_style box{
|
||||
background-color: alpha(white, 0.5);
|
||||
}
|
||||
|
||||
/* Background color in the box should be transparent*/
|
||||
.default_style box{
|
||||
background-color: transparent;
|
||||
|
|
|
@ -148,6 +148,18 @@ static void my_dock_init(MyDock *self)
|
|||
GTK_STYLE_PROVIDER(provider),
|
||||
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
|
||||
// Add Style to the Dock
|
||||
gtk_widget_add_css_class(self->dock_left, "dock_style");
|
||||
gtk_style_context_add_provider_for_display(gtk_widget_get_display(self->dock_left),
|
||||
GTK_STYLE_PROVIDER(provider),
|
||||
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
|
||||
// The widget in the dock should use default style
|
||||
gtk_widget_add_css_class(self->dock_box, "default_style");
|
||||
gtk_style_context_add_provider_for_display(gtk_widget_get_display(self->dock_box),
|
||||
GTK_STYLE_PROVIDER(provider),
|
||||
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
|
||||
// Pack widgets
|
||||
// Dock position and mode, will be changable soon
|
||||
gtk_widget_set_vexpand(self->icons_sw, TRUE);
|
||||
|
|
Loading…
Reference in New Issue