diff options
author | Reza Jelveh <[email protected]> | 2024-04-15 13:39:41 +0800 |
---|---|---|
committer | GitHub <[email protected]> | 2024-04-15 01:39:41 -0400 |
commit | fb86ed6b0588dfdebfb66ce875bc63cfa0a897f6 (patch) | |
tree | 29857a1769107adc58696f08d379f608aa4e29a2 /sway/commands/font.c | |
parent | a5e79676c4bd22fc5902182acf0667907202a465 (diff) |
feat: 1.9 merge (#277)
Co-authored-by: William McKinnon <[email protected]>
Co-authored-by: Erik Reider <[email protected]>
Diffstat (limited to 'sway/commands/font.c')
-rw-r--r-- | sway/commands/font.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sway/commands/font.c b/sway/commands/font.c index dd80281f..74bb6b9f 100644 --- a/sway/commands/font.c +++ b/sway/commands/font.c @@ -33,10 +33,10 @@ struct cmd_results *cmd_font(int argc, char **argv) { return cmd_results_new(CMD_FAILURE, "Invalid font family."); } - const PangoFontMask flags = pango_font_description_get_set_fields(font_description); - if ((flags & PANGO_FONT_MASK_SIZE) == 0) { + const gint size = pango_font_description_get_size(font_description); + if (size == 0) { pango_font_description_free(font_description); - return cmd_results_new(CMD_FAILURE, "Font size not given."); + return cmd_results_new(CMD_FAILURE, "Invalid font size."); } if (config->font_description != NULL) { |