mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:27:35 +00:00
LibWeb: Add Canvas Context2D basic font property support
This commit is contained in:
parent
b05fe22d39
commit
bba14f6014
7 changed files with 181 additions and 27 deletions
|
@ -100,6 +100,9 @@ public:
|
|||
virtual float global_alpha() const override;
|
||||
virtual void set_global_alpha(float) override;
|
||||
|
||||
HTMLCanvasElement& canvas_element();
|
||||
HTMLCanvasElement const& canvas_element() const;
|
||||
|
||||
private:
|
||||
explicit CanvasRenderingContext2D(JS::Realm&, HTMLCanvasElement&);
|
||||
|
||||
|
@ -132,14 +135,13 @@ private:
|
|||
did_draw(draw_rect);
|
||||
}
|
||||
|
||||
RefPtr<Gfx::Font const> current_font();
|
||||
|
||||
PreparedText prepare_text(DeprecatedString const& text, float max_width = INFINITY);
|
||||
|
||||
Gfx::Painter* painter();
|
||||
Optional<Gfx::AntiAliasingPainter> antialiased_painter();
|
||||
|
||||
HTMLCanvasElement& canvas_element();
|
||||
HTMLCanvasElement const& canvas_element() const;
|
||||
|
||||
Gfx::Path rect_path(float x, float y, float width, float height);
|
||||
|
||||
void stroke_internal(Gfx::Path const&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue