mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 12:49:19 +00:00
LibWeb: Add CanvasRenderingContext2D's origin-clean flag
This commit is contained in:
parent
6521c04bf3
commit
ed03f37ae9
Notes:
sideshowbarker
2024-07-17 17:56:16 +09:00
Author: https://github.com/linusg
Commit: ed03f37ae9
Pull-request: https://github.com/SerenityOS/serenity/pull/12875
Reviewed-by: https://github.com/awesomekling ✅
2 changed files with 5 additions and 0 deletions
|
@ -31,6 +31,7 @@ CanvasRenderingContext2D::~CanvasRenderingContext2D()
|
|||
|
||||
void CanvasRenderingContext2D::set_fill_style(String style)
|
||||
{
|
||||
// FIXME: 2. If the given value is a CanvasPattern object that is marked as not origin-clean, then set this's origin-clean flag to false.
|
||||
m_drawing_state.fill_style = Gfx::Color::from_string(style).value_or(Color::Black);
|
||||
}
|
||||
|
||||
|
@ -63,6 +64,7 @@ void CanvasRenderingContext2D::clear_rect(float x, float y, float width, float h
|
|||
|
||||
void CanvasRenderingContext2D::set_stroke_style(String style)
|
||||
{
|
||||
// FIXME: 2. If the given value is a CanvasPattern object that is marked as not origin-clean, then set this's origin-clean flag to false.
|
||||
m_drawing_state.stroke_style = Gfx::Color::from_string(style).value_or(Color::Black);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue