mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-04-06 07:15:30 -04:00
term: get rid of term->font_scale, use term->scale only
We only needed term->font_scale to be able to detect scaling factor changes (term->font_scale != term->scale). But, we already have the old scaling factor in all places where term_font_dpi_changed() is called, so let’s pass the old scaling factor as an argument instead.
This commit is contained in:
parent
e7c01f3e52
commit
2afc678236
3 changed files with 16 additions and 22 deletions
|
|
@ -285,8 +285,10 @@ update_term_for_output_change(struct terminal *term)
|
|||
if (tll_length(term->window->on_outputs) == 0)
|
||||
return;
|
||||
|
||||
int old_scale = term->scale;
|
||||
|
||||
render_resize(term, term->width / term->scale, term->height / term->scale);
|
||||
term_font_dpi_changed(term);
|
||||
term_font_dpi_changed(term, old_scale);
|
||||
term_font_subpixel_changed(term);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue