/* Anaconda gtk style overrides */ /* Define styles to apply to the GtkLevelBar widgets for different values. * * This stylesheet defines properties for "low", "medium" and "high" level bar * levels. The level bars themselves need to define what style applies at what * value using gtk_level_bar_add_offset_value. Gtk defines "low" and "high" by * default, but it defines them for level bars using a continuous value between * 0 and 1, so our discrete level bars are effectively always at the "high" * level. * * Fun surprises that might change in future versions: * * - Defining properties for a level will set properties on both the filled * portion and the empty portion of the level bar. So if all of the display * properties are set, which we do, the level bar effectively becomes 100% * filled with whatever properties are set. Copying the .empty-fill-block * properties from the theme so that they apply at the application level * works around this. * * - There's a bug in the handling of the maximum offset in that it only * applies when value == max-value, rather than when it's between * max-value and the next lower offset. For example, consider a * discrete-mode level bar with a max-value of 4 and offsets defined as * "low": 2.0, "medium": 3.0 and "high": 4.0. Value 1 will be low, * value 2 will be medium, value 3 will be in an undefined no-man's land, * and value 4 will be high. To get around this we re-define the default * fill-block values as the same as fill-block.level-high. * * - The GNOME Adwaita theme applies a gradient to the progress bar when the * window is focused. It does this by redefining the colors in a * background-image property, so unless we reset background-image our colors * will only apply when the window is out of focus, which uses the :backdrop * selector. */ @define-color anaconda_level_bar_low red; @define-color anaconda_level_bar_medium orange; @define-color anaconda_level_bar_high green; .level-bar.fill-block.level-low { border-color: darker(@anaconda_level_bar_low); background-color: @anaconda_level_bar_low; background-image: none; } .level-bar.fill-block.level-medium { border-color: darker(@anaconda_level_bar_medium); background-color: @anaconda_level_bar_medium; background-image: none; } .level-bar.fill-block, .level-bar.fill-block.level-high { border-color: darker(@anaconda_level_bar_high); background-color: @anaconda_level_bar_high; background-image: none; } .level-bar.fill-block.empty-fill-block { background-color: transparent; background-image: none; border-color: alpha(#000000, 0.1); } /* As of gnome-themes-standard 3.9.90, the Adwaita theme uses the same color * for all GtkInfoBars regardless of the MessageType. * (https://bugzilla.gnome.org/show_bug.cgi?id=704266, commit 6bfa3aa0). The * colors were actually kind of ok, and also the new colors are borderline * unreadable, so these rules revert that change and set different colors. */ @define-color info_fg_color black; @define-color info_bg_color rgb (252, 252, 189); @define-color warning_fg_color black; @define-color warning_bg_color rgb (250, 173, 61); @define-color question_fg_color white; @define-color question_bg_color rgb (138, 173, 212); @define-color error_fg_color white; @define-color error_bg_color rgb (237, 54, 54); .info { background-color: @info_bg_color; color: @info_fg_color; border-color: darker(@info_bg_color); } .warning { background-color: @warning_bg_color; color: @warning_fg_color; border-color: darker(@warning_bg_color); } .question { background-color: @question_bg_color; color: @question_fg_color; border-color: darker(@question_bg_color); } .error { background-color: @error_bg_color; color: @error_fg_color; border-color: darker(@error_bg_color); } .info, .warning, .question, .error { text-shadow: none; }