Skip to content

Commit 2c75457

Browse files
authored
DeviceRow: use CSS for small label (#242)
1 parent 50dbf60 commit 2c75457

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

src/DeviceRow.vala

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,10 @@ public class Bluetooth.DeviceRow : Gtk.ListBoxRow {
7979
state.halign = Gtk.Align.END;
8080
state.valign = Gtk.Align.END;
8181

82-
state_label = new Gtk.Label (null);
83-
state_label.xalign = 0;
84-
state_label.use_markup = true;
82+
state_label = new Gtk.Label (null) {
83+
xalign = 0
84+
};
85+
state_label.add_css_class (Granite.STYLE_CLASS_SMALL_LABEL);
8586

8687
var overlay = new Gtk.Overlay () {
8788
child = image,
@@ -277,7 +278,7 @@ public class Bluetooth.DeviceRow : Gtk.ListBoxRow {
277278
}
278279

279280
private void set_status (Status status) {
280-
state_label.label = GLib.Markup.printf_escaped ("<span font_size='small'>%s</span>", status.to_string ());
281+
state_label.label = status.to_string ();
281282
state.visible = true;
282283

283284
switch (status) {

0 commit comments

Comments
 (0)