diff options
author | Christian Pointner <equinox@helsinki.at> | 2016-02-06 05:52:04 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2016-02-06 05:52:04 (GMT) |
commit | 46037ccf5c9a499c37e6e14230f3bbc8d0bf1010 (patch) | |
tree | bf381374be5ee7dfe7f980d4c064e89d8a9bf938 /src | |
parent | 19325b246ad32046be6ce50216f6f7f4de9984df (diff) |
nicer selector page labels
Diffstat (limited to 'src')
-rw-r--r-- | src/rhlibrary/selector_widget.go | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/rhlibrary/selector_widget.go b/src/rhlibrary/selector_widget.go index 59f59f8..e304750 100644 --- a/src/rhlibrary/selector_widget.go +++ b/src/rhlibrary/selector_widget.go @@ -100,7 +100,21 @@ func addSelectorPage(nb *gtk.Notebook, title string, getWidget getSelectorFunc, if label, err = gtk.LabelNew(title); err != nil { return } - label.SetSizeRequest(150, 15) // workaround until expanding tabs works... + label.SetSizeRequest(250, 0) // workaround until expanding tabs works... + + var cp *gtk.CssProvider + if cp, err = gtk.CssProviderNew(); err != nil { + return + } + if err = cp.LoadFromData(".label { font-weight: bold; font-size: 12px; padding: 3px; }"); err != nil { + return + } + var sc *gtk.StyleContext + if sc, err = label.GetStyleContext(); err != nil { + return + } + sc.AddProvider(cp, 600) // TOOD: hardcoded value + nb.AppendPage(page, label) return } |