swayfx/sway
Hugo Osvaldo Barrera c16b2a26ed Avoid unecessary font metric calculations
Prior to 62d90a8e, titlebar's font height (and other related values)
would change any time any titlebar's content changed, so these values
were recalculated each time any titlebar's content changed (or a new
titlebar was created).

However, since the above was merge, these values no longer change so
often and we only need to recalculate them when the configured font
changes (and stop calling `config_update_font_height` each time
titlebars are rendered).

This commit removes all the unecessary calls to this function and avoids
all those unecessary calculations. Whenever the font strays from the
default value, the `font` command is called, and it calls
`config_update_font_height`, which is enough to keep the value always up
to date.

I've also added a default value to the `font_baseline` config, since
otherwise that's zero for setups that don't explicitly specify a font.
2021-09-20 09:25:47 +02:00
..
commands Avoid unecessary font metric calculations 2021-09-20 09:25:47 +02:00
config Add output modeline command 2021-08-31 17:29:40 +02:00
desktop introduce wlr_drm_lease_v1 2021-09-09 15:25:19 +02:00
input seatop_down: End if surface is destroyed or other seatop starts 2021-09-02 13:13:40 -04:00
tree Avoid unecessary font metric calculations 2021-09-20 09:25:47 +02:00
commands.c Fix for_window criteria and mouse button bindings 2021-02-25 09:48:39 -05:00
config.c Avoid unecessary font metric calculations 2021-09-20 09:25:47 +02:00
criteria.c container: Move pending state to state struct 2021-02-16 22:05:00 -05:00
decoration.c Fix double free when unmapping any view 2018-11-15 15:22:09 +10:00
ipc-json.c Update wlr_box includes 2021-07-07 11:29:14 +02:00
ipc-server.c Fix incorrect format specifiers 2020-07-30 22:02:42 -04:00
main.c main: removed vc4 detection code. 2021-04-29 18:04:34 +02:00
meson.build Implement xdg-activation-v1 2021-06-02 19:39:40 +02:00
server.c introduce wlr_drm_lease_v1 2021-09-09 15:25:19 +02:00
sway-bar.5.scd man: update Pango font description URL 2021-08-04 02:15:04 +02:00
sway-input.5.scd man: document input XXX map_to_output * 2021-02-25 09:38:00 -05:00
sway-ipc.7.scd sway-ipc.7.scd: fix typo 2021-09-19 17:28:37 +02:00
sway-output.5.scd Add output modeline command 2021-08-31 17:29:40 +02:00
sway.1.scd man: update maintainer 2021-01-08 09:33:51 +01:00
sway.5.scd command: implement split none 2021-09-03 23:50:20 +02:00
swaynag.c Use execlp("sh") instead of execl("/bin/sh") 2021-04-22 23:12:49 +02:00
xdg_activation_v1.c Implement xdg-activation-v1 2021-06-02 19:39:40 +02:00
xdg_decoration.c xdg-decoration: let floating clients set borders 2021-08-12 10:02:17 +02:00