Danish language pack
Danish language pack
Hi Puppy linguists
I'd like to maintain a Danish languagepack for Puppy Linux.
langpack_da-20130407.pet (572 kb)
I've made an effort to translate as much as I could last week - and I'm far from finished..
I'm a co-moderator of a small Danish forum: http://linux-abc.dk
We have a couple of threads reserved for Puppy Linux.
Puppy Linux at Linux-abc.dk
I've been making Puppy remasters for a couple of years.
Now I've reached a point where I want to be more modular in my thinking.
Recently I started creating Pets - and I really like/digg it
I have a couple of problems with the translation though...
When I translate scripts (mo) files via the momanager - they don't seem to work ...
I guessed that I should write the danish translation inside the double quotation marks - NOT replacing the msg-id text but rather fill out the empty space in the msg-string, under the msg-id ...
This procedure doesn't seem to work.... Please give me a hint
Another thing which IMO seems to be of an outmost importance for a language pack to have a serious impact - is that it should translate the first-run Quick settings dialog AND the desktop icons' text lables...
For some reason I haven't had any luck in making these two things happen...
Could you please give me a pointer regarding those two specific measures?
Cheers Måns Mårtensson
I'd like to maintain a Danish languagepack for Puppy Linux.
langpack_da-20130407.pet (572 kb)
I've made an effort to translate as much as I could last week - and I'm far from finished..
I'm a co-moderator of a small Danish forum: http://linux-abc.dk
We have a couple of threads reserved for Puppy Linux.
Puppy Linux at Linux-abc.dk
I've been making Puppy remasters for a couple of years.
Now I've reached a point where I want to be more modular in my thinking.
Recently I started creating Pets - and I really like/digg it
I have a couple of problems with the translation though...
When I translate scripts (mo) files via the momanager - they don't seem to work ...
I guessed that I should write the danish translation inside the double quotation marks - NOT replacing the msg-id text but rather fill out the empty space in the msg-string, under the msg-id ...
This procedure doesn't seem to work.... Please give me a hint
Another thing which IMO seems to be of an outmost importance for a language pack to have a serious impact - is that it should translate the first-run Quick settings dialog AND the desktop icons' text lables...
For some reason I haven't had any luck in making these two things happen...
Could you please give me a pointer regarding those two specific measures?
Cheers Måns Mårtensson
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
Re: Danish language pack
Hi Måns
I have installed your langpack and I am playing with it now...
msg means message ID (used in script)
msgstr means message string (maybe translated or empty)
s%"lock"%"lås"%
s%"trash"%"mal"%
...
welcome on board
L
----
edited
it is really nice to get puppy in Rasmus Lerdorf's language
I have installed your langpack and I am playing with it now...
Rightmaans wrote:...I guessed that I should write the danish translation inside the double quotation marks - NOT replacing the msg-id text but rather fill out the empty space in the msg-string, under the msg-id ...
msg means message ID (used in script)
msgstr means message string (maybe translated or empty)
In wary/racy/precise/rpi there is /usr/sbin/quicksetup which can be translated. Which puppy are you talking about?maans wrote:...it should translate the first-run Quick settings dialog...
Do it the right way and it will work:maans wrote:... AND the desktop icons' text lables...
s%"lock"%"lås"%
s%"trash"%"mal"%
...
welcome on board
L
----
edited
it is really nice to get puppy in Rasmus Lerdorf's language
Last edited by L18L on Mon 08 Apr 2013, 13:17, edited 2 times in total.
Re: Danish language pack
Hi L
I followed your advice and made the desk_strings.da work as intended!
I found this file: quicksetup.pupdev where Barry explains how to create a pot file from the quicksetup by temporarily renaming the script to quicksetup.sh and do a series of commands to
1) Create a pot file:
2) Set text mode to UTF-8:
5) Note that an existing .mo file can be uncompiled like this:
I haven't tried this yet - however I'm about to try it out, as it seems to be the way to make it find it's way into the language pack - maybe even into the momanager routine?
What I *did* translate was the /usr/sbin/welcome1stboot (da welcome1stboot.mo WOOF) - however it doesn't seem to have any impact on the quicksetup script at all...
I'm using Puppy Precise 5.4.3 (in livemode) for building my danish languagepack.
Thank you for your assistance
Cheers Måns Mårtensson
Ps: Would you happen to know which file(s) I should edit to translate the first two menu entries in the start menu?? (Help and Shutdown)...
ThanksL18L wrote: Right
msg means message ID (used in script)
msgstr means message string (maybe translated or empty)
In wary/racy/precise/rpi there is /usr/sbin/quicksetup which can be translated. Which puppy are you talking about?maans wrote:...it should translate the first-run Quick settings dialog...
Do it the right way and it will work:maans wrote:... AND the desktop icons' text lables...
s%"lock"%"lås"%
s%"trash"%"mal"%
...
welcome on board
I followed your advice and made the desk_strings.da work as intended!
I found this file: quicksetup.pupdev where Barry explains how to create a pot file from the quicksetup by temporarily renaming the script to quicksetup.sh and do a series of commands to
1) Create a pot file:
Code: Select all
xgettext -o quicksetup.pot --no-wrap quicksetup.sh
3) Convert the pot file to a localized po file (example is German):...the generated quicksetup.pot has a line with "charset=", please change that to
"charset=UTF-8"
Code: Select all
# msginit --no-wrap --locale=de_DE --output-file=de.po --input=quicksetup.pot
4) Create a compiled quicksetup.mo file:Also, edit this line to look like this:
"Project-Id-Version: quicksetup 1.0\n"
Then insert your country translations into de.po.
Code: Select all
# mkdir -p /usr/share/locale/de/LC_MESSAGES
# msgfmt --check --output-file=/usr/share/locale/de/LC_MESSAGES/quicksetup.mo de.po
Code: Select all
# msgunfmt quicksetup.mo
What I *did* translate was the /usr/sbin/welcome1stboot (da welcome1stboot.mo WOOF) - however it doesn't seem to have any impact on the quicksetup script at all...
I'm using Puppy Precise 5.4.3 (in livemode) for building my danish languagepack.
Thank you for your assistance
Cheers Måns Mårtensson
Ps: Would you happen to know which file(s) I should edit to translate the first two menu entries in the start menu?? (Help and Shutdown)...
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
language pack
maans wrote:Ps: Would you happen to know which file(s) I should edit to translate the first two menu entries in the start menu?? (Help and Shutdown)...
... and everything under shutdown is in
/usr/share/sss/menu_strings/menu_strings.da
s%"Help"%"Hjælp"%
Other answers will follow soon
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
language pack
That explanation was how to do it without momanager.maans wrote:...I found this file: quicksetup.pupdev where Barry explains how to create a pot file from the quicksetup
....
I haven't tried this yet - however I'm about to try it out, as it seems to be the way to make it find it's way into the language pack - maybe even into the momanager routine?
I see, something has gone wrong with your welcome1stboot.momaans wrote:What I *did* translate was the /usr/sbin/welcome1stboot (da welcome1stboot.mo WOOF) - however it doesn't seem to have any impact on the quicksetup script at all...
Code: Select all
# file welcome1stboot.mo
welcome1stboot.mo: GNU message catalog (little endian), revision 0, 1 messages
Code: Select all
msgunfmt quicksetup.mo
Usually (without -o quicksetup.po) it should go into file messages
Please delete this file:
Code: Select all
rm /usr/share/locale/da/LC_MESSAGES/welcome1stboot.mo
welcome1stboot is on the right side (without translation) again
translate just some messages in momanager
and make sure that script is showing the translated messages
Code: Select all
welcome1stboot
I am using Puppy Precise 5.5 frugal installedmaans wrote:I'm using Puppy Precise 5.4.3 (in livemode) for building my danish languagepack.
I do not see any advantage in using live mode. I live mode you always have to
-install old langpack
-translate
-create new langpack and save it somewhere
If installed my changes stay and I make langpack whenever I want.
Please upgrade to 5.5 because there might have been important fixes.
Cheers
L
Re: language pack
Hi L
I eventually found an iso for Precise 5.5 - however I can't download the devx_precise_5.5.sfs file?? (serverproblem) It's needed for the translation tools...
Do you happen to have a working devx_precise_5.5.sfs file which I could get my hands on? - to be able to translate in the Puppy Precise 5.5 environment.
Cheers Måns Mårtensson
Ok - Now I found the quicksetup file in the momanager list...Sorry for the trouble regarding the quicksetup file > Apparently I didn't look close enough - and need to clean my glasses - once in a while....L18L wrote: and make sure that script is showing the translated messagesCode: Select all
welcome1stboot
I am using Puppy Precise 5.5 frugal installedmaans wrote:I'm using Puppy Precise 5.4.3 (in livemode) for building my danish languagepack.
I do not see any advantage in using live mode. I live mode you always have to
-install old langpack
-translate
-create new langpack and save it somewhere
If installed my changes stay and I make langpack whenever I want.
Please upgrade to 5.5 because there might have been important fixes.
I eventually found an iso for Precise 5.5 - however I can't download the devx_precise_5.5.sfs file?? (serverproblem) It's needed for the translation tools...
Do you happen to have a working devx_precise_5.5.sfs file which I could get my hands on? - to be able to translate in the Puppy Precise 5.5 environment.
Cheers Måns Mårtensson
Hej Maans .
Du behoever ikke at faar Puppy Linux fraa Amilandet.
De er en europaeiske server du maa gerne kikke paa :
http://ftp.nluug.nl/ibiblio/distributions/puppylinux/puppy-5.5/devx_slacko_5.5.sfs
Den er meget hurtiger den ibiblio .
God arbejdslysten !
Du behoever ikke at faar Puppy Linux fraa Amilandet.
De er en europaeiske server du maa gerne kikke paa :
http://ftp.nluug.nl/ibiblio/distributions/puppylinux/puppy-5.5/devx_slacko_5.5.sfs
Den er meget hurtiger den ibiblio .
God arbejdslysten !
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
devx_precise 5.5.sfs
try this one
http://ftp.nluug.nl/os/Linux/distr/quirky/precise-5.5/
for devx_precise_5.5.sfs
or if you do not have broadband connection
and have the devx_precise_5.4.3.sfs
http://ftp.nluug.nl/os/Linux/distr/quir ... .sfs.delta
---
edit
Oh I see: Karl was hurtiger
http://ftp.nluug.nl/os/Linux/distr/quirky/precise-5.5/
for devx_precise_5.5.sfs
or if you do not have broadband connection
and have the devx_precise_5.4.3.sfs
http://ftp.nluug.nl/os/Linux/distr/quir ... .sfs.delta
---
edit
Oh I see: Karl was hurtiger
Hi Karl and L
I'm happy to know that it is I and not you, who sets out to make a Danish languagepack
Thank you very much for your support - I will use both Slacko and Precise for my language pack testings...
I had another go at the quicksetup.mo file - alas it failed again. (This time (3rd attempt) i made a txt-backup.... )
Have a look at: langpack_da-20130408.pet
Now icons and menu entries are in place... thanks to L
Cheers Måns Mårtensson
Ps: I've attached my text-backup file, and the quicksetup.mo file, from /tmp as a zip-file.
From a quick look - you might be able to tell what I'm doing wrong.
I'm happy to know that it is I and not you, who sets out to make a Danish languagepack
Thank you very much for your support - I will use both Slacko and Precise for my language pack testings...
I had another go at the quicksetup.mo file - alas it failed again. (This time (3rd attempt) i made a txt-backup.... )
Have a look at: langpack_da-20130408.pet
Now icons and menu entries are in place... thanks to L
Cheers Måns Mårtensson
Ps: I've attached my text-backup file, and the quicksetup.mo file, from /tmp as a zip-file.
From a quick look - you might be able to tell what I'm doing wrong.
- Attachments
-
- quicksetuptxt.zip
- txt and mo
- (21.93 KiB) Downloaded 495 times
No idea . Have not used this translations things until now . But have diffed it :
bash-3.2# diff quicksetup.po quicksetupbackup.txt
The newline space seems to be the only difference .
Opera shows two blocks before the first "de" both times .
EDIT : FF v4.x shows it correctly .
bash-3.2# diff quicksetup.po quicksetupbackup.txt
Code: Select all
251c251
< "Hvis du ikke kan finde din lokalitet, skal du vælge en af de tilgængelige <b>GMT</b> zoner. Det er bedst at finde den korrekte lokalitet, da det anvender automatisk DST (Daylight Saving Time), mens GMT zonerne er faste forskydninger ifht. GMT (UTC) referencen. \n "
---
> "Hvis du ikke kan finde din lokalitet, skal du vælge en af de tilgængelige <b>GMT</b> zoner. Det er bedst at finde den korrekte lokalitet, da det anvender automatisk DST (Daylight Saving Time), mens GMT zonerne er faste forskydninger ifht. GMT (UTC) referencen.\n"
Opera shows two blocks before the first "de" both times .
EDIT : FF v4.x shows it correctly .
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
momanager not creating .mo file
... and this forum is messing the spaces.Karl Godt wrote:...The newline space seems to be the only difference ...
Let us take a console and what we have learned "how to do it without momanager" (see 4) in 3rd post):
Code: Select all
# msgfmt quicksetup.po
quicksetup.po:253:23: invalid control sequence
quicksetup.po:541:22: invalid control sequence
msgfmt: found 2 fatal errors
#
"<b>Teknisk set</ b> \ n"
line 541:
"<b> Advarsel </ b> \ n"
In both there is a space between backslash and n
(and between backslash and b )
Remove them
/n is fault found by msgfmt
/b is markup
and
Code: Select all
msgfmt quicksetup.po -o - > /usr/share/locale/da/LC_MESSAGES/quicksetup.mo
- Attachments
-
- quicksetup_da.png
- velkommen
you might copy or link to this from 1st post - (29.11 KiB) Downloaded 663 times
Truely :L18L wrote:quicksetup.po:253:23: invalid control sequence
Code: Select all
"<b>Teknisk set</ b> \ n"
12345678901234567890123
And
/me tykker jeg har faaet mit øl altiden hvis jaag har sagt "E n Ø l" ellers "E t Ø l"L18L wrote:(We should teach momanager to find such failures)
Was missing man msgfmt on mig szstem ..
gettext is a huge source (14+MB) . Have compiled version 0.18.1.1 from
http://packages.debian.org/source/squeeze/gettext
because the Ubuntu search has changed to search only insuide the current repository
to have the man pages onboard :
bash-3.2# pwd;ls
/root/Downloads/gettext-0.18.1.1-i686/usr/local/share/man/man1
autopoint.1 msgcat.1 msgexec.1 msgmerge.1 xgettext.1
envsubst.1 msgcmp.1 msgfilter.1 msgunfmt.1
gettext.1 msgcomm.1 msgfmt.1 msguniq.1
gettextize.1 msgconv.1 msggrep.1 ngettext.1
msgattrib.1 msgen.1 msginit.1 recode-sr-latin.1
- Attachments
-
- man1-gettext-pkg.tar.gz
- (10.69 KiB) Downloaded 449 times
«Give me GUI or Death» -- I give you [[Xx]term[inal]] [[Cc]on[s][ole]] .
Macpup user since 2010 on full installations.
People who want problems with Puppy boot frugal :P
Macpup user since 2010 on full installations.
People who want problems with Puppy boot frugal :P
Code: Select all
msgfmt --strict -o quicksetup.mo quicksetup.po
Have not run hurtigopsættningen though .
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
sorry, could you teachKarl Godt wrote:And/me tykker jeg har faaet mit øl altiden hvis jaag har sagt "E n Ø l" ellers "E t Ø l"L18L wrote:(We should teach momanager to find such failures)
http://translate.google.de/#da/de/me%20 ... har%20sagt
a translation that I would understand please?
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
If you would have run it you would have seen....Karl Godt wrote:...Have not run hurtigopsættningen though .
- Attachments
-
- dod_mus.png
- bad markup
- (7.43 KiB) Downloaded 365 times
OK : Heres a solution to check markup errors :
1. Create a MARKUPDATABASE like :
2. make a grep -vE pattern :
3. run this inside the directory of the *.po file :
4:result :
P=<b>.*</b>'
P1=<.*b.*>.*..**.*<.*/.*b.*>.*'
<b>Teknisk set</ b> \n"
<b> Advarsel </ b> \n"
P=<u>.*</u>'
P1=<.*u.*>.*..**.*<.*/.*u.*>.*'
P=<i>.*</i>'
P1=<.*i.*>.*..**.*<.*/.*i.*>.*'
1. Create a MARKUPDATABASE like :
Code: Select all
MPDB="<b>.*</b>
<u>.*</u>
<i>.*</i>
"
Code: Select all
MPDBNOT=`echo "$MPDB" |tr -d '[[:blank:]]' |tr '\n' '|' |sed 's%^|*%%;s%|*$%%'`
Code: Select all
while read P; do
echo "P=$P'"
[ "$P" ] || continue;
#P1=`echo "$P" | sed 's%\(.\)%\.\*\1\.\*%g'`; ##doesn't work for me
P1=`echo "$P" | sed 's%\(.\)%\1\.\*%g'`;
echo "P1=$P1'"
grep -o "$P1" *.po | grep -v "$P" | grep -vE "$MPDBNOT";
done<<EOI
$(echo "$MPDB")
EOI
P=<b>.*</b>'
P1=<.*b.*>.*..**.*<.*/.*b.*>.*'
<b>Teknisk set</ b> \n"
<b> Advarsel </ b> \n"
P=<u>.*</u>'
P1=<.*u.*>.*..**.*<.*/.*u.*>.*'
P=<i>.*</i>'
P1=<.*i.*>.*..**.*<.*/.*i.*>.*'
Hi again
Thank you for pinpointing problems in the markup.
With your help I eventually managed to make the quicksetup.mo work
I tried to translate the screeny.mo file - and I was VERY carefull not to make the same mistakes this time. - Even so it won't compile into a mo file and copy itself into the locale dir....
I've attached a zipfile with po, pot, a write log and a text file...
I don't understand why it shouln't work - as I have been *VERY* carefull this time ....
Cheers Måns Mårtensson
Thank you for pinpointing problems in the markup.
With your help I eventually managed to make the quicksetup.mo work
I tried to translate the screeny.mo file - and I was VERY carefull not to make the same mistakes this time. - Even so it won't compile into a mo file and copy itself into the locale dir....
I've attached a zipfile with po, pot, a write log and a text file...
I don't understand why it shouln't work - as I have been *VERY* carefull this time ....
Cheers Måns Mårtensson
- Attachments
-
- screenyproblems.zip
- po, pot, a write log and a text file...
- (5.33 KiB) Downloaded 535 times
-
- capture21980.png
- No success
- (12.06 KiB) Downloaded 427 times
-
- capture20637.png
- Success :-)
- (35.86 KiB) Downloaded 515 times
Pet with danish Abiword strings and QuickSetup
Hi again
I've added a translation of AbiWord provided by my friend Morten (mjjzf) and made a change to the system.profile file - now it saves to word format as default...
QuickSetup is finally in place - thanks to you
langpack_da-20130409.pet
Cheers Måns Mårtensson
I've added a translation of AbiWord provided by my friend Morten (mjjzf) and made a change to the system.profile file - now it saves to word format as default...
QuickSetup is finally in place - thanks to you
langpack_da-20130409.pet
Cheers Måns Mårtensson
- L18L
- Posts: 3479
- Joined: Sat 19 Jun 2010, 18:56
- Location: www.eussenheim.de/
Danish language pack
screeny.po is enoughmaans wrote:...I've attached a zipfile with po, pot, a write log and a text file...
# msgfmt screeny.po
screeny.po:39:3: invalid multibyte sequence
screeny.po:39:4: invalid multibyte sequence
screeny.po:40:4: invalid multibyte sequence
screeny.po:40:5: invalid multibyte sequence
screeny.po:40:41: invalid multibyte sequence
screeny.po:40:42: invalid multibyte sequence
screeny.po:41:3: invalid multibyte sequence
screeny.po:41:4: invalid multibyte sequence
screeny.po:41:51: invalid multibyte sequence
screeny.po:41:52: invalid multibyte sequence
screeny.po:42:7: invalid multibyte sequence
screeny.po:42:8: invalid multibyte sequence
screeny.po:45:10: invalid multibyte sequence
screeny.po:45:11: invalid multibyte sequence
screeny.po:45:17: invalid multibyte sequence
screeny.po:45:18: invalid multibyte sequence
screeny.po:45:26: invalid multibyte sequence
screeny.po:45:27: invalid multibyte sequence
screeny.po:45:70: invalid multibyte sequence
screeny.po:45:71: invalid multibyte sequence
msgfmt: too many errors, aborting
#
"Content-Type: text/plain; charset=ASCII\n"
We use UTF-8
changed to UTF-8
and
compiled without error# msgfmt screeny.po
#
I really should make momanager manage those faults....
Code: Select all
loop until mo file is created
let user edit po file
if editor closed then msgfmt po -o mo
if error continue
...but maybe Karl is hurtiger