~jeremywootten/pantheon-files/fix-1622053-restore-from-trash-crash

« back to all changes in this revision

Viewing changes to src/View/Sidebar.vala

Use similar code to Noise to set the font when rendering sidebar text

Show diffs side-by-side

added added

removed removed

Lines of Context:
1626
1626
                                             Gtk.TreeIter iter) {
1627
1627
 
1628
1628
            var crt = renderer as Gtk.CellRendererText;
 
1629
            string text;
1629
1630
            bool is_category, show_eject_button;
1630
1631
            uint64 disk_size = 0;
1631
 
            model.@get (iter, Column.IS_CATEGORY, out is_category,
 
1632
            model.@get (iter, Column.NAME, out text,
 
1633
                              Column.IS_CATEGORY, out is_category,
1632
1634
                              Column.DISK_SIZE, out disk_size,
1633
1635
                              Column.SHOW_EJECT, out show_eject_button, -1);
1634
1636
 
1635
1637
            if (is_category) {
1636
 
                crt.weight = 900;
1637
 
                crt.weight_set = true;
 
1638
                crt.markup = "<b>" + text + "</b>";
1638
1639
                crt.ypad = CATEGORY_YPAD;
1639
1640
            } else {
1640
 
                crt.weight_set = false;
 
1641
                crt.markup = text;
1641
1642
                crt.ypad = BOOKMARK_YPAD;
1642
1643
                if (disk_size > 0) {
1643
1644
                    /* Make disk space graphic same length whether or not eject button displayed */