summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibGfx/Path.cpp
AgeCommit message (Collapse)Author
2021-09-18LibGfx: Implement cubic bezier curves by splitting them to subcurvesAli Mohammad Pur
This makes them significantly more nicer-looking, and fixes a FIXME :^)
2021-09-17LibGfx: Avoid invalidation when Path::close() is a no-opAndreas Kling
If the path is already closed, calling close() is a no-op, and we don't need to invalidate the split lines cache.
2021-09-15LibGfx: Add Path::cubic_bezier_curve_to()Andreas Kling
This is pretty unsophisticated as it will simply add a fixed number of of line segments approximating the curve. Still better than nothing.
2021-07-19Everywhere: Use AK/Math.h if applicableHendiadyoin1
AK's version should see better inlining behaviors, than the LibM one. We avoid mixed usage for now though. Also clean up some stale math includes and improper floatingpoint usage.
2021-05-07LibGfx: Convert StringBuilder::appendf() => AK::FormatAndreas Kling
2021-05-02LibGfx: Unify Rect, Point, and SizeMatthew Olsson
This commit unifies methods and method/param names between the above classes, as well as adds [[nodiscard]] and ALWAYS_INLINE where appropriate. It also renamed the various move_by methods to translate_by, as that more closely matches the transformation terminology.
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-04-16Everywhere: Add `-Wdouble-promotion` warningNicholas-Baron
This warning informs of float-to-double conversions. The best solution seems to be to do math *either* in 32-bit *or* in 64-bit, and only to cross over when absolutely necessary.
2021-04-15LibGfx+LibWeb: Wire up CanvasRenderingContext2D.ellipse()AnotherTest
Note that this is *extremely* naive, and not very good at being correct.
2021-04-15LibGfx+LibWeb: Move out the EllipticArcTo() logic into PathAnotherTest
At its previous state, the interface allowed invalid "ellipses" to be specified, instead of doing that, simply use the parameters that SVG uses :^)
2021-02-23Everywhere: Rename ASSERT => VERIFYAndreas Kling
(...and ASSERT_NOT_REACHED => VERIFY_NOT_REACHED) Since all of these checks are done in release builds as well, let's rename them to VERIFY to prevent confusion, as everyone is used to assertions being compiled out in release. We can introduce a new ASSERT macro that is specifically for debug checks, but I'm doing this wholesale conversion first since we've accumulated thousands of these already, and it's not immediately obvious which ones are suitable for ASSERT.
2021-01-12Libraries: Move to Userland/Libraries/Andreas Kling