Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sun 21 Dec 2014, 13:33
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Projects » Localization Project
Translate LupQ - Quickset edition of Lucid Puppy
Moderators: Lobster, MU, raffy
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 1 of 5 Posts_count   Goto page: 1, 2, 3, 4, 5 Next
Author Message
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Wed 25 Aug 2010, 00:58    Post_subject:  Translate LupQ - Quickset edition of Lucid Puppy
Sub_title: calling for translations
 

LupQ, the QuickSet edition of Lucid Puppy, has easy country setting and the desktop i18n ready.
Some language pack is available now, but calling for more translations.
Lucid Puppy Quickset edition main topic

AVAILABLE LANGUAGES:
At this point of time, Arabic/Hebrew, Dutch, French, German, Hungarian, Italian, Portuguese, Russian , Spanish, Chinese, Korean and Japanese are available as partially translated.
Get the packages from here.

HOW TO:
  1. Gettext scripts: Some scripts are i18n ready thanks to L18L using gettext system.
    To make translations using gettext system. You can copy the .pot file to yourlang.po and edit it using text editor, but i recommend poedit. Get the tool here or poedit-1.4.2-3-i686.pet here. You may be confused for the first time but It is easy once you run the poedit.
    The .pot files are available at /usr/share/doc/nls on LupQ.
    The translated .mo files to be placed in '/usr/share/locale/<language code>/LC_MESSAGES'.
    Where <language code> can be <2-letter> code or <2-letter>_<country code>, such as 'pt' for Portuguese and 'pt_BR' for Brazilian Portuguese.
  2. Simple localization scripts: Some scripts are using simple localization by MU. Some has the template, for example, /usr/local/locale/en/LC_MESSAGES/net-setup.mo, /usr/local/locale/C/LC_MESSAGES/connectwizard.mo.
    Some has the template in itself like /usr/sbin/grub4dosconfig.
    Most of them place the translation at '/usr/share/locale/<language code>/LC_MESSAGES/*.mo'. Note that they have the extension '.mo', but they are simple text files with shell syntax.
    Scripts by zigbert place the translation at '/urs/local/<appdir>/locals'.
  3. Desktop icons, tray icons, main menu: gettext system can be applied for this thanks to the puppy-desktop NLS system.
    They are now gettext'ed. Next is the old way:
    • Desktop icons: You can find the file '/root/Choices/ROX-Filer/PuppyPin.C'.
      Copy this template as 'PuppyPin.<langage code>' in the same directory. For example '/root/Choices/ROX-Filer/PuppyPin.fr'.
      Find label="something" and replace "something" with your language.
    • Tray: There is the file '/root/.jwmrc-tray.C'. Copy it as '.jwmrc-tray.<langage code>'. Translate label="Menu" and popup="something".
    • 'Shutdown' and 'help' on main menu: Find the file '/etc/xdg/templates.locale/_root_.jwmrc.C'.
      Copy this template as '_root_.jwmrc.<language code>' in the same directory.
      Replace label="something" and replace "something" with your language.

  4. Main Menu: Go to '/usr/share/desktop-directories'. for example the file Puppy-Calculate.directoy has the next contents:
    Code:
    [Desktop Entry]
    Encoding=UTF-8
    Name=Business
    Name[fr]=Calculs
    Name[hu_HU]=Üzleti
    Name[ja]=会計
    Name[ru]=Вычисления
    Name[zh_CN]=计算器
    Name[zh_TW]=計算工具
    Icon=spread24.png
    Type=Directory

    You can add line of translation as 'Name[<language code>]=<translation>'.
  5. Menu items: Go to "/usr/share/applications". Add 'Name[<language code>]=<translation>' line to each '*.desktop' files.
  6. Help files and Welcome page: Some help files can put in /usr/share/doc/help/<language code>/<keyword>{.html,.text}
    You can put the translation of '/usr/share/doc/welcome1stboot.htm' as '/usr/share/doc/help/<language code>/welcome1stboot.htm'.
    The translation of '/usr/share/doc/home.htm' at '/usr/share/doc/help/<language code>/home.htm', or '/usr/share/doc/home_<language code>.htm'(obsolute). They are coppied at /usr/share/doc/home.htm', so the links are better to be absolute, not relative. The puppyhelp reffers '/usr/share/doc/index.html' or '/usr/share/doc/help/<language code>/index.html' if available, but note that indexgen.sh modifies only the file '/usr/share/doc/index.html'.
  7. Right click menu of the desktop icons: The ROX-Filer menu appears when right-clicking the icons on the desktop. The translation of Rox-Filer shall be placed at /usr/local/apps/ROX-Filer/Messages/??/LC_MESSAGES/ROX-Filer.mo, at the recent version of ROX-Filer.
  8. Right click menu of the desktop icons for some apps: See '/usr/local/apps/Xlock/Appinfo.xml' for example.
    Code:
    <?xml version="1.0"?>
    <AppInfo>
      <Summary>Lock the screen</Summary>
      <Summary xml:lang="fr">Verrouiller l'écran</Summary>
      <Summary xml:lang="ja">パスワードを使って画面をロックします</Summary>
      <About>
        <Purpose>Lock the screen</Purpose>
        <License>GPL: http://www.gnu.org/licenses/gpl.txt</License>
        <Version>1.0 - Barry Kauler - Nov. 11, 2005</Version>
        <Homepage>http://www.pupweb.org/</Homepage>
      </About>
      <AppMenu>
        <Item icon="system-lock-screen" option="-locknow">
         <Label>Lock the screen now</Label>
         <Label xml:lang="fr">Verrouiller maintenant</Label>
         <Label xml:lang="ja">今すぐ画面をロック</Label>
        </Item>
        <Item icon="gtk-preferences" option="-configure">
         <Label>Configure screen locking</Label>
         <Label xml:lang="fr">Configurer le verrouillage</Label>
         <Label xml:lang="ja">画面ロックの設定</Label>
        </Item>
        <Item icon="edit-clear" option="-password">
         <Label>Clear xlock password</Label>
         <Label xml:lang="fr">Effacer le mot de passe</Label>
         <Label xml:lang="ja">xlockパスワードをクリア</Label>
        </Item>
      </AppMenu>
    </AppInfo>

    You can add translation lines with property 'xml:lang="??"'.
    Same way on Connect, Pupzip, Trash and Trash/template.
  9. Applications: Some applications has its translations with its way. Some use gettext system and some based on MU's simple localization.
    Most of gtk and gnome applications place the translations at '/usr/share/locale/<language code>/LC_MESSAGES'.
    ROX-Filer places its translations at '/usr/local/apps/ROX-Filer/Messages/<language code>/LC_MESSAGES/ROX-Filer.mo'.
    Abiword has localized settings and strings at '/usr/share/abiword-<version>'.
    Recent CUPS has its translations under '/usr/share/cups/templates'.

Indivisual Puppy apps(built in lupq) language support pages: (typically zigbert's put the translations in '/urs/local/<appdir>/locals'.)

LINKS:

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html

Edited_times_total
Back to top
View user's profile Send_private_message Visit_website 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Wed 25 Aug 2010, 12:25    Post_subject: New language
Sub_title: hungarian language pack for lupq
 

New language package add.
Get Hungarian(Magyal) language package lang_pack_hu-lupq-0.2.pet from here.
EDIT:l updated ang_pack_hu-lupq-0.2.pet, sync with Lupq-003-HUNpack-01.pet available from http://skami.homelinux.org/, but without icewm translation.
Applicable only on the Lucid Puppy QuickSet edition(Lupq).

EDIT on 29 aug 2010: There is another package Lupq-003-HUNpack-02.pet prepaired by s-kami available at
ftp://puppylinux.hu/puppylinux/localization/hungarian/


EDIT on 31 Aug 2010: The countrywizard on lupq-006 and older does not show the dialog choosing UTF-8 in some locale, for example hu_HU. Use 'more...' from the combobox, or install countrywizard-0.7.pet.


EDIT on 3 Sep 2010: Hungarian Lupq-006-hu-01.iso available.
http://puppylinux.hu/

To enable firefox/seamonley2 translations, you have to run 'firefox.nls' instead of 'firefox', 'seamonkey2.nls' instead of 'seamonkey2'.
Install firefox/seamonkey2, use 'Choose Default Browser' on the tray.
Once set to netsurf, then reset firefox/seamonkey2.
Then the defaultbrowser is set as 'firefox.nls' or 'seamonkey2.nls'.


See the desktop:
desktop_magyar.png
 Description   
 Filesize   20.58 KB
 Viewed   8785 Time(s)

desktop_magyar.png


_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html

Edited_times_total
Back to top
View user's profile Send_private_message Visit_website 
don570


Joined: 10 Mar 2010
Posts: 3437
Location: Ontario

PostPosted: Wed 25 Aug 2010, 16:25    Post_subject: Hebrew and Arabic writing  

To help people with writing in Hebrew or Arabic, especially for localization
projects I have written a tutorial.

http://www.murga-linux.com/puppy/viewtopic.php?search_id=76008749&t=59014

Note that I highly recommend Nicoedit for opening text files
with Hebrew and Arabic. Geany has certain flaws which
I document.
Back to top
View user's profile Send_private_message 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Sun 29 Aug 2010, 04:09    Post_subject: Gettext'ed puppy desktop
Sub_title: translation of the desktp icons, main menu and tray
 

An inovation!
The desktp icons, main menu and tray on puppies can be translated with gettext system.
Install puppy-desktop-20100829.pet on LupQ-006.
EDIT: LupQ-507 has already intsalled.
EDIT: new version is available. See the topic.

CONTENTS: French and Hungarian translation for a trial and the how to make other translations at /usr/share/doc/nls/puppy-desktop.

The translation of the desktp icons, main menu and tray on puppies can be done by modifying the files, /etc/xdg/template/*, /root/Choices/ROX-FilerPuppyPin, /root/.jwmrc-tray, and etc by hand.

Puppy-43xJP(Japanese edition, english/japanese bilingual) and LupQ(multilingual) has the system to switch the translations. That is, having some translated files prepared before, and the script /usr/local/bin/freshmenus_on_locale changes the files according the locale automatically.

Now the new generation of the language switching system comes. It has the similar script that switches the language according the locale. But now, the translation is performed thanks to the gettext system.

Find the file /usr/share/doc/nls/pupy-desktop/puppy-desktop.pot.
You can make .po file and puppy-desktop.mo file using poedit or such a editors same way as the other gettext system.
The puppy-desktop.pot includes the desktop icon label, a part of the main menu label, and popups of some icons on the tray.

puppy-desktop-20100829 is made for LupQ-006, but potentially expanded to apply on other puppies. For JWM is good, but some trouble with IceWM when using non-UTF-8 encoding.

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html

Edited_times_total
Back to top
View user's profile Send_private_message Visit_website 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Sun 29 Aug 2010, 20:38    Post_subject: petget bug
Sub_title: menu language reverts to english when packages removed
 

A bug on lupq-006.
The menu language reverts to english when packages removed.
Menu > Shutdown > Refresh Desktop repares.

Fix:
Edit /usr/local/petget/removepreview.sh at line 88, should be:
Code:
LANG=$LANG_USER /usr/sbin/fixmenus   # 30aug10 shinobar

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
L18L

Joined: 19 Jun 2010
Posts: 2620
Location: www.eussenheim.de/

PostPosted: Mon 30 Aug 2010, 09:48    Post_subject: translations using gettext system, poedit ...  

geany was sufficient for me. Exclamation
now I will take nicoedit

Edit:
just if you do not want poedit because of its size.
use msgfmt (in devx) to create .mo files.
I have done it this way

Edit: No devx available?
use attached msgfmt
msgfmt.tar.gz
Description  msgfmt for translators without devx or poedit
gz

 Download 
Filename  msgfmt.tar.gz 
Filesize  576.59 KB 
Downloaded  1314 Time(s) 
Back to top
View user's profile Send_private_message 
L18L

Joined: 19 Jun 2010
Posts: 2620
Location: www.eussenheim.de/

PostPosted: Tue 31 Aug 2010, 08:24    Post_subject: puppy desktop translated to german  

just used and translated and msgfmt`´ed

and used Laughing
puppy-desktop-de.tar.gz
Description  contains puppy-desktop.po and .mo
gz

 Download 
Filename  puppy-desktop-de.tar.gz 
Filesize  2.93 KB 
Downloaded  1228 Time(s) 
Back to top
View user's profile Send_private_message 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Thu 02 Sep 2010, 03:08    Post_subject: IceWM translating problem
Sub_title: UTF-8 or non-UTF-8
 

shinobar wrote:
puppy-desktop-20100829 is made for LupQ-006, but potentially expanded to apply on other puppies. For JWM is good, but some trouble with IceWM when using non-UTF-8 encoding.

The detail:
IceWM with UTF-8 locales, such as 'fr_FR.UTF-8', shows proper translations, but with non-UTF-8 locales, shuch as 'fr_FR', breaks the translations.

The puppy-desktop can change the encoding UTF-8 or ISO-8859-1/2 if i modify the code to control the OUTPT_CHARMAP for gettext.
But the main problem is the *.desktop files has the translations in UTF-8 encoding and IceWM cannot correctly display them in its menu when the locale is non-UTF-8.
Hope someone resolve this problem regarding the IceWM.

The JWM shows the translations in the menu with no problem whether the locale is UTF-8 or non-UTF-8.

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
esmourguit


Joined: 17 Nov 2006
Posts: 1288
Location: Sur l'ile aux oiseaux.

PostPosted: Thu 02 Sep 2010, 05:32    Post_subject:  

Bonjour à tous,
Quote:
But the main problem is the *.desktop files has the translations in UTF-8 encoding and IceWM cannot correctly display them in its menu when the locale is non-UTF-8.
Hope someone resolve this problem regarding the IceWM.

That was done for Toutou 3.01, which have both jwm and icewm.
We've modified the fixmenus file.
Cordialement Wink

_________________
Toutou Linux - Pets francisés
Back to top
View user's profile Send_private_message 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Thu 02 Sep 2010, 07:10    Post_subject: fixmenus and icewm
Sub_title: UTF-8 and non-UTF8 problem
 

esmourguit wrote:
We've modified the fixmenus file.

Great.

EDIT: Seems not needed the attached because your fixmenus patched converts whole icewm menu from UTF-8 to ISO-8859-1.

Attached outputs ISO-8859-1 with non-UTF-8 locales. But NG for your fixmenus.
puppy-desktop-20100902.pet
Description  revised /usr/share/local/bin/fixmenus_on_locale for icewm with UTF-8 and without UTF-8.
pet

 Download 
Filename  puppy-desktop-20100902.pet 
Filesize  13.38 KB 
Downloaded  1139 Time(s) 

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
esmourguit


Joined: 17 Nov 2006
Posts: 1288
Location: Sur l'ile aux oiseaux.

PostPosted: Thu 02 Sep 2010, 10:10    Post_subject:  

Bonjour à tous,
Sorry for the late reply, I had difficulties to burn lupuq506.
I see no problem in displaying menus with accents using icewm.
It does not seem any necessary changes.
Cordialement Wink

_________________
Toutou Linux - Pets francisés
Back to top
View user's profile Send_private_message 
esmourguit


Joined: 17 Nov 2006
Posts: 1288
Location: Sur l'ile aux oiseaux.

PostPosted: Thu 02 Sep 2010, 10:21    Post_subject:  

Bonjour à tous,
And it seems it doesn't support the locale for the menu. Even if I launch the refreshment of the menu.
This is curious, because I translated all the branches of the menu and submenus are displayed in French.
Cordialement Wink
menu1.jpg
 Description   
 Filesize   50.13 KB
 Viewed   2448 Time(s)

menu1.jpg


_________________
Toutou Linux - Pets francisés
Back to top
View user's profile Send_private_message 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Thu 02 Sep 2010, 19:17    Post_subject: Hungarian LupQ etc.  

Thanks esmourguit.

à propos, the Hungarian LupQ base on lupq-006, Lupq-006-hu-01.iso, is available. http://puppylinux.hu/
The Hungarian translates the IceWM, but cannnot switch by the other locale.

Give me a time on IceWM translation based on the new desktop translating system. The first issue is the IceWM is removed on LupQ-507 Cool

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Fri 03 Sep 2010, 04:21    Post_subject: Non-ASCII letters on urxvt
Sub_title: unicode locale on LupQ is not '.utf8' but '.UTF-8'
 

It is reported that the console can not display accented letters on Magyar Lucid Puppy 5.1, Lupq-006-hu-01.
It is because of the locale problem. Lupq-006-hu-01 uses its locale as 'hu_HU.utf8'.
Most of puppies and woof uses '.utf8' for the UTF-8 encoding locales.
But '.utf8' makes trouble with some X application like urxvt.
The recommended unicode locale on LupQ is not '.utf8' but '.UTF-8'.

If you are using Lupq-006-hu-01, edit /etc/profile and find 'LANG=hu_HU.utf8' and change it to
Code:
LANG=hu_HU.UTF-8

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
shinobar


Joined: 28 May 2009
Posts: 2631
Location: Japan

PostPosted: Fri 03 Sep 2010, 05:04    Post_subject: Non-ASCII letters on console
Sub_title: Puppies cannot display them?
 

The matter of the console (without X).
I am not sure on the older version, but most of puppies cannot display non-ASCII letters on the console.
Recent puppies have the console fonts at /lib/consolefonts, lat1-12.psfu.gz for ISO-8859-1 and lat2-12.psfu.gz for ISO-8859-2.
But they seem not work.
Try:
Code:
# gzip -dcf /lib/consolefonts/lat1-12.psfu.gz | loadfont
loadfont: KDFONTOP: Invalid argument
# zcat /lib/consolefonts/lat1-12.psfu.gz | loadfont
loadfont: KDFONTOP: Invalid argument

We can find next line for example in /etc/rc.d/rc.country.
Code:
echo -n "$FONTMAP" > /etc/fontmap

This code is comment outed on LupQ because a half of the console dialog cannot be seen on some hardware, maybe nvidia graphics.
I do not know who reads this file /etc/fontmap and what do.
Anyway the console cannot display non-ASCII whether the /etc/fontmap is blank or filled.

I do not intend to follow this issue further.
Someone interested in?

_________________
Google Chrome portable
Downloads for Puppy Linux http://shino.pos.to/linux/downloads.html
Back to top
View user's profile Send_private_message Visit_website 
Display_posts:   Sort by:   
Page 1 of 5 Posts_count   Goto page: 1, 2, 3, 4, 5 Next
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » Advanced Topics » Puppy Projects » Localization Project
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1251s ][ Queries: 13 (0.0044s) ][ GZIP on ]