diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-11-14 22:33:41 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-11-14 22:33:41 -0600 |
commit | 0f92dd542b65bc910caaf190b7c623aa5158c86a (patch) | |
tree | 120ab7e08fa0ffc354ef58d100f79a33c92aa6e6 /doc/html/linguist-manual-4.html | |
parent | d796c9dd933ab96ec83b9a634feedd5d32e1ba3f (diff) | |
download | tqt3-0f92dd542b65bc910caaf190b7c623aa5158c86a.tar.gz tqt3-0f92dd542b65bc910caaf190b7c623aa5158c86a.zip |
Fix native TQt3 accidental conversion to tquit
Diffstat (limited to 'doc/html/linguist-manual-4.html')
-rw-r--r-- | doc/html/linguist-manual-4.html | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/html/linguist-manual-4.html b/doc/html/linguist-manual-4.html index 84814282d..b31088a13 100644 --- a/doc/html/linguist-manual-4.html +++ b/doc/html/linguist-manual-4.html @@ -102,7 +102,7 @@ body { background: #ffffff; color: black; } rbh = new TQRadioButton( tr("Enabled", "Hue frame"), this ); </pre> <!-- index Ctrl Key --><p>Ctrl key accelerators are also translatable:</p> -<pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#tquit">tquit</a>()), +<pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#quit">quit</a>()), <a href="qobject.html#tr">tr</a>("Ctrl+Q", "Quit") ); </pre> <p>It is strongly recommended that the two argument form of <tt>tr()</tt> is used for Ctrl key accelerators. The second argument is the only clue the translator has as to the function performed by the accelerator.</p> @@ -336,7 +336,7 @@ TRANSLATIONS = tt2_fr.ts \ <pre> ArrowPad *ap = new ArrowPad( this, "arrow pad" ); </pre> <p>We also call <tt>MainWindow::tr()</tt> twice, once for the menu item and once for the accelerator.</p> -<!-- index Ctrl Key --><!-- index Alt Key --><pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#tquit">tquit</a>()), +<!-- index Ctrl Key --><!-- index Alt Key --><pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#quit">quit</a>()), <a href="qobject.html#tr">tr</a>("Ctrl+Q", "Quit") ); </pre> <p>Note the use of <tt>tr()</tt> to support different keys in other languages. "Ctrl+Q" is a good choice for Quit in English, but a Dutch translator might want to use "Ctrl+A" (for Afsluiten) and a German translator "Strg+E" (for Beenden). When using <tt>tr()</tt> for Ctrl key accelerators, the two argument form should be used with the second argument describing the function that the accelerator performs.</p> @@ -452,7 +452,7 @@ TRANSLATIONS = tt3_pt.ts <pre> <a href="qwidget.html#setCaption">setCaption</a>( <a href="qobject.html#tr">tr</a>("Troll Print 1.0") ); </pre> <p>We must translate the window's caption.</p> -<pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#tquit">tquit</a>()), +<pre> file-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("E&xit"), qApp, SLOT(<a href="qapplication.html#quit">quit</a>()), <a href="qobject.html#tr">tr</a>("Ctrl+Q", "Quit") ); <a href="qpopupmenu.html">TQPopupMenu</a> *help = new <a href="qpopupmenu.html">TQPopupMenu</a>( this ); help-><a href="qmenudata.html#insertItem">insertItem</a>( <a href="qobject.html#tr">tr</a>("&About"), this, SLOT(about()), Key_F1 ); @@ -489,7 +489,7 @@ TRANSLATIONS = tt3_pt.ts <!-- index lupdate --><!-- index tt3_pt.ts --><p>Now run <a href="linguist-manual-2.html#2">lupdate</a> and open <tt>tt3_pt.ts</tt> with <em>TQt Linguist</em>. You should now see two changes.</p> <p>First, the translation source file now contains <em>three</em> "Enabled", "Disabled" pairs. The first pair is marked "(obs.)" signifying that they are obsolete. This is because these texts appeared in <tt>tr()</tt> calls that have been replaced by new calls with two arguments. The second pair has "two-sided" as their comment, and the third pair has "colors" as their comment. The comments are shown in the <em>Source text and comments</em> area in <em>TQt Linguist</em>.</p> <p>Second, the translation text "Ativado" and "Desativado" have been automatically used as translations for the new "Enabled" and "Disabled" texts, again to minimize the translator's work. Of course in this case these are not correct for the second occurrence of each word, but they provide a good starting point.</p> -<p>Change the second "Ativado" into "Ativadas" and the second "Desativado" into "Desativadas", then save and tquit. Run <a href="linguist-manual-2.html#3">lrelease</a> to obtain an up-to-date binary <tt>tt3_pt.qm</tt> file, and run Troll Print (or rather Troll Imprimir).</p> +<p>Change the second "Ativado" into "Ativadas" and the second "Desativado" into "Desativadas", then save and quit. Run <a href="linguist-manual-2.html#3">lrelease</a> to obtain an up-to-date binary <tt>tt3_pt.qm</tt> file, and run Troll Print (or rather Troll Imprimir).</p> <p align="center"><img align="middle" src="tt3_10_pt_good.png" width="208" height="177"> </p> <blockquote><p align="center"><em>Tutorial 3 Screenshot, "Troll Imprimir 1.0", (Good) Portuguese version</em></p></blockquote> @@ -537,7 +537,7 @@ TRANSLATIONS = tt3_pt.ts <li><p>Two-sided - unmarked, i.e. untranslated.</p> </ul></ul><p>Notice that <a href="linguist-manual-2.html#2">lupdate</a> works hard behind the scenes to make revisions easier, and it's pretty smart with numbers.</p> <p>Go over the translations in <tt>MainWindow</tt> and mark these as "done". Translate "<b>TROLL PRINT</b>" as "<b>TROLL IMPRIMIR</b>". When you're translating "Two-sided", press the <em>Guess Again</em> button to translate "Two-sided", but change the "2" into "Dois".</p> -<p>Save and tquit, then run <a href="linguist-manual-2.html#3">lrelease</a>. The Portuguese version should look like this:</p> +<p>Save and quit, then run <a href="linguist-manual-2.html#3">lrelease</a>. The Portuguese version should look like this:</p> <p align="center"><img align="middle" src="tt3_11_pt.png" width="198" height="187"> </p> <blockquote><p align="center"><em>Tutorial 3 Screenshot, "Troll Imprimir 1.1", Portuguese version</em></p></blockquote> |