mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-07 21:59:54 +00:00
LibWeb: Account for animated values when computing font
Computing the font for an element in `compute_font` is premature since we are yet to apply animated properties - instead we should compute the value on the fly (with a cache to avoid unnecessary work) to ensure we are respecting the latest values
This commit is contained in:
parent
6c236d04d8
commit
dca80ad5eb
Notes:
github-actions[bot]
2025-12-05 10:04:25 +00:00
Author: https://github.com/Calme1709
Commit: dca80ad5eb
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6757
Reviewed-by: https://github.com/AtkinsSJ ✅
Reviewed-by: https://github.com/gmta
12 changed files with 69 additions and 43 deletions
|
|
@ -696,7 +696,7 @@ static CSS::RequiredInvalidationAfterStyleChange compute_required_invalidation(C
|
|||
{
|
||||
CSS::RequiredInvalidationAfterStyleChange invalidation;
|
||||
|
||||
if (!old_style.computed_font_list().equals(new_style.computed_font_list()))
|
||||
if (old_style.cached_computed_font_list() != new_style.cached_computed_font_list())
|
||||
invalidation.relayout = true;
|
||||
|
||||
for (auto i = to_underlying(CSS::first_longhand_property_id); i <= to_underlying(CSS::last_longhand_property_id); ++i) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue