mirror of
https://github.com/labwc/labwc.git
synced 2025-11-02 09:01:47 -05:00
icon-loader: load SVG icons at max scale of any usable output
- Add a new function to get the maximum scale of all usable outputs - Pass the maximum output scale through to img_svg_load(), which ultimately calls cairo_surface_set_device_scale() before rendering
This commit is contained in:
parent
a5d89a2e4c
commit
ddfaae98ad
8 changed files with 52 additions and 12 deletions
|
|
@ -257,7 +257,8 @@ load_button(struct theme *theme, struct button *b, int active)
|
|||
int size = theme->title_height - 2 * theme->padding_height;
|
||||
get_button_filename(filename, sizeof(filename), b->name,
|
||||
active ? "-active.svg" : "-inactive.svg");
|
||||
img_svg_load(filename, buffer, size);
|
||||
/* TODO: account for output scale */
|
||||
img_svg_load(filename, buffer, size, 1);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue