mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-19 15:32:31 +00:00
LibWeb/CSS: Introduce OpenTypeTaggedStyleValue
Two font properties, font-feature-settings and font-variation-settings, contain a list of values that are an `<opentype-tag>` followed by a single value. This class is intended to fill both roles.
This commit is contained in:
parent
94b3b84dd8
commit
c22a2d8f2b
Notes:
github-actions[bot]
2024-10-02 15:38:16 +00:00
Author: https://github.com/AtkinsSJ
Commit: c22a2d8f2b
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1599
6 changed files with 85 additions and 0 deletions
|
@ -40,6 +40,7 @@
|
|||
#include <LibWeb/CSS/StyleValues/LinearGradientStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/MathDepthStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/NumberStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/OpenTypeTaggedStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/PercentageStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/PositionStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/RadialGradientStyleValue.h>
|
||||
|
@ -244,6 +245,12 @@ NumberStyleValue const& CSSStyleValue::as_number() const
|
|||
return static_cast<NumberStyleValue const&>(*this);
|
||||
}
|
||||
|
||||
OpenTypeTaggedStyleValue const& CSSStyleValue::as_open_type_tagged() const
|
||||
{
|
||||
VERIFY(is_open_type_tagged());
|
||||
return static_cast<OpenTypeTaggedStyleValue const&>(*this);
|
||||
}
|
||||
|
||||
PercentageStyleValue const& CSSStyleValue::as_percentage() const
|
||||
{
|
||||
VERIFY(is_percentage());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue