diff options
| author | Federico Angelilli <code@fedang.net> | 2024-03-23 11:16:24 +0100 |
|---|---|---|
| committer | Federico Angelilli <code@fedang.net> | 2024-03-23 11:16:24 +0100 |
| commit | 46de28e9789618b2ea7af66c461f3f7db5ef0bd5 (patch) | |
| tree | 00a4493d538895b168ba9852a07319a71e553788 /src/comet.c | |
| parent | 12f20dd7cd742e0cf54543ea5a1642b911ed1ec6 (diff) | |
Implement initial hidpi scaling
Diffstat (limited to 'src/comet.c')
| -rw-r--r-- | src/comet.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/comet.c b/src/comet.c index 7adebaf..24e89ea 100644 --- a/src/comet.c +++ b/src/comet.c @@ -282,6 +282,7 @@ int main(int argc, char **argv) int screen_width = con->screen_size->width; int screen_height = con->screen_size->height; + double scale = window_get_scale(win); int height = EVEN(round(screen_height * 0.021)); int x_padding = EVEN(round(screen_width * 0.005)); @@ -297,7 +298,7 @@ int main(int argc, char **argv) draw_set_separator(draw, 10); draw_set_font(draw, "Hack 13 Bold"); draw_set_context(draw, context); - draw_set_size(draw, height, x_padding, x_padding, y_padding); + draw_set_size(draw, height, x_padding, x_padding, y_padding, scale); State *state = state_create(win, draw); |
