Difference between revisions of "Localisation Sidebar"

From FreeCAD Documentation
Jump to: navigation, search
(Marked this version for translation)
m (link "Translate_the_FreeCAD_wiki" correction)
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
<languages/>
 
<translate>
 
<translate>
 
<!--T:1-->
 
<!--T:1-->
Localisation is in general the process of providing a Software with a multiple language user interface.
+
[[Localisation]] is the process of providing software with a multiple language user interface.
 +
The documentation wiki can also be localized, as described in section [[Localisation#Translate_the_FreeCAD_wiki|Translate the FreeCAD wiki]].
  
 
<!--T:2-->
 
<!--T:2-->
The Sidebar is an important navigation tool in the wiki world, as documented [http://www.mediawiki.org/wiki/Manual:Interface/Sidebar here].
+
The sidebar is an important navigation tool in the wiki world, see [http://www.mediawiki.org/wiki/Manual:Interface/Sidebar Manual:Interface/Sidebar] for more information.
  
 
==Translate the sidebar== <!--T:3-->
 
==Translate the sidebar== <!--T:3-->
  
 
<!--T:4-->
 
<!--T:4-->
The sidebar is now fully translatable with the [http://www.mediawiki.org/wiki/Help:Extension:Translate Translation plugin] usable for all the pages in the wiki.
+
The sidebar is now fully translatable with the [http://www.mediawiki.org/wiki/Help:Extension:Translate Translation extension], which is available in all pages of the wiki.
  
 
<!--T:5-->
 
<!--T:5-->
This feature is a bit of an hack, so if you want some technical details on the way it has been implemented, you can refer to [http://forum.freecadweb.org/viewtopic.php?f=21&t=9687&start=10#p80441 this post].
+
In the FreeCAD wiki, the sidebar is implemented using templates, which change the text depending on the selected language.
 +
Technical details on how this feature was implemented are described in the forum thread [http://forum.freecadweb.org/viewtopic.php?f=21&t=9687&start=10#p80441 Wiki navigation / translation].
  
 
===Instructions=== <!--T:6-->
 
===Instructions=== <!--T:6-->
  
 
<!--T:7-->
 
<!--T:7-->
You can go to the special page : [[Special:Translate/wiki-sidebar]] to begin translation.
+
You can go to the special page [[Special:Translate/wiki-sidebar]] to begin translation.
  
 
<!--T:14-->
 
<!--T:14-->
There is a bug with the Download page. You can't redirect the link to "Download/lang". Instead, the link will point to the actual translation of "Download" in your language. The best way to deal with it is to create this new page and do a redirection to the right page. More about redirection on [[Help:Editing]].
+
There is a bug with the Download page. You can't redirect the link to "Download/fr", or "Download/de", etc. Instead, the link will point to the actual translation of "Download" in your language.
 +
The best way to deal with it is to create this new page and do a redirection to the right page. More about redirection on [[Help:Editing]].
  
==Be carefull== <!--T:8-->
+
==Important notes== <!--T:8-->
  
 
<!--T:9-->
 
<!--T:9-->
You will find most of the time 2 strings for each item in the menu. One represent the text who is displayed in the sidebar, and the other is the target of the link.
+
Most of the time there will be two strings for each item in the sidebar.
 +
 
 +
<!--T:15-->
 +
<nowiki>** {{int:sidebar-faq-target}}|sidebar-faq</nowiki>
 +
 
 +
<!--T:16-->
 +
The left one represents the target of the link, and the right one represent the text that will be displayed in the sidebar.
  
 
<!--T:10-->
 
<!--T:10-->
You can see the difference between the two by looking on the top of the 'translate box' where the name of the variable is displayed.
+
You can see the difference between the two by looking at the top of the translate box where the name of the variable is displayed.
When the variable name ends with "-target", it mean that you are translating a target link. It's made to allow the allow the translator to redirect the items to the translated pages (by adding "/fr" after the name page for french translation for exemple).
+
When the variable name ends with "-target", it means that you will be translating a target link. It's made to allow the translator
 +
to redirect the items to the translated pages, that is, by adding a language code at the end of the page name, for example, "/fr" for a French translation.
  
 
<!--T:11-->
 
<!--T:11-->
DO NOT add the "/lang" if the translate page doesn't exists in you langage, it will broke the link. DO NOT write anything else than the name of the page or it will broke the link.
+
Do not add the language codes "/fr", "/de", "/es", "/ru", etc., if the translated page doesn't exists in that language, it will break the link.
 +
In this case, do not write anything else than the name of the page, or it will break the link.
  
 
<!--T:12-->
 
<!--T:12-->
[[File:Translate-sidebar-instruction.png|300px|thumb|left|Where to look]]
+
[[File:Translate-sidebar-instruction.png|left|Where to look]]
  
 
<!--T:13-->
 
<!--T:13-->
 
[[Category:Developer Documentation]]
 
[[Category:Developer Documentation]]
 +
[[Category:Wiki]]
  
 
</translate>
 
</translate>
 
{{clear}}
 
{{clear}}
<languages/>
 

Latest revision as of 20:48, 10 March 2019

Other languages:
Deutsch • ‎English • ‎français • ‎hrvatski • ‎italiano • ‎Türkçe

Localisation is the process of providing software with a multiple language user interface. The documentation wiki can also be localized, as described in section Translate the FreeCAD wiki.

The sidebar is an important navigation tool in the wiki world, see Manual:Interface/Sidebar for more information.

Translate the sidebar

The sidebar is now fully translatable with the Translation extension, which is available in all pages of the wiki.

In the FreeCAD wiki, the sidebar is implemented using templates, which change the text depending on the selected language. Technical details on how this feature was implemented are described in the forum thread Wiki navigation / translation.

Instructions

You can go to the special page Special:Translate/wiki-sidebar to begin translation.

There is a bug with the Download page. You can't redirect the link to "Download/fr", or "Download/de", etc. Instead, the link will point to the actual translation of "Download" in your language. The best way to deal with it is to create this new page and do a redirection to the right page. More about redirection on Help:Editing.

Important notes

Most of the time there will be two strings for each item in the sidebar.

** {{int:sidebar-faq-target}}|sidebar-faq

The left one represents the target of the link, and the right one represent the text that will be displayed in the sidebar.

You can see the difference between the two by looking at the top of the translate box where the name of the variable is displayed. When the variable name ends with "-target", it means that you will be translating a target link. It's made to allow the translator to redirect the items to the translated pages, that is, by adding a language code at the end of the page name, for example, "/fr" for a French translation.

Do not add the language codes "/fr", "/de", "/es", "/ru", etc., if the translated page doesn't exists in that language, it will break the link. In this case, do not write anything else than the name of the page, or it will break the link.

Where to look