Merge lp:~danrabbit/pantheon-greeter/cosmetic-changes into lp:~elementary-pantheon/pantheon-greeter/trunk

Proposed by Danielle Foré
Status: Merged
Merged at revision: 123
Proposed branch: lp:~danrabbit/pantheon-greeter/cosmetic-changes
Merge into: lp:~elementary-pantheon/pantheon-greeter/trunk
Diff against target: 203 lines (+41/-43)
3 files modified
src/ShadowedLabel.vala (+3/-5)
src/indicators.vala (+12/-12)
src/loginbox.vala (+26/-26)
To merge this branch: bzr merge lp:~danrabbit/pantheon-greeter/cosmetic-changes
Reviewer Review Type Date Requested Status
elementary Pantheon team Pending
Tom Beckmann Pending
Review via email: mp+136110@code.launchpad.net

Description of the change

This branch makes a number of small cosmetic changes:

* adjust shadows on login box
* adjust alignment of widgets in login box
* Slightly smaller text in login box
* render avatars more sharply
* render text shadows slightly below text
* Thinner "wingpanel"
* Style login box closer to popover appearance

To post a comment you must log in.
129. By Danielle Foré

tom is dumb for using tabs

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/ShadowedLabel.vala'
2--- src/ShadowedLabel.vala 2012-11-09 23:58:15 +0000
3+++ src/ShadowedLabel.vala 2012-11-26 09:41:36 +0000
4@@ -45,14 +45,12 @@
5 var layout = Pango.cairo_create_layout (buffer.context);
6 layout.set_markup (label, -1);
7
8- buffer.context.move_to (10, 0);
9+ buffer.context.move_to (0, 1);
10 buffer.context.set_source_rgba (0, 0, 0, 1);
11 Pango.cairo_show_layout (buffer.context, layout);
12- Pango.cairo_show_layout (buffer.context, layout);
13- buffer.exponential_blur (7);
14- Pango.cairo_show_layout (buffer.context, layout);
15- Pango.cairo_show_layout (buffer.context, layout);
16 buffer.exponential_blur (3);
17+
18+ buffer.context.move_to (0, 0);
19 buffer.context.set_source_rgba (1, 1, 1, 1);
20 Pango.cairo_show_layout (buffer.context, layout);
21
22
23=== modified file 'src/indicators.vala'
24--- src/indicators.vala 2012-08-13 16:21:40 +0000
25+++ src/indicators.vala 2012-11-26 09:41:36 +0000
26@@ -76,17 +76,17 @@
27
28 ~Indicators ()
29 {
30- if (keyboard_pid != 0) {
31- Posix.kill (keyboard_pid, Posix.SIGKILL);
32- int status;
33- Posix.waitpid (keyboard_pid, out status, 0);
34- keyboard_pid = 0;
35- }
36- }
37-
38- private async void run () {
39- try {
40- var proxy = new GLib.DBusProxy.for_bus_sync (GLib.BusType.SESSION,
41+ if (keyboard_pid != 0) {
42+ Posix.kill (keyboard_pid, Posix.SIGKILL);
43+ int status;
44+ Posix.waitpid (keyboard_pid, out status, 0);
45+ keyboard_pid = 0;
46+ }
47+ }
48+
49+ private async void run () {
50+ try {
51+ var proxy = new GLib.DBusProxy.for_bus_sync (GLib.BusType.SESSION,
52 GLib.DBusProxyFlags.NONE, null,
53 "org.gnome.SettingsDaemon",
54 "/org/gnome/SettingsDaemon",
55@@ -126,7 +126,7 @@
56 (get_widget () as Gtk.Container).add (bar);
57
58 bar.pack_direction = Gtk.PackDirection.RTL;
59- height = 28;
60+ height = 26;
61
62 var transp = new Gtk.CssProvider ();
63 try {
64
65=== modified file 'src/loginbox.vala'
66--- src/loginbox.vala 2012-11-09 19:39:47 +0000
67+++ src/loginbox.vala 2012-11-26 09:41:36 +0000
68@@ -4,11 +4,11 @@
69 background-image:none;
70 background-color:@bg_color;
71
72- border-radius: 6px;
73+ border-radius: 5px;
74
75- border-width:1px;
76+ border-width: 1px;
77 border-style: solid;
78- border-color: alpha (#000, 0.25);
79+ border-color: alpha (#000, 0.4);
80 }
81 """;
82
83@@ -27,10 +27,10 @@
84 Gdk.Pixbuf image;
85
86 Granite.Drawing.BufferSurface buffer;
87- int shadow_blur = 20;
88+ int shadow_blur = 25;
89 int shadow_x = 0;
90- int shadow_y = 4;
91- double shadow_alpha = 0.5;
92+ int shadow_y = 6;
93+ double shadow_alpha = 0.6;
94
95 LightDM.Greeter greeter;
96
97@@ -58,7 +58,7 @@
98 this.scale_gravity = Clutter.Gravity.CENTER;
99
100 try {
101- this.image = Gtk.IconTheme.get_default ().load_icon ("avatar-default", 96, 0);
102+ this.image = Gtk.IconTheme.get_default ().load_icon ("avatar-default", 92, 0);
103 } catch (Error e) { warning (e.message); }
104
105 this.avatar = new Gtk.EventBox ();
106@@ -67,22 +67,23 @@
107 this.login = new Gtk.Button.with_label (_("Login"));
108 this.settings = new Gtk.ToggleButton ();
109
110- avatar.set_size_request (97, 97);
111+ avatar.set_size_request (92, 92);
112 avatar.valign = Gtk.Align.START;
113 avatar.visible_window = false;
114 username.hexpand = true;
115 username.halign = Gtk.Align.START;
116 username.ellipsize = Pango.EllipsizeMode.END;
117- username.margin_top = 10;
118- username.height_request = 65;
119- login.expand = false;
120+ username.margin_top = 6;
121+ username.height_request = 1;
122+ login.expand = false;
123 login.height_request = 1;
124- login.width_request = 140;
125- login.margin_top = 30;
126+ login.width_request = 120;
127+ login.margin_top = 26;
128 login.halign = Gtk.Align.END;
129 settings.valign = Gtk.Align.START;
130 settings.relief = Gtk.ReliefStyle.NONE;
131 settings.add (new Gtk.Image.from_icon_name ("application-menu-symbolic", Gtk.IconSize.MENU));
132+ password.margin_top = 11;
133 password.caps_lock_warning = true;
134 password.set_visibility (false);
135 password.key_release_event.connect ( (e) => {
136@@ -94,9 +95,9 @@
137 });
138
139 spinner = new Gtk.Spinner ();
140- spinner.valign = Gtk.Align.START;
141+ spinner.valign = Gtk.Align.CENTER;
142 spinner.start ();
143- spinner.set_size_request (97, 97);
144+ spinner.set_size_request (92, 24);
145
146 grid = new Gtk.Grid ();
147
148@@ -108,13 +109,13 @@
149
150 grid.margin = shadow_blur + 12;
151 grid.margin_top += 5;
152- grid.margin_bottom -= 10;
153+ grid.margin_bottom -= 12;
154 grid.column_spacing = 12;
155
156 avatar.draw.connect ( (ctx) => {
157- Granite.Drawing.Utilities.cairo_rounded_rectangle (ctx, 0.5, 0.5,
158- avatar.get_allocated_width ()-1, avatar.get_allocated_height ()-1, 5);
159- Gdk.cairo_set_source_pixbuf (ctx, image, 0.5, 0.5);
160+ Granite.Drawing.Utilities.cairo_rounded_rectangle (ctx, 0, 0,
161+ avatar.get_allocated_width (), avatar.get_allocated_height (), 3);
162+ Gdk.cairo_set_source_pixbuf (ctx, image, 0, 0);
163 ctx.fill_preserve ();
164 ctx.set_line_width (1);
165 ctx.set_source_rgba (0, 0, 0, 0.3);
166@@ -180,14 +181,14 @@
167
168 this.buffer = new Granite.Drawing.BufferSurface (w, h);
169
170- this.buffer.context.rectangle (shadow_blur + shadow_x,
171- shadow_blur + shadow_y, w - shadow_blur*2 + shadow_x, h - shadow_blur*2 + shadow_y);
172+ this.buffer.context.rectangle (shadow_blur + shadow_x + 3,
173+ shadow_blur + shadow_y*2, w - shadow_blur*2 + shadow_x - 6, h - shadow_blur*2 - shadow_y);
174 this.buffer.context.set_source_rgba (0, 0, 0, shadow_alpha);
175 this.buffer.context.fill ();
176 this.buffer.exponential_blur (shadow_blur / 2-2);
177
178 draw_ref.get_style_context ().render_activity (this.buffer.context, shadow_blur + shadow_x,
179- shadow_blur + shadow_y, w - shadow_blur*2 + shadow_x, h - shadow_blur*2 + shadow_y);
180+ shadow_blur + shadow_y -2, w - shadow_blur*2 + shadow_x, h - shadow_blur*2);
181 });
182
183 this.get_widget ().draw.connect ( (ctx) => {
184@@ -208,16 +209,15 @@
185 }
186
187 public static string get_user_markup (LightDM.User user, bool title=false) {
188- var color = (title)?"color='#808080'":"";
189- return "<span face='Open Sans Light' font='32'>"+user.real_name+"</span>";
190+ return "<span face='Open Sans Light' font='24'>"+user.real_name+"</span>";
191 }
192
193 public void wrong_pw () {
194 this.password.text = "";
195- this.animate (Clutter.AnimationMode.EASE_IN_BOUNCE, 200, scale_x:1.3f, scale_y:1.3f).
196+ this.animate (Clutter.AnimationMode.EASE_IN_BOUNCE, 150, scale_x:0.9f, scale_y: 0.9f).
197 completed.connect ( () => {
198 Clutter.Threads.Timeout.add (1, () => {
199- this.animate (Clutter.AnimationMode.EASE_OUT_BOUNCE, 200, scale_x:1.0f, scale_y:1.0f);
200+ this.animate (Clutter.AnimationMode.EASE_OUT_BOUNCE, 150, scale_x:1.0f, scale_y: 1.0f);
201 return false;
202 });
203 });

Subscribers

People subscribed via source and target branches