mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-08 06:09:58 +00:00
LibWeb: Add basic variable font support
Integrates the new `FontVariationSettings` from LibGfx into LibWeb to enable initial variable font functionality. Currently, only the `wght` (weight) axis is fully supported and tested. This update also introduces support for the CSS `font-variation-settings` property.
This commit is contained in:
parent
489381698f
commit
3829a85fde
Notes:
github-actions[bot]
2025-11-04 20:46:29 +00:00
Author: https://github.com/Norbiros
Commit: 3829a85fde
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6439
Reviewed-by: https://github.com/AtkinsSJ
Reviewed-by: https://github.com/gmta
Reviewed-by: https://github.com/kalenikaliaksandr
Reviewed-by: https://github.com/konradekk
7 changed files with 94 additions and 24 deletions
|
|
@ -146,7 +146,9 @@ void CanvasTextDrawingStyles<IncludingClass, CanvasType>::set_font(StringView fo
|
|||
computed_font_size->as_length().length().absolute_length_to_px(),
|
||||
computed_font_style->as_font_style().to_font_slope(),
|
||||
computed_font_weight->as_number().number(),
|
||||
computed_font_width->as_percentage().percentage());
|
||||
computed_font_width->as_percentage().percentage(),
|
||||
{},
|
||||
length_resolution_context);
|
||||
},
|
||||
[](HTML::WorkerGlobalScope*) -> RefPtr<Gfx::FontCascadeList const> {
|
||||
// FIXME: implement computing the font for HTML::WorkerGlobalScope
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue