diff --git a/briar-gtk/briar_gtk/widgets/private_message.py b/briar-gtk/briar_gtk/widgets/private_message.py index f9951016bc6f9077ee8ac0446aa09204c9e82e47..9563fc0203b06050e7a6cf0c7b8e033a9ca87aa1 100644 --- a/briar-gtk/briar_gtk/widgets/private_message.py +++ b/briar-gtk/briar_gtk/widgets/private_message.py @@ -22,10 +22,13 @@ class PrivateMessageWidget(Gtk.ListBoxRow): self.set_margin_top(12) username = contact_name + username_style_class = "username" if message["local"]: username = _("Myself") + username_style_class = "username-self" - username_info = PrivateMessageWidget._create_username_info(username) + username_info = PrivateMessageWidget._create_username_info( + username, username_style_class) date_info = PrivateMessageWidget._create_date_info( message["timestamp"] / 1000) info = PrivateMessageWidget._create_info(username_info, date_info) @@ -44,11 +47,11 @@ class PrivateMessageWidget(Gtk.ListBoxRow): self.show_all() @staticmethod - def _create_username_info(username): + def _create_username_info(username, username_style_class): username_label = Gtk.Label.new(username) username_label.set_justify(Gtk.Justification.LEFT) username_label.set_halign(Gtk.Align.START) - username_label.get_style_context().add_class("username") + username_label.get_style_context().add_class(username_style_class) username_event_box = Gtk.EventBox() username_event_box.add(username_label) diff --git a/briar-gtk/data/ui/application.css b/briar-gtk/data/ui/application.css index bbcfcb6761d84a83c9371368768c31f3c1ebb65d..fc3c7b361ad6da4f386d918286d0fd09a34eece7 100644 --- a/briar-gtk/data/ui/application.css +++ b/briar-gtk/data/ui/application.css @@ -61,12 +61,18 @@ opacity: 0.5; } +row .username-self { + font-weight: bold; + font-size: small; + color: @theme_selected_bg_color; +} + row .username { font-weight: bold; font-size: small; + color: #74B816; } -row .username, row.msg-emote, .divider { color: @theme_selected_bg_color;