Skip to content
Myr

render: set clip region when rendering SVG icons using librsvg >= 2.46

Before adoption: this commit came in with the history the project adopted, so no landing records it.

This is already being done for older librsvg versions (and doesn’t apply to the nanosvg backend). Not doing this means SVG icons containing multiple icons aren’t contained properly. I.e. all the variously sized sub-icons are rendered all over the fuzzel window. Closes #48

authored by Daniel Eklöf · committed by Daniel Eklöf · parent 18b7d9b · Browse files · 2 files+6 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+6 added−0 removed

  • other:+6 added−0 removed

2 files+6 added−0 removed

modified:CHANGELOG.md+2 added
33 unmodified lines
34### Fixed3536* Graphical corruption triggered by the “gerbview” SVG icon, from37 KiCAD (https://codeberg.org/dnkl/fuzzel/issues/47).38* SVG icons containing multiple icons not being limited to the main39 icon (https://codeberg.org/dnkl/fuzzel/issues/48).404142### Security43### Contributors
182 unmodified lines
modified:render.c+4 added
287 unmodified lines
288 .y = y,289 .width = size,290 .height = size,291 };292293 cairo_rectangle(buf->cairo, x, y, size, size);294 cairo_clip(buf->cairo);295296 rsvg_handle_render_document(svg, buf->cairo, &viewport, NULL);297 }298 #else299 RsvgDimensionData dim;
385 unmodified lines