[f21] Support high contrast mode in fedora-welcome (#1160499)

David Shea dshea at redhat.com
Tue Nov 11 21:33:09 UTC 2014


(pushing this needs to be coordinated with a path change in fedora-logos)

Thanks to Matthias Clasen for this patch. Remove the hardcoded text
color from the icon labels and use a named icon for "Install to Hard
Drive" instead of a full path.
---
 data/liveinst/gnome/fedora-welcome | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/data/liveinst/gnome/fedora-welcome b/data/liveinst/gnome/fedora-welcome
index 973a3ab..10da12e 100755
--- a/data/liveinst/gnome/fedora-welcome
+++ b/data/liveinst/gnome/fedora-welcome
@@ -40,14 +40,14 @@ function makeLabel(label, button) {
     let widget = new Gtk.Label();
 
     if (button)
-        widget.set_markup('<b><span size="x-large" color="white">' + label + '</span></b>');
+        widget.set_markup('<b><span size="x-large">' + label + '</span></b>');
     else {
         widget.set_line_wrap(true);
         widget.set_justify(Gtk.Justification.CENTER);
         widget.set_margin_top(32);
         widget.set_margin_bottom(32);
 
-        widget.set_markup('<span size="large" color="white">' + label + '</span>');
+        widget.set_markup('<span size="large">' + label + '</span>');
     }
 
     return widget;
@@ -99,10 +99,8 @@ const WelcomeWindow = new Lang.Class({
                                          spacing: 16 });
 
       // provided by the 'fedora-logos' package
-      let pix = GdkPixbuf.Pixbuf.new_from_file_at_size(
-          '/usr/share/icons/Fedora/scalable/apps/anaconda.svg',
-          256, 256);
-      installContent.add(new Gtk.Image({ pixbuf: pix }));
+      installContent.add(new Gtk.Image({ icon_name: 'anaconda',
+                                         pixel_size: 256 }));
       installContent.add(makeLabel(anacondaApp.get_name(), true));
 
       let installButton = new Gtk.Button({ child: installContent });
-- 
2.1.0



More information about the anaconda-patches mailing list