mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 19:57:44 +00:00
PixelPaint: Relate cursor to brush tool size
This patch changes the cursor for the brush tool to a circle of dynamic size to indicate the region where the tool will apply color changes.
This commit is contained in:
parent
e9ca641d45
commit
e520b9c3a3
6 changed files with 87 additions and 6 deletions
|
@ -25,6 +25,7 @@ public:
|
|||
protected:
|
||||
virtual Color color_for(GUI::MouseEvent const& event) override;
|
||||
virtual void draw_point(Gfx::Bitmap& bitmap, Gfx::Color const& color, Gfx::IntPoint const& point) override;
|
||||
virtual NonnullRefPtr<Gfx::Bitmap> build_cursor() override;
|
||||
|
||||
private:
|
||||
virtual StringView tool_name() const override { return "Erase Tool"sv; }
|
||||
|
@ -35,7 +36,7 @@ private:
|
|||
Pencil,
|
||||
Brush,
|
||||
};
|
||||
DrawMode m_draw_mode { DrawMode::Brush };
|
||||
DrawMode m_draw_mode { DrawMode::Pencil };
|
||||
bool m_use_secondary_color { false };
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue