-
Notifications
You must be signed in to change notification settings - Fork 82
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
no svg validation if jock.svg
is also installed
#805
Comments
Fixes redhat-developer#805 Signed-off-by: azerr <[email protected]>
Fixes #805 Signed-off-by: azerr <[email protected]>
Thx for your fast fix. Release it 🚀 |
@BuZZ-dEE once build we be done you will able to install vscode-xml prerelease to enjoy with this fix |
Hi @angelozerr I will try it, but what do I need from: releases/tag/latest ? |
It works now. (Content from hovering over the |
Thanks for your feedback. The problem now is with completion. You will see 2 duplicate completion item for the same element which comes from jock.svg and vscode-xml. I think vscode-xml could support the same feature than jock.svg like better hover documentation and color for rgb attribute. I will see if jock.svg could be interested to delegate thise features to vscode-xml |
@angelozerr I have created lishu/vscode-svg2#129 just to make vscode-svg2 / |
@BuZZ-dEE |
@lishu have you svg validation which is working? Could you share your svg file please. It requires the svg namespace if I remember |
Could you share please your svg file |
I tested it and you can see duplicate completion items: Here my svg file: <?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg width="5cm" height="4cm" version="1.1"
xmlns="http://www.w3.org/2000/svg">
<a xlink:href=""></a>
<desc>Four separate rectangles
</desc>
<a
<rect x="0.5cm" y="0.5cm" width="2cm" height="1cm"/>
<rect x="0.5cm" y="2cm" width="1cm" height="1.5cm"/>
<rect x="3cm" y="0.5cm" width="1.5cm" height="2cm"/>
<rect x="3.5cm" y="3cm" width="1cm" height="0.5cm"/>
<!-- Show outline of canvas using 'rect' element -->
<rect x=".01cm" y=".01cm" width="4.98cm" height="3.98cm"
fill="none" stroke="blue" stroke-width=".02cm" />
</svg> You can notice you need to declare DOCTYPE. Is the validation working for you? |
I noticed in the log the same error than you, but is is working for me. We need to invesitgate this error log. |
I noticec that the first completion item a (coming from vscode-xml) generates:
which is valid according to the DTD, although your extension generates:
which seems not be valid. Is it allowed? |
Yes, my svg doesn't use
|
LemMinx doesn't provide a specific SVG support, so you need to declare the DOCTYPE with the proper DTD. But it is possible to write a little Java LemMinx extension which does that. But I think you will not be interested to provide that. My another idea is to gives the capability to do that with package.json in your extension point (no dependency to vscode-xml), but before developping that, we need some user requirements. |
There are many conflicts between the standards under HTML and the XML standard, so it is indeed a problem that is not easy to handle 🤣 |
No svg validation if
jock.svg
is also installed. If for example thesvg
has a group and you remove the end tag</g>
, then you get no error, so the validation does not work.The text was updated successfully, but these errors were encountered: