mirror of
https://github.com/gwenhael-le-moine/sway-patched-tray-menu.git
synced 2024-12-28 22:23:42 +01:00
Make pango: optional for bar font
This commit is contained in:
parent
655b003062
commit
63474aa04d
1 changed files with 3 additions and 3 deletions
|
@ -2263,14 +2263,14 @@ static struct cmd_results *bar_cmd_font(int argc, char **argv) {
|
|||
}
|
||||
|
||||
char *font = join_args(argv, argc);
|
||||
free(config->current_bar->font);
|
||||
if (strlen(font) > 6 && strncmp("pango:", font, 6) == 0) {
|
||||
free(config->current_bar->font);
|
||||
config->current_bar->font = font;
|
||||
sway_log(L_DEBUG, "Settings font '%s' for bar: %s", config->current_bar->font, config->current_bar->id);
|
||||
} else {
|
||||
sway_log(L_ERROR, "warning: non-pango font '%s' not supported.", font);
|
||||
config->current_bar->font = font;
|
||||
}
|
||||
|
||||
sway_log(L_DEBUG, "Settings font '%s' for bar: %s", config->current_bar->font, config->current_bar->id);
|
||||
return cmd_results_new(CMD_SUCCESS, NULL, NULL);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue