mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-19 05:33:44 -04:00
term: cache font baseline
No need to redo the calculation for every single cell we render, every frame...
This commit is contained in:
parent
34aa979f46
commit
4449177517
4 changed files with 12 additions and 9 deletions
|
|
@ -774,6 +774,8 @@ term_set_fonts(struct terminal *term, struct fcft_font *fonts[static 4],
|
|||
term->font_x_ofs = term_pt_or_px_as_pixels(term, &conf->horizontal_letter_offset);
|
||||
term->font_y_ofs = term_pt_or_px_as_pixels(term, &conf->vertical_letter_offset);
|
||||
|
||||
term->font_baseline = term_font_baseline(term);
|
||||
|
||||
LOG_INFO("cell width=%d, height=%d", term->cell_width, term->cell_height);
|
||||
|
||||
sixel_cell_size_changed(term);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue