Last modified: 2012-07-10 20:22:01 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T7899, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 5899 - Allow on-wiki editing of SVG images
Allow on-wiki editing of SVG images
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
File management (Other open bugs)
unspecified
All All
: Normal enhancement with 17 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 4702 5172 6452 7712 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-10 16:25 UTC by Nicholas
Modified: 2012-07-10 20:22 UTC (History)
23 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Nicholas 2006-05-10 16:25:37 UTC
I have suggestion:  I wish we could have a feature to edit 
SVG images "wikistyle", like we do for articles. It would 
help graphic artists immensely instead of repeatedly 
uploading images for minor changes. We could also clone XML 
content and translate text by this method for non-en wikis.
Comment 1 Brion Vibber 2006-05-10 23:37:06 UTC
I'm going to merge this into bug 5172.

*** This bug has been marked as a duplicate of 5172 ***
Comment 2 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-06-26 18:36:42 UTC
On Rob's orders (mostly), I'll change this into the centralized bug for
wikistyle SVG-editing.  Presumably it would be relatively easy to add parameters
once that's implemented, or something, because Rob told me to merge those in too.
Comment 3 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-06-26 18:36:57 UTC
*** Bug 6452 has been marked as a duplicate of this bug. ***
Comment 4 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-06-26 18:37:30 UTC
*** Bug 5172 has been marked as a duplicate of this bug. ***
Comment 5 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-06-26 18:37:40 UTC
*** Bug 4702 has been marked as a duplicate of this bug. ***
Comment 6 Marco 2006-06-26 18:39:02 UTC
We could create a new namespace "SVG:" or similar and could solve the problem on
this way.
Comment 7 Brian Kell 2006-06-26 19:48:52 UTC
This is a good idea, but it should still be possible to upload SVG files. Most
people who upload SVGs are going to make them in an external application; they
aren't going to edit all the path control points and things by hand. Of course,
then you run into the problem where some carefully hand-crafted SVG exists,
including parameters and other things, which has been built up over several
months by wiki-style editing, and someone comes along and improves the image
somehow with an external application and wipes out all the little tweaks that
have been made. Doing a diff to fix this problem would really be a pain, but I
can't think of a better way to do it.

Inserting parameters into an SVG file is also a tricky point, since SVG is an
XML application. If the parameters aren't done right, they could easily break
the validity of the XML. This would make it much more difficult to edit the SVG
file in an external application. Moreover, even if parameters are done in some
way that preserves XML validity, getting third-party editors to recognize them
(or maybe even ignore them gracefully) might be difficult.
Comment 8 Leon Weber 2006-06-26 19:56:45 UTC
Well, how's about an action=editsvg? This link could appear additionally on the
image description page.
Comment 9 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-06-26 20:09:17 UTC
SVG provides a standard mechanism for extensibility, using XML namespaces.  See
http://www.w3.org/TR/SVG11/extend.html.  This method would be the appropriate
one to use when storing SVGs on the server and possibly when allowing people to
download them, although of course not when serving them for actual display.  All
conformant SVG clients are required to ignore elements and attributes from
namespaces they don't recognize.

Conformance of parameter values should obviously be checked; typically it should
be possible to just escape everything inputted, unless there's some reason
entire tags or attributes need to be inserted.  If there is, that could perhaps
be dealt with by using different types of parameters for tag names, attribute
names, tag contents, and attribute contents.  Alternatively, you could allow
arbitrary text insertion at the parameter point and just make sure to validate
it before sending it on (passing an error or the parameter defaults if it
doesn't validate).  This is all something people more familiar with SVG than I
should have opinions on, but clearly there are some obvious ways to go about it.
Comment 10 Nux 2006-06-27 06:05:14 UTC
There could be some warning saying something like:
--
This SVG image was handcrafted and has some wiki-parameters in it. Please edit
it only if you know what you are doing.
--

This comment could be put in a description as a template by a creator/editor of
the SVG file. Would be similar to the one that is put in some complicated templates.
Comment 11 Ori Livneh 2006-07-07 03:02:00 UTC
It would be nice if we had a tool that grepped through an SVG for <text></text>
fields, and provided a text box for the editor to input a translation. Then the
user could save it under a different filename, like NorthAmericaMap-hebrew.svg.
The way I see it, there'd be action=editsvg? for raw editing of the SVG file,
and action=translatesvg? for translation, as per above.
Comment 12 Aryeh Gregor (not reading bugmail, please e-mail directly) 2006-10-26 02:39:51 UTC
*** Bug 7712 has been marked as a duplicate of this bug. ***
Comment 13 Stéphane Brunner 2007-02-19 13:44:10 UTC
On this image I have as a problem with arrow they are really small, in Firefox
or in Inkscape the arrows will be really bigger !!!

Is it the same bug, is there a work around ?
Comment 14 Platonides 2007-02-19 18:12:44 UTC
1. You should specify which is "this" image.
2. It has nothing to do with this bug. Seems to be a problem on rendering SVGs
as PNGs, thus a rsvg bug.
Comment 15 Stéphane Brunner 2007-02-19 18:26:35 UTC
Oups I forget it :
http://commons.wikimedia.org/wiki/Image:Compression_JPEG.svg

Effectively with rsvg-view I have the same problem :(

Then how to display arrows ?
Comment 16 Nux 2007-02-19 20:39:03 UTC
This is an _enhancement_ to allow editing a SVG file, this not about rendering
errors or any such things.
Comment 17 Stéphane Brunner 2007-02-20 07:21:07 UTC
Effectively but initially I post to Bug 5163, there where strange redirect !

Sorry
Comment 18 CyrilB 2007-08-15 16:41:23 UTC
Just a quick comment, which might be completely useless: why not use pgf? It is a LaTeX extension used to generate drawings, which has a svg export feature. It is very well documented, relatively clear syntax (for a latex extension...), and uses LaTeX which already generates the equations...

an example (not really appealing maybe): http://commons.wikimedia.org/wiki/Image:Switches_domain.svg

Cyril
Comment 19 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-08-15 18:14:54 UTC
Does it have SVG import too?  And lossless export (i.e., guaranteed round-tripping)?  If it's LaTeX-based foremost, then I suspect not.  In that case it may be nice for creating SVGs, but not editing existing ones.
Comment 20 Brion Vibber 2008-05-28 21:15:17 UTC
*** Bug 14320 has been marked as a duplicate of this bug. ***
Comment 21 Siebrand Mazeland 2008-10-27 23:33:54 UTC
Comment from bug 15721: Nowadays we have many different Versions of the same SVG image only with different descriptions. To keep images consistent it wold be really cool to have only one image for all languages, that only rendered for the different project languages. SVG supports this:
http://www.w3.org/TR/SVG/i18n.html
http://www.w3.org/TR/SVG/struct.html#SystemLanguageAttribute
Comment 22 Siebrand Mazeland 2008-10-27 23:34:01 UTC
*** Bug 15721 has been marked as a duplicate of this bug. ***
Comment 23 Martin Fischer 2009-06-21 23:58:19 UTC
Open Source online SVG editor
http://code.google.com/p/svg-edit/
Comment 24 Brion Vibber 2010-12-27 03:34:15 UTC
Current dev trunk includes the SVGEdit extension, which uses the above linked svg-edit to provide on-web editing from the file: page of any uploaded SVG file. It could use some more UI polish (and an update from svg-edit dev work which will add IE9 compatibility), but it's there and it works.
Comment 25 AnonMoos 2010-12-29 20:29:01 UTC
Hope it will have associated "history" and "compare versions" features, or it could be quite cumbersome to use.  Also, since this is actually an "uploading over previously-existing image version" function, and it could be a way for vandals to quickly and easily make images non-functional, I hope that there will be an option to restrict anonymous IPs and users registered for less than 4 days from using it...
Comment 26 Rainer Rillke @commons.wikimedia 2011-12-22 17:17:01 UTC
What’s necessary in order to activate this extension? (If it is not stable, this bug should not be marked as fixed.) I do not need a GUI. But when it's your goal to make SVG more popular, it should be easier editable. Most Windows users have serious problems when they should edit or even open a SVG. Sometimes you just have to exchange a few letters.

In the meantime, a lot of browsers natively support SVG. So an instant-preview would be also a nice feature. Feel free to make new bugs or whatever you think is appropriate.
Comment 27 Philosopher 2012-06-13 22:41:01 UTC
This has come up again at Commons recently - see https://commons.wikimedia.org/w/index.php?title=Commons:Help_desk&oldid=72593008#Modify_an_uploaded_SVG-file and https://commons.wikimedia.org/wiki/Commons:Village_pump#Editing_SVGs.27_text_as_wiki_pages

As mentioned above, this bug is either NOT fixed or we don't know how to use the fix....  

(I don't know if I'm supposed to do this or not, but I'm marking this as "REOPENED" in the hopes that it'll get some dev eyes on it.)
Comment 28 Alex Monk 2012-06-13 22:49:55 UTC
An extension was created for this: https://www.mediawiki.org/wiki/Extension:SVGEdit

It's not deployed on Wikimedia sites which is why you can't use it on commons yet.
Comment 29 Philosopher 2012-06-14 03:47:04 UTC
Cool.  How would we go about requesting that it be deployed?
Comment 30 Philosopher 2012-06-14 04:28:37 UTC
As a better thought - is it deployed on a test wiki or something where we could see how it works?
Comment 31 achim1999 2012-06-14 13:48:04 UTC
Sorry, this is a misunderstanding -- or better maybe Philosopher wanted a different thing than me, who triggered this reopen of this bug. Please see the link
[http://commons.wikimedia.org/wiki/Commons:Village_pump#Maintaining_(and_thus_editing)_SVGs'_text_like_wiki_articles].

I did create an account here and wrote this comment, because of
[http://commons.wikimedia.org/wiki/User_talk:Rillke#regarding modifying SVG-arcticle in wikimedia]'s advice. ~~~~
Comment 32 MZMcBride 2012-07-10 00:24:18 UTC
(In reply to comment #27)
> (I don't know if I'm supposed to do this or not, but I'm marking this as
> "REOPENED" in the hopes that it'll get some dev eyes on it.)

You're not supposed to do this. :-)

I'm going to go ahead and file a separate bug now about getting the SVGEdit extension reviewed and deployed to Wikimedia wikis.

I'm re-closing this bug as resolved/fixed. Please leave it that way.
Comment 33 MZMcBride 2012-07-10 00:29:53 UTC
Bug 38271 is now filed ("Review and deploy SVGEdit extension to Wikimedia wikis"). For some further background information regarding my closure of this bug and the filing of bug 38271, please see this mailing list post: <http://lists.wikimedia.org/pipermail/wikitech-l/2012-July/061683.html>.
Comment 34 Philosopher 2012-07-10 20:22:01 UTC
(In reply to comment #32)
Wasn't sure - userrights seem to be rather loose around here so it's not always clear what you are supposed to change and what you aren't.  Especially for us "drive-by users" of bugzilla.

Thanks for filing the new bug, though!

> (In reply to comment #27)
> > (I don't know if I'm supposed to do this or not, but I'm marking this as
> > "REOPENED" in the hopes that it'll get some dev eyes on it.)
> 
> You're not supposed to do this. :-)
> 
> I'm going to go ahead and file a separate bug now about getting the SVGEdit
> extension reviewed and deployed to Wikimedia wikis.
> 
> I'm re-closing this bug as resolved/fixed. Please leave it that way.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links