The Birdfont Source Code


All Repositories / birdfont.git / commit – RSS feed

High contrast theme

These changes was commited to the Birdfont repository Mon, 20 Apr 2015 12:23:24 +0000.

Contributing

Send patches or pull requests to johan.mattsson.m@gmail.com.
Clone this repository: git clone https://github.com/johanmattssonm/birdfont.git
author Johan Mattsson <johan.mattsson.m@gmail.com>
Mon, 20 Apr 2015 12:23:24 +0000 (14:23 +0200)
committer Johan Mattsson <johan.mattsson.m@gmail.com>
Mon, 20 Apr 2015 12:23:24 +0000 (14:23 +0200)
commit 7fbbbb9c41705250dbca77e9589015c26737af67
tree 61f980ff196e1f59b2350551eb582cdbed5df69b
parent 88845067eaf37421e012490827b51e19ea77d343
High contrast theme

libbirdfont/LabelTool.vala
libbirdfont/TabBar.vala
libbirdfont/Theme.vala
resources/dark.theme
resources/high_contrast.theme
--- a/libbirdfont/LabelTool.vala +++ b/libbirdfont/LabelTool.vala @@ -114,7 +114,7 @@ if (has_delete_button) { cr.save (); - Theme.color (cr, "Foreground Inverted"); + Theme.color (cr, "Text Foreground"); cr.set_line_width (1); cr.move_to (w - 20, y + h / 2 - 2.5 + 2); cr.line_to (w - 25, y + h / 2 + 2.5 + 2);
--- a/libbirdfont/TabBar.vala +++ b/libbirdfont/TabBar.vala @@ -758,7 +758,7 @@ close_opacity = (over_close_tab == tab_index) ? 1 : 0.2; if (tab_index == selected) { - Theme.color_opacity (cr, "Foreground 1", close_opacity); + Theme.color_opacity (cr, "Selected Tab Foregrund", close_opacity); } else { Theme.color_opacity (cr, "Text Foreground", close_opacity); } @@ -784,7 +784,7 @@ center_y = (int) (tab_height / 2.0 + 4 / scale); if (tab_index == selected) { - Theme.text_color (label, "Selected Tab Foreground"); + Theme.text_color (label, "Selected Tab Foregrund"); } else { Theme.text_color (label, "Text Tab Bar"); }
--- a/libbirdfont/Theme.vala +++ b/libbirdfont/Theme.vala @@ -306,7 +306,112 @@ current_theme = "generated_dark_theme.theme"; write_theme (); } + + // Bright theme + Theme.set_default_color ("Canvas Background", 1, 1, 1, 1); + Theme.set_default_color ("Stroke Color", 0, 0, 0, 1); + Theme.set_default_color ("Handle Color", 0, 0, 0, 1); + Theme.set_default_color ("Fill Color", 0, 0, 0, 1); + Theme.set_default_color ("Selected Objects", 0, 0, 0, 1); + Theme.set_default_color ("Background 1", 1, 1, 1, 1); + Theme.set_default_color ("Dialog Background", 1, 1, 1, 1); + Theme.set_default_color ("Menu Background", 1, 1, 1, 1); + Theme.set_default_color ("Default Background", 1, 1, 1, 1); + Theme.set_default_color ("Headline Background", 0, 0, 0, 1); + + Theme.set_default_color ("Checkbox Background", 1, 1, 1, 1); + + Theme.set_default_color ("Foreground 1", 0, 0, 0, 1); + + Theme.set_default_color ("Text Foreground", 0, 0, 0, 1); + Theme.set_default_color ("Text Tool Box", 0, 0, 0, 1); + Theme.set_default_color ("Text Tab Bar", 0, 0, 0, 1); + Theme.set_default_color ("Selected Tab Foregrund", 1, 1, 1, 1); + Theme.set_default_color ("Menu Foreground", 0, 0, 0, 1); + + Theme.set_default_color ("Table Border", 0, 0, 0, 1); + Theme.set_default_color ("Selection Border", 0, 0, 0, 1); + Theme.set_default_color ("Overview Glyph", 0, 0, 0, 1); + + Theme.set_default_color ("Table Background 1", 1, 1, 1, 1); + Theme.set_default_color ("Table Background 2", 1, 1, 1, 1); + + Theme.set_default_color ("Tab Separator", 0, 0, 0, 1); + + Theme.set_default_color ("Foreground Inverted", 1, 1, 1, 1); + + Theme.set_default_color ("Highlighted 1", 0, 0, 0, 1); + + Theme.set_default_color ("Highlighted Guide", 0, 0, 0, 1); + Theme.set_default_color ("Guide 1", 0, 0, 0, 1); + Theme.set_default_color ("Guide 2", 0, 0, 0, 1); + Theme.set_default_color ("Guide 3", 0, 0, 0, 1); + + Theme.set_default_color ("Grid", 0, 0, 0, 1); + + Theme.set_default_color ("Background Glyph", 0.2, 0.2, 0.2, 0.5); + + Theme.set_default_color ("Button Border 1", 0, 0, 0, 1); + Theme.set_default_color ("Button Background 1", 0, 0, 0, 1); + + Theme.set_default_color ("Button Border 2", 0, 0, 0, 1); + Theme.set_default_color ("Button Background 2", 0, 0, 0, 1); + + Theme.set_default_color ("Button Border 3", 0, 0, 0, 1); + Theme.set_default_color ("Button Background 3", 1, 1, 1, 1); + + Theme.set_default_color ("Button Border 4", 0, 0, 0, 1); + Theme.set_default_color ("Button Background 4", 1, 1, 1, 1); + + Theme.set_default_color ("Button Foreground", 0, 0, 0, 1); + Theme.set_default_color ("Selected Button Foreground", 1, 1, 1, 1); + + Theme.set_default_color ("Tool Foreground", 0, 0, 0, 1); + Theme.set_default_color ("Selected Tool Foreground", 1, 1, 1, 1); + + Theme.set_default_color ("Text Area Background", 1, 1, 1, 1); + + Theme.set_default_color ("Overview Item Border", 0, 0, 0, 1); + + Theme.set_default_color ("Selected Overview Item", 0, 0, 0, 1); + Theme.set_default_color ("Overview Item 1", 1, 1, 1, 1); + Theme.set_default_color ("Overview Item 2", 1, 1, 1, 1); + + Theme.set_default_color ("Overview Selected Foreground", 1, 1, 1, 1); + Theme.set_default_color ("Overview Foreground", 0, 0, 0, 1); + + Theme.set_default_color ("Glyph Count Background 1", 1, 1, 1, 1); + Theme.set_default_color ("Glyph Count Background 2", 1, 1, 1, 1); + + Theme.set_default_color ("Dialog Shadow", 0, 0, 0, 1); + + Theme.set_default_color ("Selected Active Cubic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Selected Cubic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Active Cubic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Cubic Control Point", 0, 0, 0, 1); + + Theme.set_default_color ("Selected Active Quadratic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Selected Quadratic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Active Quadratic Control Point", 0, 0, 0, 1); + Theme.set_default_color ("Quadratic Control Point", 0, 0, 0, 1); + + Theme.set_default_color ("Selected Control Point Handle", 0, 0, 0, 1); + Theme.set_default_color ("Active Control Point Handle", 0, 0, 0, 1); + Theme.set_default_color ("Control Point Handle", 0, 0, 0, 1); + + Theme.set_default_color ("Merge", 0, 0, 0, 1); + + Theme.set_default_color ("Spin Button", 0, 0, 0, 1); + Theme.set_default_color ("Active Spin Button", 0, 0, 0, 1); + Theme.set_default_color ("Zoom Bar Border", 0, 0, 0, 1); + Theme.set_default_color ("Font Name", 0, 0, 0, 1); + + if (BirdFont.has_argument ("--test")) { + current_theme = "generated_high_contrast.theme"; + write_theme (); + } + if (BirdFont.has_argument ("--test")) { t_("Canvas Background"); t_("Stroke Color");
--- a/resources/dark.theme +++ b/resources/dark.theme @@ -25,7 +25,7 @@ <color name="Selected Tool Foreground" red="0.4823529411764706" green="0.49803921568627452" blue="0.51764705882352946" alpha="1"/> <color name="Selected Control Point Handle" red="0" green="0" blue="0" alpha="1"/> <color name="Font Name" red="0.91764705882352937" green="0.30196078431372547" blue="0.10196078431372549" alpha="1"/> - <color name="Button Foreground" red="0.41960784313725491" green="0.4392156862745098" blue="0.47843137254901963" alpha="1"/> + <color name="Button Foreground" red="1" green="1" blue="1" alpha="1"/> <color name="Grid" red="0.20000000000000001" green="0.59999999999999998" blue="0.20000000000000001" alpha="0.20000000000000001"/> <color name="Text Area Background" red="0.396078431372549" green="0.42352941176470588" blue="0.45490196078431372" alpha="1"/> <color name="Button Background 1" red="0.098039215686274508" green="0.10980392156862745" blue="0.11764705882352941" alpha="1"/>
--- a/resources/high_contrast.theme +++ b/resources/high_contrast.theme @@ -2,44 +2,45 @@ <theme> <color name="Highlighted 1" red="0" green="0" blue="0" alpha="1"/> <color name="Guide 1" red="0" green="0" blue="0" alpha="1"/> - <color name="Foreground 6" red="0" green="0" blue="0" alpha="1"/> + <color name="Overview Item Border" red="0" green="0" blue="0" alpha="1"/> <color name="Active Quadratic Control Point" red="0" green="0" blue="0" alpha="1"/> <color name="Background 1" red="1" green="1" blue="1" alpha="1"/> <color name="Guide 2" red="0" green="0" blue="0" alpha="1"/> - <color name="Foreground 7" red="0" green="0" blue="0" alpha="1"/> - <color name="Background 2" red="0" green="0" blue="0" alpha="1"/> <color name="Guide 3" red="0" green="0" blue="0" alpha="1"/> - <color name="Selected Overview Item 1" red="0" green="0" blue="0" alpha="1"/> - <color name="Background 3" red="0" green="0" blue="0" alpha="1"/> - <color name="Selected Overview Item 2" red="0" green="0" blue="0" alpha="1"/> - <color name="Background 4" red="1" green="1" blue="1" alpha="1"/> - <color name="Dialog Shadow" red="0" green="0" blue="0" alpha="0.29999999999999999"/> - <color name="Background 5" red="1" green="1" blue="1" alpha="1"/> - <color name="Glyph Count Background" red="1" green="1" blue="1" alpha="1"/> - <color name="Background 6" red="1" green="1" blue="1" alpha="1"/> + <color name="Tab Separator" red="0" green="0" blue="0" alpha="1"/> + <color name="Overview Glyph" red="0" green="0" blue="0" alpha="1"/> + <color name="Dialog Shadow" red="0" green="0" blue="0" alpha="1"/> <color name="Selected Active Cubic Control Point" red="0" green="0" blue="0" alpha="1"/> <color name="Selected Cubic Control Point" red="0" green="0" blue="0" alpha="1"/> - <color name="Background 7" red="1" green="1" blue="1" alpha="1"/> + <color name="Selected Tab Foreground" red="0.14901960784313725" green="0.14117647058823529" blue="0.15294117647058825" alpha="1"/> <color name="Control Point Handle" red="0" green="0" blue="0" alpha="1"/> - <color name="Background 8" red="1" green="1" blue="1" alpha="1"/> + <color name="Text Tab Bar" red="0" green="0" blue="0" alpha="1"/> + <color name="Zoom Bar Border" red="0" green="0" blue="0" alpha="1"/> + <color name="Selected Tab Foregrund" red="1" green="1" blue="1" alpha="1"/> + <color name="Text Foreground" red="0" green="0" blue="0" alpha="1"/> <color name="Fill Color" red="0" green="0" blue="0" alpha="1"/> - <color name="Foreground Inverted Table" red="1" green="1" blue="1" alpha="1"/> - <color name="Background 9" red="1" green="1" blue="1" alpha="1"/> + <color name="Table Background 1" red="1" green="1" blue="1" alpha="1"/> <color name="Stroke Color" red="0" green="0" blue="0" alpha="1"/> + <color name="Menu Background" red="1" green="1" blue="1" alpha="1"/> + <color name="Table Background 2" red="1" green="1" blue="1" alpha="1"/> <color name="Selected Tool Foreground" red="1" green="1" blue="1" alpha="1"/> <color name="Selected Control Point Handle" red="0" green="0" blue="0" alpha="1"/> + <color name="Font Name" red="0" green="0" blue="0" alpha="1"/> <color name="Button Foreground" red="0" green="0" blue="0" alpha="1"/> <color name="Grid" red="0" green="0" blue="0" alpha="1"/> <color name="Text Area Background" red="1" green="1" blue="1" alpha="1"/> - <color name="Background 10" red="1" green="1" blue="1" alpha="1"/> <color name="Button Background 1" red="0" green="0" blue="0" alpha="1"/> + <color name="Glyph Count Background 1" red="1" green="1" blue="1" alpha="1"/> <color name="Button Border 1" red="0" green="0" blue="0" alpha="1"/> <color name="Button Background 2" red="0" green="0" blue="0" alpha="1"/> + <color name="Glyph Count Background 2" red="1" green="1" blue="1" alpha="1"/> <color name="Button Border 2" red="0" green="0" blue="0" alpha="1"/> <color name="Button Background 3" red="1" green="1" blue="1" alpha="1"/> + <color name="Selection Border" red="0" green="0" blue="0" alpha="1"/> <color name="Button Border 3" red="0" green="0" blue="0" alpha="1"/> <color name="Button Background 4" red="1" green="1" blue="1" alpha="1"/> - <color name="Background Glyph" red="0" green="0" blue="0" alpha="1"/> + <color name="Background Glyph" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="0.5"/> + <color name="Default Background" red="1" green="1" blue="1" alpha="1"/> <color name="Handle Color" red="0" green="0" blue="0" alpha="1"/> <color name="Button Border 4" red="0" green="0" blue="0" alpha="1"/> <color name="Highlighted Guide" red="0" green="0" blue="0" alpha="1"/> @@ -48,7 +49,12 @@ <color name="Selected Active Quadratic Control Point" red="0" green="0" blue="0" alpha="1"/> <color name="Overview Item 2" red="1" green="1" blue="1" alpha="1"/> <color name="Selected Button Foreground" red="1" green="1" blue="1" alpha="1"/> - <color name="Menu Foreground" red="1" green="1" blue="1" alpha="1"/> + <color name="Active Spin Button" red="0" green="0" blue="0" alpha="1"/> + <color name="Menu Foreground" red="0" green="0" blue="0" alpha="1"/> + <color name="Dialog Background" red="1" green="1" blue="1" alpha="1"/> + <color name="Table Border" red="0" green="0" blue="0" alpha="1"/> + <color name="Spin Button" red="0" green="0" blue="0" alpha="1"/> + <color name="Text Tool Box" red="0" green="0" blue="0" alpha="1"/> <color name="Overview Foreground" red="0" green="0" blue="0" alpha="1"/> <color name="Selected Objects" red="0" green="0" blue="0" alpha="1"/> <color name="Tool Foreground" red="0" green="0" blue="0" alpha="1"/> @@ -58,12 +64,11 @@ <color name="Foreground 1" red="0" green="0" blue="0" alpha="1"/> <color name="Active Control Point Handle" red="0" green="0" blue="0" alpha="1"/> <color name="Merge" red="0" green="0" blue="0" alpha="1"/> - <color name="Foreground 2" red="0" green="0" blue="0" alpha="1"/> - <color name="Foreground 3" red="0" green="0" blue="0" alpha="1"/> + <color name="Headline Background" red="0" green="0" blue="0" alpha="1"/> <color name="Overview Selected Foreground" red="1" green="1" blue="1" alpha="1"/> - <color name="Foreground 4" red="1" green="1" blue="1" alpha="1"/> + <color name="Canvas Background" red="1" green="1" blue="1" alpha="1"/> <color name="Foreground Inverted" red="1" green="1" blue="1" alpha="1"/> - <color name="Foreground 5" red="0" green="0" blue="0" alpha="1"/> + <color name="Selected Overview Item" red="0" green="0" blue="0" alpha="1"/> <color name="Quadratic Control Point" red="0" green="0" blue="0" alpha="1"/> </theme>