Last modified: 2014-09-23 19:46:52 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 26845 - Include language name placeholder in message livetranslate-translate-to
Include language name placeholder in message livetranslate-translate-to
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
LiveTranslate (Other open bugs)
unspecified
All All
: Normal enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
http://translatewiki.net/wiki/Thread:...
: i18n, patch, patch-reviewed
Depends on:
Blocks: messages
  Show dependency treegraph
 
Reported: 2011-01-21 14:52 UTC by Purodha Blissenbach
Modified: 2014-09-23 19:46 UTC (History)
5 users (show)

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


Attachments
Patch (1.71 KB, patch)
2012-02-21 12:13 UTC, Michael Movchin
Details

Description Purodha Blissenbach 2011-01-21 14:52:58 UTC
The message livetranslate-translate-to lacks a placeholder ($1) for the target language of the translation. It is not really feasible to make a phrase to which a language name could be appended giving a valid sentence in many languages.

See also: http://www.mediawiki.org/wiki/Localisation#Avoid_patchwork_messages


http://translatewiki.net/w/i.php?title=Support&offset=20110121132950#MediaWiki:livetranslate-translate-to_10589
is giving more - purely informational - details.
Comment 1 Jeroen De Dauw 2011-01-21 15:33:21 UTC
It's a valid point, although the target language can not simply be put in there. It's a HTML dropdown, not a simple word. See this image: https://secure.wikimedia.org/wikipedia/mediawiki/wiki/File:Lte-article.png

I don't know how I can put the dropdown in while properly escaping the message, so cannot fix this. Help is welcome though.
Comment 2 Purodha Blissenbach 2011-02-20 13:43:12 UTC
Thanks a lot, I've added a link to the image to the message documentations (qqq) of this message and 'livetranslate-translate' as well. This will help translators a lot.

With the help of the layout, I found an imho very elegant way that includes the "translate"-button in a sentence, which would not work this way in English due to word order constraints.

We can say: "Do this page into [und language-name ] [translate!]"

In English, "[Translate] this page into [zxx language]!" had an unintuitive order of inputs, opposite to word and reading order.

A more general approach could be to make the entire box a translatable message and another, like this in English:

'livetranslate-translate-to' => 'Translate this page to $1 $2',
'livetranslate-translate' => 'Translate',

Message documentation (qqq):

'livetranslate-translate-to' => 'Parameters:
* $1: an input (dropdown) to choose a language'
* $2: a klickable button with text {{msg-mw|livetranslate-translate}}
Note, this message appears as the only content in a floated box on every content page.',
'livetranslate-translate' => 'Used as button text inside paramter $2 in {{msg-mw|livetranslate-translate-to}}',

which allows language translators a maximum of flexibility placing the inputs and putting words around and between them, such as:

'livetranslate-translate-to' => 'You can machine-translate this page.<br />
Choose a language: $1, and then $2 with it!'
'livetranslate-translate' => 'go ahead',

I could quickly implement this, or something similar, if you like me to.
Comment 3 Michael Movchin 2012-02-21 12:13:35 UTC
Created attachment 10060 [details]
Patch

I just added a patch for this.
Comment 4 Sumana Harihareswara 2012-02-22 00:41:42 UTC
Adding "patch" and "need-review" keywords.
Comment 5 Jeroen De Dauw 2012-02-23 12:49:25 UTC
Thanks for the patch Michael.

I have some concerns though: these are only changes to the i18n file, which seem to need matching changes on other places as well. And I am doubtful this actually would work at all, since you can not pass HTML to messages as argument AFAIK. Did you test your modifications?
Comment 6 Mark Holmquist 2012-07-25 15:35:15 UTC
Michael,

Could you please address the concerns raised above, and possibly consider getting developer access [1] and submitting this patch through Gerrit, our code review tool? We'd really love to solve this issue and close the bug.

Thanks!

(adding Michael to the CC list, hopefully that wasn't a conscious decision on his part)

[1] http://www.mediawiki.org/wiki/Developer_access
Comment 7 Mark Holmquist 2012-08-14 17:05:45 UTC
OK, I'm almost certain that, while the patch accomplishes the goal of the bug, there are places where this message is used that will need to be updated before we can accept it.

If someone else wants to take this and run with it, please do so.
Comment 8 Andre Klapper 2014-02-24 17:25:26 UTC
[Removing "easy" keyword as per comment 7]

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


Navigation
Links