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

InkStitch SVG Namespace and mediawiki #200

Closed
danielkschneider opened this issue Jun 14, 2018 · 5 comments
Closed

InkStitch SVG Namespace and mediawiki #200

danielkschneider opened this issue Jun 14, 2018 · 5 comments
Labels
question Inform there is a question on how to or how is made

Comments

@danielkschneider
Copy link
Collaborator

Hi
I noticed that you added a inkstitch namespace in the SVG (I think during "Print"). Do you plan to keep this (xmlns:inkstitch="http://inkstitch.org/namespace") ?

I am asking because MediaWiki has a whitelist of legit namespaces and I plan to ask them if they could include it. Before doing so, I ask here what you think of it.

If the inkstitch namespace is not whitelisted, any mediawiki will refuse loading a SVG file.

https://www.mediawiki.org/wiki/Manual:UploadBase.php
https://phabricator.wikimedia.org/source/mediawiki/browse/master/includes/upload/UploadBase.php (line 1535)

  • greetings Daniel

PS: A similar discussion about XHTML which explain why they do not want some namespaces.
mgeb/mediawiki-drawio-editor#1

@danielkschneider danielkschneider added the question Inform there is a question on how to or how is made label Jun 14, 2018
@tatarize
Copy link

I would guess that for now it's simply a requirement of the way the format is setup that it needs a bunch of saveable flags to make the format able to reload with the same given settings. I would guess it's not fully baked yet. I recall back when I seriously considered using SVG for a metaformat to capture all forms of embroidery before scrapping the idea because of what became obvious shortfalls to the paradigm, it was pretty clear that any attempt at extending SVG in the manner here would tend to fall into "Foreign Object" and "switch" paradigms. Though I'm not sure if inkscape cares for that. Much like most embroidery formats it would, in theory, save all the individual stitches and save the filled vector object, and simply switch between them depending on whether it supported the given namespace.

I'd guess therefore any further movement down this design path would require a namespace. If for no other reason than to allow the proper description of non-vector elements like embroidery fills. SVG does allow you to write files properly wherein they will just load as normal vector objects (either shapes/paths or indvidual stitches) for those that don't accept the embroidery namespace and would just load as vector objects with explicit fills for those that do.

@lexelby
Copy link
Member

lexelby commented Jun 15, 2018

@danielkschneider I do plan to keep the namespace. In fact, I've been meaning to write up a ticket for migrating the existing xml attributes used by Ink/Stitch to be in the namespace. Everything's embroider_<stuff>, because when I originally wrote it, I didn't know about XML namespaces. :)

@danielkschneider
Copy link
Collaborator Author

Right that makes sense :)

If you got time and energy it might be a good idea to do that soon, before the whole planet will use Ink/Stitch and then would have to update the SVG code ;) Same is true for the examples on the website.

Also: You might at some consider putting some propaganda in the URL, e.g. a one liner that explains what it is. Alternatively sometimes in the far future, an XML Schema. The Schema might be useful for folks who dynamically want to create Ink/Stitch SVG and then validate (but programmers usually don't like schemas ...).

@lexelby
Copy link
Member

lexelby commented Jun 16, 2018

Great points! I've created #201 and #202 to capture your ideas. Your idea of getting Ink/Stitch's namespace whitelisted on mediawiki sounds good to me. Do you know of any other XML namespace registries that we should submit it to?

@danielkschneider
Copy link
Collaborator Author

danielkschneider commented Jun 18, 2018

No I do not, but I just submitted a request to Mediawiki, hopefully in the right way :)

https://phabricator.wikimedia.org/T197595

The following may help convince someone:

mediawiki_logo_reworked_embroidery

https://edutechwiki.unige.ch/en/InkStitch_-_embroidery_logos

@kaalleen kaalleen changed the title InkStitch SVG Namespace InkStitch SVG Namespace and mediawiki May 16, 2020
@lexelby lexelby closed this as completed Jul 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Inform there is a question on how to or how is made
Projects
None yet
Development

No branches or pull requests

3 participants