octave-patch-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-patch-tracker] [patch #8640] Comments for translators


From: Felipe G. Nievinski
Subject: [Octave-patch-tracker] [patch #8640] Comments for translators
Date: Sun, 05 Apr 2015 05:15:45 +0000
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.115 Safari/537.36

Follow-up Comment #1, patch #8640 (project octave):

Explaining the syntax adopted. 
tr()'s second input argument is now meant for string disambiguation:

<http://doc.qt.io/qt-5/i18n-source-translation.html#translator-comments>
> The recommended way to add comments is to annotate the tr() calls in
> your code with comments of the form:
> 
>     //: ...
> 
> or
> 
>     /*: ... */
> 
> Examples:
> 
>     //: This name refers to a host name.
>     hostNameLabel->setText(tr("Name:"));
> (...)
> You can [also] use the keyword TRANSLATOR for translator comments. 


The .ui files are a little more complicated:

<https://code.launchpad.net/~dpm/intltool/add-qtdesigner-support/+merge/145112>
78      +    ### For translatable Qt Designer XML files ###
79      +    #
80      +    # Specs:
81      +    # 
82      +    # -
http://qt-project.org/doc/qt-5.0/qtlinguist/linguist-ts-file-format.html
83      +    # -
http://qt-project.org/doc/qt-5.0/qtdesigner/designer-ui-file-format.html
84      +    #
85      +    # <string> tag attributes:
86      +    #
87      +    # notr="true" means the string is not translatable
88      +    # extracomment maps to a developer comment in gettext
89      +    # comment corresponds to "disambiguation" in the Qt Linguist API, 
and
maps
90      +    # to msgctxt in gettext

<http://tsdgeos.blogspot.com.br/2011/05/qt-designer-texts-disambiguation-vs.html>
Qt Designer has two fields regarding translations for text properties:
"disambiguation" and "comment"; they confusely map respectively to XML
attributes "comment" (for disambiguation) and "extracomment" (for
developer/translator comment) in the .ui file) [quote edited for clarity]


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/patch/?8640>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]