summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibGfx/CMakeLists.txt
diff options
context:
space:
mode:
authorMacDue <macdue@dueutil.tech>2023-01-10 01:07:06 +0000
committerAndreas Kling <kling@serenityos.org>2023-01-10 10:25:58 +0100
commitc8c065b6b0c30dcc51a6e944c64921942a90c34c (patch)
tree0bcbf9c00a1aa021cfbb0ae716ba71d4bc83fdcf /Userland/Libraries/LibGfx/CMakeLists.txt
parent668204041b92661e73d16ae37359b4854cdd9e76 (diff)
downloadserenity-c8c065b6b0c30dcc51a6e944c64921942a90c34c.zip
LibWeb+LibGfx: Migrate (most of) the CSS gradient painting to LibGfx
This moves the CSS gradient painting to the painter creating: - Painter::fill_rect_with_linear_gradient() - Painter::fill_rect_with_conic_gradient() - Painter::fill_rect_with_radial_gradient() This has a few benefits: - The gradients can now easily respect the painter scale - The Painter::fill_pixels() escape hatch can be removed - We can remove the old fixed color stop gradient code - The old functions are now just a shim - Anywhere can now easily use this gradient painting code! This only leaves the color stop resolution in LibWeb (which is fine). Just means in LibGfx you have to actually specify color stop positions. (Also while here add a small optimization to avoid generating excessively long gradient lines)
Diffstat (limited to 'Userland/Libraries/LibGfx/CMakeLists.txt')
-rw-r--r--Userland/Libraries/LibGfx/CMakeLists.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/Userland/Libraries/LibGfx/CMakeLists.txt b/Userland/Libraries/LibGfx/CMakeLists.txt
index f51e7e9ca1..8b8379e6f8 100644
--- a/Userland/Libraries/LibGfx/CMakeLists.txt
+++ b/Userland/Libraries/LibGfx/CMakeLists.txt
@@ -25,6 +25,7 @@ set(SOURCES
Font/ScaledFont.cpp
Font/Typeface.cpp
Font/WOFF/Font.cpp
+ GradientPainting.cpp
GIFLoader.cpp
ICCProfile.cpp
ICOLoader.cpp