mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 17:27:34 +00:00
LibPDF: Fix paths with negatively sized re
(rect) commands
Turns out the width/height in a `re` command can be negative. This results in rectangles with different winding orders. For example, a negative width results in a reversed winding order. Previously, this was lost by passing the rect through an `AffineTransform` before constructing the path. So instead, this constructs the rect path, and then transforms the resulting path.
This commit is contained in:
parent
6a4dd8fa47
commit
d55867e563
2 changed files with 11 additions and 1 deletions
|
@ -155,6 +155,8 @@ private:
|
|||
template<typename T>
|
||||
ALWAYS_INLINE Gfx::Rect<T> map(Gfx::Rect<T>) const;
|
||||
|
||||
Gfx::Path map(Gfx::Path const&) const;
|
||||
|
||||
Gfx::AffineTransform calculate_image_space_transformation(int width, int height);
|
||||
|
||||
PDFErrorOr<NonnullRefPtr<PDFFont>> get_font(FontCacheKey const&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue