Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extract and use height and width of SVG images #3

Open
bowman2001 opened this issue Nov 11, 2023 · 0 comments
Open

Extract and use height and width of SVG images #3

bowman2001 opened this issue Nov 11, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@bowman2001
Copy link
Owner

  1. Extract the values. There are two general ways to parse the SVG content as far as I can see:

    1. Use string functions with matching capabilities (findRE or maybe others) to isolate the width and height attributes or the viewBox.
    2. Use transform.Unmarshal to get the full data structure of the SVG.
  2. We need to collect and maybe calculate the values (viewBox) for the width and height.

  3. Add them to the image tag.

@bowman2001 bowman2001 added the enhancement New feature or request label Nov 11, 2023
@bowman2001 bowman2001 self-assigned this Nov 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant