Skip to content

Conversation

ThomasAdam
Copy link
Member

@ThomasAdam ThomasAdam commented Dec 7, 2024

In the librsvg API calls for >=2.52, the newer API of
handle_get_intrinsic_size_in_pixels() doesn't set the default
width/height of the image if none is supplied.

In this case, set those to a default value based on that the viewbox attribute suggests.

If that cannot be found, bail.

Fixes #1133

@ThomasAdam ThomasAdam added this to the 1.1.2 milestone Dec 7, 2024
@ThomasAdam ThomasAdam marked this pull request as draft December 7, 2024 09:30
@ThomasAdam ThomasAdam self-assigned this Dec 7, 2024
@ThomasAdam ThomasAdam added the type:bug Something's broken! label Dec 7, 2024
In the librsvg API calls for >=2.52, the newer API of
handle_get_intrinsic_size_in_pixels() doesn't set the default
width/height of the image if none is supplied.

In this case the viewbox attribute of the SVG file can be used to
determine the width/height.

If the viewbox attribute isn't present the image is not processed
further.

Fixes #1133
@ThomasAdam ThomasAdam marked this pull request as ready for review December 12, 2024 16:30
@ThomasAdam ThomasAdam merged commit ddc4ab0 into main Dec 12, 2024
12 checks passed
@ThomasAdam ThomasAdam deleted the ta/gh-1133 branch December 12, 2024 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something's broken!
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[FVWM 1.1.1] Crash when using SVG images {fvwm3: calloc: zero size}
1 participant