Commit graph

2 commits

Author SHA1 Message Date
Andreas Kling
ea6c0e431a LibWeb: Inline CSSPixels methods and optimize device pixel math
Make CSSPixels::to_float(), to_double(), and to_int() constexpr inline
instead of out-of-line in the .cpp file. These are trivial one-liners
called in very hot painting paths.

Also optimize DevicePixelConverter::rounded_device_rect() to work
directly with CSSPixels values instead of constructing an intermediate
Rect<double> and scaling it.
2026-02-21 15:53:22 +01:00
Timothy Flynn
93712b24bf Everywhere: Hoist the Libraries folder to the top-level 2024-11-10 12:50:45 +01:00
Renamed from Userland/Libraries/LibWeb/PixelUnits.cpp (Browse further)