summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnotherTest <ali.mpfard@gmail.com>2021-04-15 04:03:59 +0430
committerAndreas Kling <kling@serenityos.org>2021-04-15 17:50:16 +0200
commit6c05d6d3706bc2d3ebda1fed641dfa9c903100f3 (patch)
tree1b90458396528888f9e68011a64a1fb190415550
parent598a6d46c7ac8a51a8c834ed0e2726feb9564233 (diff)
downloadserenity-6c05d6d3706bc2d3ebda1fed641dfa9c903100f3.zip
LibGfx: Add a Path::arc_to() helper
...That just uses elliptical_arc_to().
-rw-r--r--Userland/Libraries/LibGfx/Path.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/Userland/Libraries/LibGfx/Path.h b/Userland/Libraries/LibGfx/Path.h
index b9dd0b641d..52013ce7ff 100644
--- a/Userland/Libraries/LibGfx/Path.h
+++ b/Userland/Libraries/LibGfx/Path.h
@@ -155,6 +155,10 @@ public:
}
void elliptical_arc_to(const FloatPoint& point, const FloatPoint& radii, double x_axis_rotation, bool large_arc, bool sweep);
+ void arc_to(const FloatPoint& point, float radius, bool large_arc, bool sweep)
+ {
+ elliptical_arc_to(point, { radius, radius }, 0, large_arc, sweep);
+ }
void close();
void close_all_subpaths();