Commit 8cf948bf authored by Lucas Manika Koeb's avatar Lucas Manika Koeb
Browse files

greeter: Change the logo displayed on the login scren



Add the Linux Educacional 5.0 logo to the login screen and
change the logo position.
Signed-off-by: default avatarLucas Manika Koeb <lmk08@c3sl.ufpr.br>
parent 5c67f91a
......@@ -22,6 +22,7 @@ class BackgroundLoader : Object
{
public string filename {get; private set;}
public Cairo.Surface logo {get; set;}
public int version_logo_width {get; set;}
public int[] widths;
public int[] heights;
......@@ -175,7 +176,7 @@ class BackgroundLoader : Object
private Cairo.Pattern? create_pattern (Gdk.Pixbuf image)
{
var grid_x_offset = get_grid_offset (image.width);
//var grid_x_offset = get_grid_offset (image.width);
var grid_y_offset = get_grid_offset (image.height);
/* Create background */
......@@ -189,8 +190,8 @@ class BackgroundLoader : Object
if (logo != null)
{
bc.save ();
var y = (int) (image.height / grid_size - 2) * grid_size + grid_y_offset;
bc.translate (grid_x_offset, y);
var y = (int) (image.height / grid_size - 1) * grid_size + grid_y_offset;
bc.translate (image.width/2 - version_logo_width/2, y);
bc.set_source_surface (logo, 0, 0);
bc.paint_with_alpha (0.5);
bc.restore ();
......@@ -466,6 +467,7 @@ public class Background : Gtk.Fixed
b = new BackgroundLoader (target_surface, filename, widths, heights, draw_grid);
b.logo = version_logo_surface;
b.version_logo_width = version_logo_width;
b.loaded.connect (() => {reload();});
b.load ();
loaders.insert (filename, b);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment