Discussion: translating Puppys System-tools
i can't get $"text" to work either ... that's why i put LANG= on each line, to be absolutely sure LANG was set when the line executed
except, the way bash works, i think it substitutes all $"text" strings before any line in the script executes, so to work properly (for demo purposes), LANG variables should be set and exported before ever calling the script
also, gettext uses LANG, but i think bash uses LC_ALL ... but i still couldn't get $"text" to work
maybe it's the way bash was compiled ... maybe it was compiled without NLS support?
except, the way bash works, i think it substitutes all $"text" strings before any line in the script executes, so to work properly (for demo purposes), LANG variables should be set and exported before ever calling the script
also, gettext uses LANG, but i think bash uses LC_ALL ... but i still couldn't get $"text" to work
maybe it's the way bash was compiled ... maybe it was compiled without NLS support?
I just wanted to make sure that other readers understand that when implementing gettext in their scripts they should rely on the locale set for the system.GuestToo wrote:so to work properly (for demo purposes), LANG variables should be set and exported before ever calling the script
Thanks for your demo.
[url]http://rarsa.blogspot.com[/url] Covering my eclectic thoughts
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
Re: Discussion: translating Puppys System-tools
I am not a coder but I can translate English to Traditional ChineseMU wrote:
So we need coders that start adding the functions, and later users (without programming-experience) to translate .mo -files.
Mark
Can someone help me to translate Dillo-0.5.8-i18n-misc into zh_TW.UTF-8
environment under Puppy?
Thanks,
nyu
Rosetta
Hi there!
Does anyone know if there is a way to upload all the texts into Rosetta to easier internationalize Puppy?
If you never heard about it just check www.launchpad.net. Its a great tool for translating.
Another question: How can Linux beginner extract the texts from Puppy to translate it? And later put them back translated? Maybe some experienced user could do the extraction for others who don't know how & later help to load them back? What do you think?
Does anyone know if there is a way to upload all the texts into Rosetta to easier internationalize Puppy?
If you never heard about it just check www.launchpad.net. Its a great tool for translating.
Another question: How can Linux beginner extract the texts from Puppy to translate it? And later put them back translated? Maybe some experienced user could do the extraction for others who don't know how & later help to load them back? What do you think?
i think it is already translated to zh_TW ... does the font that is used make a difference? ... if it does, then you should be able to get the zh_TW.po file from the source and adapt it ... zh_TW.po already seems to be a UTF8 text fileCan someone help me to translate Dillo-0.5.8-i18n-misc into zh_TW.UTF-8
maybe you need to add a locale named zh_TW.UTF-8 in /usr/local/share/locale/ ? ... it could probably be a copy or a symlink to the zh_TW locale
source:
http://www.murga.org/~puppy/viewtopic.php?t=7473
i do not know if the Puppy unleased package is significantly different from MU's
for programs, the programs should be written (re-written) to support translations ... if the programs are written properly, the strings can be automatically extracted to a .po file (a text file with the text strings and spaces for the translations) ... for example, for a bash script, text stings in quotes with a leading $ will be extracted ( $"text" ) to the .po fileHow can Linux beginner extract the texts from Puppy to translate it?
normally, the programmer would provide a .po file with a list of the text strings that need translation ... someone could add the translations and upload the translated .po file
a .po file would look something like this:
msgid "Reset"
msgstr ""
msgid "Reload"
msgstr ""
msgid "Save"
msgstr ""
after translation, it would look something like this:
# Dillo Chinese Translation
msgid "Reset"
msgstr "重設"
msgid "Reload"
msgstr "重載"
msgid "Save"
msgstr "儲存"
Re: Rosetta
As Guesttoo explained:Kingskid wrote:How can Linux beginner extract the texts from Puppy to translate it?
"Translating" consist on two steps:
Internationalization (i18n):
Consist on enabling the application for multiple locales: (Language, text directionality, etc)
Localization (l10n):
Is the actuall translation of the strings apearing in an Internationalized application.
A developer does the i18n a translator the l10n.
[url]http://rarsa.blogspot.com[/url] Covering my eclectic thoughts
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
Hi GuestToo,GuestToo wrote:i think it is already translated to zh_TW ... does the font that is used make a difference? ... if it does, then you should be able to get the zh_TW.po file from the source and adapt it ... zh_TW.po already seems to be a UTF8 text fileCan someone help me to translate Dillo-0.5.8-i18n-misc into zh_TW.UTF-8
maybe you need to add a locale named zh_TW.UTF-8 in /usr/local/share/locale/ ? ... it could probably be a copy or a symlink to the zh_TW locale
source:
http://www.murga.org/~puppy/viewtopic.php?t=7473
i do not know if the Puppy unleased package is significantly different from MU's
Thanks for leading me to the right direction. Here is my locale environment:
-----------------------------------------------------------------
#locale
LANG=zh_TW.UTF-8
LC_CTYPE=zh_TW.UTF-8
LC_NUMERIC="zh_TW.UTF-8"
LC_TIME="zh_TW.UTF-8"
LC_COLLATE="zh_TW.UTF-8"
LC_MONETARY="zh_TW.UTF-8"
LC_MESSAGES="zh_TW.UTF-8"
LC_PAPER="zh_TW.UTF-8"
LC_NAME="zh_TW.UTF-8"
LC_ADDRESS="zh_TW.UTF-8"
LC_TELEPHONE="zh_TW.UTF-8"
LC_MEASUREMENT="zh_TW.UTF-8"
LC_IDENTIFICATION="zh_TW.UTF-8"
LC_ALL=
#locale -a
C
en_AU
en_US
POSIX
zh_CN.utf8
zh_TW.UTF-8
-----------------------------------------------------------------
I downloaded dillo-0.8.5-i18n-misc source file and found the zh_TW.po file.
I can open the file using Leafpad. It is indeed in Unicode (UTF-8 ) format and I can
read the Chinese translation under my installed fonts. I wnat to compile the po file to
generate zh_TW.mo file but I can not do it in Puppy. Fortunately, I have another
system with Ubuntu and it has "gettext " installed by default. I used "msgfmt" to
generate the corresponding .mo file successfully. Then I copied the file back to my
Puppy computer and changed the file name from zh_TW.mo to dillo.mo because Dillo
suppose to read this file under /usr/local/share/locale/zh_TW/LC_MESSAGES/dillo.mo.
But when I open Dillo browser, the system sub-menus are still not readable in Chinese.
My question is when I compile zh_TW.po file, does it generate Unicode .mo file?
nyu
Do you mean that they have garbage characters? or that they are in English?nyu wrote:But when I open Dillo browser, the system sub-menus are still not readable in Chinese.
[url]http://rarsa.blogspot.com[/url] Covering my eclectic thoughts
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
[url]http://www.kwlug.org/blog/48[/url] Covering my Linux How-to
nyu, i am not an expert in localisation
maybe what you need is to add a locale for
zh_TW.UTF-8 ... there is a locale for zh_TW, but maybe you need one for zh_TW.UTF-8 too
i think maybe the dillo.mo file for zh_TW.UTF-8 would be identical to the dillo.mo file for zh_TW
i installed MU's dillo package, and if is set LANG and LC_ALL to zh_TW or to zh_TW.UTF-8, i get an error message:
Gdk-WARNING **: locale not supported by Xlib, locale set to C
and dillo just runs in english ... maybe i would need to use localedef or something to setup my locales first?
maybe what you need is to add a locale for
zh_TW.UTF-8 ... there is a locale for zh_TW, but maybe you need one for zh_TW.UTF-8 too
i think maybe the dillo.mo file for zh_TW.UTF-8 would be identical to the dillo.mo file for zh_TW
i installed MU's dillo package, and if is set LANG and LC_ALL to zh_TW or to zh_TW.UTF-8, i get an error message:
Gdk-WARNING **: locale not supported by Xlib, locale set to C
and dillo just runs in english ... maybe i would need to use localedef or something to setup my locales first?
i do not know ... i would think that since the .po file is UTF8 then the .mo file will be toowhen I compile zh_TW.po file, does it generate Unicode .mo file?
and locale -a seems to show that you have a zh_TW.UTF-8 locale
do you get any error messages if you start dillo in an rxvt console?
and of course, you are using the internationalised dillo and not the standard version?
well, i tried using bash from 2 other distros that i have installed, and the implicit $"text" method does not seem to work with those version of bash either ... maybe they were compiled without NLS support eithermaybe it's the way bash was compiled ... maybe it was compiled without NLS support?
maybe i'm not using the right syntax, but i think i'm doing it right ... for example, see here
I have visited the page several times already. It mentions to view web pages in otherrarsa wrote:look at this page. There is a section for Dilo:
http://puppylinux.org/wikka/LanguageSupport
languages and I can read pages in Chinese but the problem is that I can't read the Dillo system sub-menus. The characters are all unreadable - garbage.
When I run dillo in an rxvt console, I got the following errors but I am not sure they are related to my problem:GuestToo wrote:
and locale -a seems to show that you have a zh_TW.UTF-8 locale
do you get any error messages if you start dillo in an rxvt console?
and of course, you are using the internationalised dillo and not the standard version?
debianinstallerrc :38: unexpected string constant "send", expected symbol
debianinstallerrc :38: unexpected string constant "referer", expected symbol
And yes, I am using MU's dotpup Dillo file.
that is strange ... i do not know why dillo would be accessing a file called debianinstallerrc ... i do not have that file, i just unzipped MU's package and copied the files to the appropriate places, i try to avoid registering things with pupget, and i did not want the package to mess with my menus either ... i try to make my own packages so that they are as independent of Puppy as possible
it seems that your locale is working, or there would be an error message "locale set to C"
maybe the locale is using the wrong character set ... as i said, i do not know a lot localisation
it seems that your locale is working, or there would be an error message "locale set to C"
maybe the locale is using the wrong character set ... as i said, i do not know a lot localisation
I need to spend some more time to find out what is going on......GuestToo wrote:that is strange ... i do not know why dillo would be accessing a file called debianinstallerrc ... i do not have that file, i just unzipped MU's package and copied the files to the appropriate places, i try to avoid registering things with pupget, and i did not want the package to mess with my menus either ... i try to make my own packages so that they are as independent of Puppy as possible
it seems that your locale is working, or there would be an error message "locale set to C"
maybe the locale is using the wrong character set ... as i said, i do not know a lot localisation
- Nathan F
- Posts: 1764
- Joined: Wed 08 Jun 2005, 14:45
- Location: Wadsworth, OH (occasionally home)
- Contact:
This is something I will look into (FLTK + unicode) but right off my guess would be that unicode will be supported. Dillo is not the only major project porting over to FLTK, Cinepaint is doing so as well. I have to assume the developers at least took this into consideration.
If my memory serves I did read about it once, and the reply given was that unicode will be supported by FLTK but that support is not fully complete yet. Like I said, I'll research it.
Nathan
If my memory serves I did read about it once, and the reply given was that unicode will be supported by FLTK but that support is not fully complete yet. Like I said, I'll research it.
Nathan
Bring on the locusts ...