Merge lp:~elementary-apps/switchboard/category-label-css into lp:~elementary-pantheon/switchboard/switchboard

Proposed by Danielle Foré
Status: Merged
Approved by: Cody Garver
Approved revision: 462
Merged at revision: 463
Proposed branch: lp:~elementary-apps/switchboard/category-label-css
Merge into: lp:~elementary-pantheon/switchboard/switchboard
Diff against target: 24 lines (+1/-13)
1 file modified
src/CategoryView.vala (+1/-13)
To merge this branch: bzr merge lp:~elementary-apps/switchboard/category-label-css
Reviewer Review Type Date Requested Status
elementary Pantheon team Pending
Review via email: mp+227656@code.launchpad.net

Commit message

replace hardcoded CSS with .category-label class and do the styling in the theme

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/CategoryView.vala'
--- src/CategoryView.vala 2014-05-26 08:51:58 +0000
+++ src/CategoryView.vala 2014-07-22 00:19:06 +0000
@@ -56,19 +56,7 @@
5656
57 private void setup_category (Switchboard.Plug.Category category, int i) {57 private void setup_category (Switchboard.Plug.Category category, int i) {
58 var category_label = new Gtk.Label (get_category_name (category));58 var category_label = new Gtk.Label (get_category_name (category));
59 var fg_css = new Gtk.CssProvider ();59 category_label.get_style_context ().add_class ("category-label");
60
61 try {
62 fg_css.load_from_data ("*{
63 color: shade (@bg_color, 0.4);
64 font: open sans 11;
65 font-weight: 600;
66 text-shadow: 0 1px alpha (#fff, 0.6);
67 }", -1);
68 category_label.get_style_context ().add_provider (fg_css, 20000);
69 } catch (Error e) {
70 critical (e.message);
71 }
7260
73 category_label.margin_left = 12;61 category_label.margin_left = 12;
74 category_label.margin_right = 8;62 category_label.margin_right = 8;

Subscribers

People subscribed via source and target branches