-
Notifications
You must be signed in to change notification settings - Fork 136
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
Corrupted rendering of Verovio SVG output #284
Comments
SVG:
XAML:
The full shape reappears when |
I edit with post to avoid fragmentation of information. 1) Font SMuFLMaybe there is an issue with the font used by Verovio specified by SMuFL.
The bounding box is (0, -133, 314, 266). The glyph path is defined as: It seems there is a mismatch between the bounding box and the viewBox. The viewBox can only clip the shape. Using Fontforge to edit the font, I see that it is how it is defined, with paths in positive and negative Ys. So maybe an easier way is to adapt the renderer. 2) Overflow attributeThe issue may come from the handling of the overflow attribute. The header of Verovio SVG ouput has overflow set to visible. I understand the paths outside the viewBox of a symbol should not be clipped. Documentation about overflow at mozilla.org
But the rendering in WpfSvgTextBox clips the shape. I looked at the source code. In WpfRendering.cs, line 330 and 353 are comments about outdated SVG specification of overflow. It looks complex to implement. |
@raiatea Thanks for researching this issue. |
Hello,
Issue: SVG files are not correctly rendered in SharpVectors, but are correctly rendered by any online SVG viewer in a webbrowser.
The SVG files are produced by Verovio a C++ music score rendering library (https://github.com/rism-digital/verovio).
Process: Verovio MEI file -> SVG file -> SharpVectors SVG rendering
Last github releases of SharpVectors and Verovio are build with VS2022.
Verovio has a test suite, I attached the first sample accid-001, the Verovio SVG output accid-001.zip
Screenshots of renderings of SVG by an online SVG viewer and WpfSvgTestBox:
Online viewer in webbrowser:
WpfSvgTestBox:
The text was updated successfully, but these errors were encountered: