Skip to content

Commit

Permalink
Fix up some logo style stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
danirabbit committed Dec 20, 2023
1 parent e9cc841 commit a064522
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions data/OperatingSystemView.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.logo {
background-image: linear-gradient(
.card.circular {
background: linear-gradient(
to bottom,
alpha(@accent_color_500, 0.25),
alpha(@accent_color_700, 0.75)
Expand Down
8 changes: 5 additions & 3 deletions src/Views/OperatingSystemView.vala
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,10 @@ public class About.OperatingSystemView : Gtk.Box {

if (file.query_exists ()) {
var logo = new Gtk.Image.from_file (file.get_path ()) {
overflow = HIDDEN,
pixel_size = 128
};
logo.add_css_class (Granite.STYLE_CLASS_CIRCULAR);
logo.get_style_context ().add_provider (style_provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);

logo_overlay.child = logo;
Expand All @@ -63,9 +65,9 @@ public class About.OperatingSystemView : Gtk.Box {
// 128 minus 3px padding on each side
icon.pixel_size = 128 - 6;

unowned var icon_style_context = icon.get_style_context ();
icon_style_context.add_class ("logo");
icon_style_context.add_provider (style_provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
icon.add_css_class (Granite.STYLE_CLASS_CARD);
icon.add_css_class (Granite.STYLE_CLASS_CIRCULAR);
icon.get_style_context ().add_provider (style_provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);

break;
}
Expand Down

0 comments on commit a064522

Please sign in to comment.