mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibWeb: Use CSSPixelFraction
to represent aspect ratios
This allows us to retain perfect precision for aspect ratios derived from either the intrinsic sizes of replaced elements, or the `aspect-ratio` CSS property.
This commit is contained in:
parent
4fb209d25f
commit
34c5043cbe
Notes:
sideshowbarker
2024-07-16 20:31:50 +09:00
Author: https://github.com/Zaggy1024
Commit: 34c5043cbe
Pull-request: https://github.com/SerenityOS/serenity/pull/20943
22 changed files with 57 additions and 55 deletions
|
@ -74,7 +74,7 @@ private:
|
|||
// ^Layout::ImageProvider
|
||||
virtual Optional<CSSPixels> intrinsic_width() const override;
|
||||
virtual Optional<CSSPixels> intrinsic_height() const override;
|
||||
virtual Optional<float> intrinsic_aspect_ratio() const override;
|
||||
virtual Optional<CSSPixelFraction> intrinsic_aspect_ratio() const override;
|
||||
virtual RefPtr<Gfx::Bitmap const> current_image_bitmap(Gfx::IntSize = {}) const override;
|
||||
virtual void set_visible_in_viewport(bool) override;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue