mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:27:44 +00:00
LibWeb: Remove StyleValue::has/to_integer()
Only NumericStyleValue holds integers. I'm not sure our current distinction between NumericStyleValue holding an integer or non-integer is useful given it always returns a float. :thonk:
This commit is contained in:
parent
4ecf0b7768
commit
5cbf6eb930
5 changed files with 9 additions and 11 deletions
|
@ -294,14 +294,12 @@ public:
|
|||
bool has_auto() const;
|
||||
virtual bool has_color() const { return false; }
|
||||
virtual bool has_length() const { return false; }
|
||||
virtual bool has_integer() const { return false; }
|
||||
|
||||
virtual ErrorOr<ValueComparingNonnullRefPtr<StyleValue const>> absolutized(CSSPixelRect const& viewport_rect, Length::FontMetrics const& font_metrics, Length::FontMetrics const& root_font_metrics) const;
|
||||
|
||||
virtual Color to_color(Optional<Layout::NodeWithStyle const&>) const { return {}; }
|
||||
ValueID to_identifier() const;
|
||||
virtual Length to_length() const { VERIFY_NOT_REACHED(); }
|
||||
virtual float to_integer() const { return 0; }
|
||||
virtual ErrorOr<String> to_string() const = 0;
|
||||
|
||||
[[nodiscard]] int to_font_weight() const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue