Skip to content

Flags are not scaled correctly #11

Description

@kalj

I enabled showing flags by

gsettings set org.mate.peripherals-keyboard-xkb.indicator show-flags true

and adding flags to ~/.icons/flags.

The flags appear and work as they should in all respects except one; the aspect ratio of the status icon in the panel is not correct. Instead of keeping the shape of the input image, it is stretched to span the entire space of the status icon. I believe this is a bug.

Btw, the icon showed at other places e.g. when unlocking the screen lock or in lightdm is correct, so this seams to be limited to libmatekbd-status.[ch].

Although I have absolutely no experience with gnome/gtk/gdk programming, I looked in the code to see if I could find anything. As far I understand, the flag image is loaded in libmatekbd-status.c:312:

image = gdk_pixbuf_new_from_file_at_size (image_filename,
                          globals.current_width,
                          globals.current_height,
                          &gerror);

Now, this should do the right thing and maintain the aspect ratio, at least according to the manual.

In my infinite ignorance, here is where I'm stuck. I would be happy very grateful for some hints and pointers on where to continue with this!


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions