Skip to content
This repository has been archived by the owner on Oct 30, 2021. It is now read-only.

stroke-dasharray : comma - space #113

Closed
JoKalliauer opened this issue Dec 16, 2017 · 9 comments
Closed

stroke-dasharray : comma - space #113

JoKalliauer opened this issue Dec 16, 2017 · 9 comments

Comments

@JoKalliauer
Copy link
Contributor

The librsvg-Render don't handle spaces in stoke-dasharray:
https://phabricator.wikimedia.org/T32033
therefore I need commas instead of spaces. (at least if the input are commas the output should also be) Maybe an option --renderer-workaround as in scour, or you can also always use commas, they need the same number of characters.

See also:
https://commons.wikimedia.org/wiki/Librsvg_bugs#stroke-dasharray

@RazrFalcon
Copy link
Owner

rsvg has a ton of bugs. Making workarounds for them is not my job. All I can do is to make an option to choose a separator for list-of-numbers/list-of-lengths data type.

@JoKalliauer
Copy link
Contributor Author

JoKalliauer commented Dec 16, 2017

I would say it is one of the most famous one, which is very easy to solve. And if I have a correct file, I don't want that it get messed up, you don't have to repair them, but you shouldn't produce meaningless Rendererrors.

scour, svgo and Inkscape keep the seperator of inputformat. (even if it mixed)

@RazrFalcon
Copy link
Owner

Well, svgcleaner is correct according to the SVG spec. It's purely the rsvg problem.

@JoKalliauer
Copy link
Contributor Author

Both specification are correct, but W3C uses commas on there website:
https://www.w3.org/TR/svg-strokes/#StrokeDashing

I'm not happy about it, but it is up on you if you want to change it.

@RazrFalcon
Copy link
Owner

There is nothing to change. is equal to , and to , in the SVG. All I can do is to add an option to choose a specific format.

RazrFalcon added a commit that referenced this issue Dec 18, 2017
@JoKalliauer
Copy link
Contributor Author

Thank you very much! :)

Is there a possibility to get the unreleased version?
(Sorry I'm not that familiar neither with Github nor compiling on my own, and I never heard rust before.)

[I'm using Cygwin (With cargo 0.23.0 (61fa02415 2017-11-22)), but if you could explain how it would work on Linux or Windows, I think I will manage on my own to get it run also in Cygwin.]

@RazrFalcon
Copy link
Owner

RazrFalcon commented Dec 18, 2017

I think this should work:

cargo install --force --git https://github.com/RazrFalcon/svgcleaner --branch devel --bin svgcleaner

But it doesn't. Probably a cargo bug.

See: rust-lang/cargo#4830

@RazrFalcon
Copy link
Owner

@JoKalliauer

Seems like the working command is:

cargo install --force svgcleaner --git https://github.com/RazrFalcon/svgcleaner

@JoKalliauer
Copy link
Contributor Author

JoKalliauer commented Dec 23, 2017

@RazrFalcon : Thanks:

For me

cargo install --force --git https://github.com/RazrFalcon/svgcleaner --branch devel svgcleaner

worked.

Corrected: 2018:

cargo install svgcleaner --force --git https://github.com/RazrFalcon/svgcleaner

worked.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants