diff --git a/Libraries/LibWeb/Painting/BorderPainting.cpp b/Libraries/LibWeb/Painting/BorderPainting.cpp index 311f5ea8452..958dfda028e 100644 --- a/Libraries/LibWeb/Painting/BorderPainting.cpp +++ b/Libraries/LibWeb/Painting/BorderPainting.cpp @@ -192,8 +192,11 @@ void paint_border(DisplayListRecorder& painter, BorderEdge edge, DevicePixelRect } case CSS::LineStyle::Groove: case CSS::LineStyle::Ridge: - // FIXME: Implement these - break; + // Two half-width borders + paint_double_border(0.5f, + border_style == CSS::LineStyle::Groove ? CSS::LineStyle::Inset : CSS::LineStyle::Outset, + border_style == CSS::LineStyle::Groove ? CSS::LineStyle::Outset : CSS::LineStyle::Inset); + return; } struct Points { diff --git a/Tests/LibWeb/Screenshot/expected/css-border-style-groove-ref.html b/Tests/LibWeb/Screenshot/expected/css-border-style-groove-ref.html new file mode 100644 index 00000000000..21a24c5d351 --- /dev/null +++ b/Tests/LibWeb/Screenshot/expected/css-border-style-groove-ref.html @@ -0,0 +1,10 @@ + + + diff --git a/Tests/LibWeb/Screenshot/expected/css-border-style-ridge-ref.html b/Tests/LibWeb/Screenshot/expected/css-border-style-ridge-ref.html new file mode 100644 index 00000000000..90c4bceae1c --- /dev/null +++ b/Tests/LibWeb/Screenshot/expected/css-border-style-ridge-ref.html @@ -0,0 +1,10 @@ + + + diff --git a/Tests/LibWeb/Screenshot/images/css-border-style-groove-ref.png b/Tests/LibWeb/Screenshot/images/css-border-style-groove-ref.png new file mode 100644 index 00000000000..e6fdb4f427b Binary files /dev/null and b/Tests/LibWeb/Screenshot/images/css-border-style-groove-ref.png differ diff --git a/Tests/LibWeb/Screenshot/images/css-border-style-ridge-ref.png b/Tests/LibWeb/Screenshot/images/css-border-style-ridge-ref.png new file mode 100644 index 00000000000..6fcfec509af Binary files /dev/null and b/Tests/LibWeb/Screenshot/images/css-border-style-ridge-ref.png differ diff --git a/Tests/LibWeb/Screenshot/input/css-border-style-groove.html b/Tests/LibWeb/Screenshot/input/css-border-style-groove.html new file mode 100644 index 00000000000..4d22bb03427 --- /dev/null +++ b/Tests/LibWeb/Screenshot/input/css-border-style-groove.html @@ -0,0 +1,14 @@ + + + + +
diff --git a/Tests/LibWeb/Screenshot/input/css-border-style-ridge.html b/Tests/LibWeb/Screenshot/input/css-border-style-ridge.html new file mode 100644 index 00000000000..daa085da607 --- /dev/null +++ b/Tests/LibWeb/Screenshot/input/css-border-style-ridge.html @@ -0,0 +1,14 @@ + + + + +