Template talk:Translate

From Wikimedia Commons, the free media repository
Jump to: navigation, search

This is the discussion page of the template {{Translation possible}}. Since it is an undiscussed one man project, I'd like to read comments about it. --Enricopedia 15:56, 7 December 2006 (UTC)

Nice idea, but I'm still waiting for on-wiki editing of SVG images (bug 5899)... There are some problems with UTF-8 capable text editors running under Windows, so it would be great (also) for this project, to have it available right through MediaWiki. BTW not all texts are stored as plain text (some are converted to paths). --Nux (talk··dyskusja) 00:35, 11 December 2006 (UTC)
Hi and thank you for the translation into Polish! I wanted to have the Learn_more page translated too but no one has ever done that for any other language.  ;) Yes, it would be nice to edit SVGs online! Let's see when they implement that. I tried editing SVG text with a simple text editor but it only works when you put UTF-8 characters. Anything else will break the SVG rendering. Thats why I didn't even mention it on the help page. Btw, let me put it under a new headline...  :) --Enricopedia 00:59, 11 December 2006 (UTC)

"Inside labels"?[edit]

Make the English explicit before you get translations. :( It is not clear what an "inside label" is. pfctdayelise (说什么?) 07:11, 11 December 2006 (UTC)

An inside label is a label that is included into the image. I took the term from the Convert to international template, where it's been used exactly the same way. You might tell me though, what would be better to use, since you are native speaker. --Enricopedia 10:02, 11 December 2006 (UTC)
I put embedded labels now. I guess that's better and translated it is the same of what I've used in the German version. --Enricopedia 10:48, 11 December 2006 (UTC)
There is no succinct term for what you mean, that I know of. I would put something like "embedded labels (text as part of the image itself)". Or just "embedded text"?? pfctdayelise (说什么?) 12:37, 11 December 2006 (UTC)
Okay, it's embedded text now. Simple.  :) --Enricopedia 17:55, 11 December 2006 (UTC)

Numeric labels[edit]

I've made the suggestion of numeric labels less emphatic: there is good reason to use labels in a given language, but numeric versions are valuable for being easily reusable.

Nbarth 00:03, 5 February 2008 (UTC)


"Gaphic data mistake will be unpossible to prevent" should be "Graphic data mistake will be unpossible to prevent". BernardM (talk) 09:22, 6 September 2008 (UTC)

Change the font of a specific language[edit]

Is it possible to change the font of a specific language (I mean languages like Persian having an arabic writing) to make texts more readable? --P30Carl (talk) 21:23, 7 January 2009 (UTC)


Since this template redirect here, I wonder if we have a template to indicate that an image should be translated (into English)? I've run into many images in less known languages that I'd like to tag as needed a translation, but I can't find the right template for that.--Piotr Konieczny aka Prokonsul Piotrus Talk 18:15, 18 February 2009 (UTC)

Well, hopefully, this template is enough. The idea is that it doesn't matter what language people translate into, that every new translation makes other translations more likely (lesser known languages → well-known languages → all languages). Having a "translate to English" template would be redundant. I can see other "translate to language" templates popping up and then we would have tagging mess. If you think it would be beneficial to single out images lacking an English translation (which greatly widens the circle of potential new translations), maybe create a project page gallery? Rocket000 (talk) 16:14, 3 August 2009 (UTC)

Whenever one does something, there is the risk for a mess, that doesn't mean there shouldn't be any. This template is well intended, but too vague by itself, and limits only to SVG files, where some files may not be, and may not have the possibility of being converted in such a format, and still need translation.

Secondly, this template only says one could, if he really wants to, to translate an image, and in no means lets someone ask the valid question of translating something. There are subtemplates translated and encouraged for templates, why not for the text in pertinent images?

Thirdly, the main language of this project is English, and this is mainly asked of all users - to know at least English. Now, while those people really bothered in making their files in their own language and it's respectable, most of the users on Commons won't understand what it means (with few exceptions, where the words may be similar, but again, that's still going almost blind).

So considering all this, there should be a tag for translation requests at least from another language into English, if some would think from English to other languages would be too "messy". --Anime Addict AA (talk) 19:51, 14 October 2009 (UTC)

Right way?[edit]

I'm glad that here is activity about translating descriptions, but I'm not sure if it is right way. What about changing image in the future - change needs to be done in every image separatly (if I understand system of translating correctly). Or there is some tool for this? If not so, I happier if there would be some special codes in image which would be dynamicly replaced by translation from separate place (file), so there would be possible to generate both versions (with embedded texts and also version with numbers) from one source. ■ Jan Šebetovský 19:01, 7 October 2009 (UTC)

Can this be used on non-SVG fies?[edit]

For examples, gifs tagged with {{SVG}}? --Piotr Konieczny aka Prokonsul Piotrus Talk 23:05, 15 December 2009 (UTC)

Sorry, no it cannot. This tag is designed for SVG files that can be easily translated, not GIFs that are waiting to be converted to SVG. ~a (usertalkcontribs) 21:01, 11 February 2010 (UTC)

Proper procedure for uploading?[edit]

What is the proper procedure for uploading? E.g. for keeping track of versions, descriptions, copyright information, ... --Chire (talk) 08:52, 19 January 2011 (UTC)

Inactivity of Nikola: SVG translate needs of a new programmer please ![edit]

(Please, keep the talk here.)

Hello wikipedians and uploaders,

While SVG translate is a very convenient and High potential tool, I noticed that user:Nikola_Smolenski have largely withdraw his implication from coding SVG translate, this inactivity recently automatically closed SVG translate. The development is also stale, since, de facto, nobody is leading it. As a wikigraphist, I look SVG translate as a fundamental tool which need strong support, and further development. Also, I strongly encourage an active programmer to : 1. copy the SVG translate code to his own toolserver account ; 2. change {{Translation possible}}'s link accordingly ; 3. to continue development according to meaningful requests. 4. It's integration within Luxo's http://toolserver.org/~luxo/derivativeFX (auto upload) would be higly beneficial. Yug (talk) 08:27, 23 January 2011 (UTC)

Please, if you want to copy and manage SVG translate, just do it, and notice everyone here ;)
Jarry1250 who coded SVG Check might be a candidate. --Leyo 14:40, 23 January 2011 (UTC)
I can certainly take a look at rehosting the existing code corpus, but I don't know about developing it further. That might demand too much of my time, I don't know really. Jarry1250 (talk) 20:08, 13 March 2011 (UTC)
Ok, thanks. Rehosting is already a good step to secure this code. After, we need to continue to look for an active programmer. Yug (talk) 13:32, 18 March 2011 (UTC)
The implementation of this script is probably not too difficult. --Leyo 14:03, 18 March 2011 (UTC)

Records and Merging with DerivativeFX[edit]

(Copied from Nikola's inactive talk page)

Hello Nikola, Already 2 years since our last talk. Im just wondering, since then :

  • Do you save the translations ?
  • Do you have the count of usage of your tool ?
  • Did you considered a collaboration with Luxo to provide automatic upload ?
  • others interesting issues : lets me know :D

Regards, Yug (talk) 09:29, 4 May 2010 (UTC)

Toolserver user nikola[edit]

(Copied from Nikola's inactive talk page)

Toolserver expired your account automatically because you have been inactive for over six months there. Big fan here of your tools. If you log in there every 5 months or so and make post, your hard tookserver work can remain live for the benefit of your followers. Thanks! -- Uzma Gamal (talk) 13:14, 2 December 2010 (UTC)

From this, it looks like you last modified sredjivanje.csv on 14 Nov 2010, which seems to be within the last 6 months. Perhaps toolserver's automatic expiring tool is out of wack. -- Uzma Gamal (talk) 13:23, 2 December 2010 (UTC)
SVGTranslate is working… --Leyo 16:58, 3 December 2010 (UTC)

Displaying a thumbnail in SVGTranslate[edit]

(Copied from Nikola's inactive talk page)

Hi Nikola. What about displaying a thumbnail in SVGTranslate? This would facilitate to translate from a language a users does not understand and act like a confirmation that the right image was selected. In this tool, a thumbnail is shown. --Leyo 17:04, 4 February 2010 (UTC)

Please include this script to get this feature. --Leyo 23:41, 5 December 2010 (UTC)

DerivateFX should integrate SVG translate[edit]


I already praised DerivateFX and SVG translate as two wonderful tools for graphists here. However, both have lowly active (DFX, Luxo) or totally inactive (SVG translate, Nikola) programmers, respectively Luxo, and Nikola. Since a translation is de facto a derivation, SVG translate should be integrated to DFX to allow automatic and instant upload with proper license of those derivate files. Accordingly, and since the codes are free, out of Luxo, do you know some potential programmers to do this work ? Yug (talk) 08:47, 23 January 2011 (UTC)

I can not translate[edit]

I put the Template:translate possible, but I can't translate it please help. Could you please help to resolve this problem??? (Nisetpdajsankha (talk) 00:51, 16 September 2011 (UTC))

Which SVG file, the sentences/word are likely vectorized (they are not characters with a font anymore, but vectorial shapes), in such cases, the translation is impossible. Yug (talk) 14:20, 7 December 2011 (UTC)

Edit requested[edit]

The news place for the scirpt is http://toolserver.org/~jarry/svgtranslate/index.php? , Admins, please update the template's page. Yug (talk) 14:20, 7 December 2011 (UTC)

Done. Thanks to you and Jarry. --Leyo 14:31, 7 December 2011 (UTC)

2013 May's bug[edit]

The tool was bugging, a report have been send to en:User talk:Jarry ! Yug (talk) 15:59, 30 May 2013 (UTC)

Russian text[edit]

There must be SVG-файл instead of SVG файл. And Также instead of Так же. But it would be even better to replace Так же with Кроме того,. Stas000D (talk) 16:18, 6 October 2013 (UTC)

Done, the text can be edited by anyone at Template:Translate/ru. --Zolo (talk) 06:42, 7 October 2013 (UTC)

Update to mention support of <switch> statements[edit]

[[file:Gerrit_patchset 25838 test.svg|thumb]]
[[file:Gerrit_patchset 25838 test.svg|lang=de|thumb]]

Jarry1250 added support for <switch> statements in mediawiki's svg support, which allows multiple translations in a single file. This doc page should maybe be updated to talk about this. Bawolff (talk) 21:43, 20 October 2013 (UTC)

Ideally the presentation page in the File namespace should autodetect that the file has one or several translations built in, and then should include a combobox to list and select the language to view (with the preselection according to the current user's UI language).
The File page can already parse some content types, e.g. it can render the embedded tags in a JPEG photo: it should be able to parse an SVG file as well to get its list of languages.
Once we click the combobox, a new thumbnail would be made and rendered with this lang parameter, without even having to document this list in the wiki description page itself, and the generated links proposing to download/view the SVG rendered as PNG in several resolutions should use this language selected in the combobox.
The language selection combobox (with label "This file embeds several languages: (en) English") should be placed beside the existing "add a note" button.
If you use it to select another language, it should not change the UI language to render the new thumbail:
  • if javascript is enabled, it will load the new thumbnail in situ without reloading the whole page (and it will update in situ the displayed links to the SVG rendered as PNG in several resolutions ),
  • otherwise it will reload the page with URL query parameter "filelang=*", its default value being the UI language selectable separately by URL query parameter "uselang=*" whose behavior is unchanged.
  • the file is first parsed to get the list of languages; its first language is used as the initial default value of "filelang"; if this parsing fails or returns an empty list, the defaul "filelang" will remain empty in the following steps.
  • if the File page is queried without any "uselang=*" or "filelang" parameter, it will use the user's prefered language (if connected) or the default wiki language (English on Commons) only if this language is in the list of embedded languages.
  • if the File page is queried with a value of "uselang=*" that does not math one of the embedded languages, this parameter is ignored for selecting the image thumbnail URL to render, otherwise it becomes the defult value to use for "filelang"
  • if the File page is queried with a value of "filelang=*" that does not match one of the embedded languages, this parameter will be completely ignored and replaced by the default value of "filelang".
  • then the File page can render the HTML image element with the correct vlue for the URL matching this language; it will correctly generate the content and the preselection of the combo (if the list is not empty), and the links to rendered SVG with the correct language.
verdy_p (talk) 13:48, 22 October 2013 (UTC)
I agree this should be discoverable on the image page (It is with TranslateSVG extension, but that's probably not going to be enabled for a while). I may work on something along those lines if I have some time. I do not think associating the file's language with the user language is a good idea (I can just imagine the bugs: There's an error in this file, but it only shows up for me...). OTOH, Content language maybe. I think there's some performance concerns that need to be remedied before doing that though. Bawolff (talk) 15:09, 27 October 2013 (UTC)

{{editrequest}} I just prepared all sub-templates to support a new parameter which indicates that the file is translated using <switch> elements. The user will get initial instructions on how to use the new system and is directed to the help page Commons:Translation possible/Learn more (which still needs updating) and the Commons:Graphic Lab/Illustration workshop were we can help people to translate those files. This is how it will look:

Translate This file is translated using SVG <switch> elements. All translations are stored in the same file! Learn more.

To embed this file in your language (if available) use the lang parameter with the appropriate language code, e.g. [[Template talk:Translate|lang=en]] for the English version.

To translate this file into your language download the file to your computer, add your translation and re-upload it with the same name. You will find help in Graphics Lab if you're not sure how to do this.

العربية | Asturianu | Беларуская (тарашкевіца)‎ | Bosanski | Català | Čeština | Dansk | Deutsch | Ελληνικά | English | Esperanto | Español | Eesti | Euskara | فارسی | Suomi | Français | Galego | עברית | Hrvatski | Magyar | Հայերեն | Italiano | 日本語 | ქართული | ភាសាខ្មែរ | 한국어 | Ripoarisch | Lietuvių | Македонски | മലയാളം | Bahasa Melayu | Plattdüütsch | Nederlands | Norsk nynorsk | Norsk bokmål | Polski | Piemontèis | Português | Русский | Slovenščina | Shqip | Српски / srpski | Svenska | Türkçe | Українська | Tiếng Việt | 中文 | 中文(简体)‎ | +/−

I propose to use a named parameter called "switch" to adjust the template. Usage would then be as simple as writing {{Translate|switch=yes}}.

To activate the new parameter please change the template to read

  |{{#if:{{{switch|}}}|[[Category:Translation possible - SVG (switch)]]|[[Category:Translation possible - SVG]]}}
  |[[Category:Translation possible - to check]]}}</includeonly>

This also categorizes files tagged with switch=yes into Category:Translation possible - SVG (switch). --Patrick87 (talk) 04:28, 8 December 2013 (UTC)

I will migrate this template to the translate extension, so in future we only have to update Template:Translate/i18n and User:FuzzyBot will do the boring work for us. -- Rillke(q?) 15:51, 9 December 2013 (UTC)
btw, These types of files will have a language drop down on their description pages come Tuesday (You can see what it will look like at testwiki, e.g. testwiki:file:Gerrit_patchset_25838_test.svg). Bawolff (talk) 09:29, 13 December 2013 (UTC)
Bawolff, I am positively delighted! However, there seems to be a small (IMHO non-blocking DAU) bug: When pressing the Go-button without changing the select (so (default language) is selected), the result is a file description page without file shown: It attempts to show lang-345px-Gerrit_patchset_25838_test.svg.png and the select now also contains a blank entry which is selected by default. -- Rillke(q?) 08:43, 14 December 2013 (UTC)
Also happens when one switches back to "(default language)" from the localized version. --Patrick87 (talk) 13:05, 14 December 2013 (UTC)
Another small issue: On this file, the "(default language)" option is missing making it unavailable to select (potentially because an English version is explicitly given?). --Patrick87 (talk) 13:21, 14 December 2013 (UTC)
good catch on the default language thing. I've submitted Gerrit:101493 to fix that. For default language thing - yes that's the reason. It displays default language if its unclear what language the default content is (since the svg might have the non systemLanguage labelled be something other than english). At the moment we always use english as default language to pass to rsvg, so if we know there is something actually in english, we display the language as english instead of default. Maybe the interface should say "English (default)" in such a situation. Bawolff (talk) 19:07, 14 December 2013 (UTC)
So this is live on commons now (Images uploaded prior to code being live may have to be purged for the drop down to show up). The fix for the default language thing mentioned above is probably only going to come to commons on dec 31. I'm not exactly sure what the best approach would be to fixing Patrick's issue. I guess it should detect if there actually is a default fallback other then english and then add that is a (default language) option. anyways, I've filed that as bugzilla:58666 Bawolff (talk) 20:35, 18 December 2013 (UTC)
Language dropdown autodetect does not happen for File:First_Ionization_Energy.svg. Its first switch uses systemLanguage=en-US,en-GB,de,(default). Glrx (talk) 20:56, 21 December 2013 (UTC)
Actually purging the file description page made the language dropdown appear. However there seems to be a problem differentiating between en/en-GB/en-US. More work for User:Bawolff I suppose Face-wink.svg. --Patrick87 (talk) 21:29, 21 December 2013 (UTC)
Hmm, the svg spec states the following:
"Evaluates to "true" if one of the languages indicated by user preferences exactly equals one of the languages given in the value of this parameter, or if one of the languages indicated by user preferences exactly equals a prefix of one of the languages given in the value of this parameter such that the first tag character following the prefix is "-"."
However rsvg seems to do something else. It does the following to see if the language specified by user matches the systemLanguage attribute (After splitting up systemLanguage if it has commas. It goes through each systemLanguage in order until it finds one that matches using the following procedure): First it takes the language supplied by the user. If the user specified language is longer than the systemLanguage attribute, any letters in the user language code that come after the length of the systemLanguage code are thrown away. If that is an exact match, then this language is used. Otherwise it checks if there is a hyphen in the systemLanguage. If there is, anything after (And including) the first hyphen it is removed from the systemLanguage, and however many letters are needed to be removed from the user-specified language are removed to make them the same length. The languages are compared again. If its not a match, processing proceeds to the next systemLanguage code. Bawolff (talk) 23:12, 21 December 2013 (UTC)


{{Translate|switch=no}} is interpreted as {{Translate|switch=yes}}. ScotXW (talk) 11:11, 6 March 2014 (UTC)

That's "by design". The template simply checks if the parameter switch is given, the actual value does not matter. This is common practice, as additional checks only complicate code and decrease performance. If the image does not use <switch> tags (like most current images) there's no reason to specify this parameter; just omit it. --Patrick87 (talk) 12:09, 6 March 2014 (UTC)