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 Thu 19 Oct 2017, 22:04
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Projects » Localization Project
Rox and desktop files: how to display Comment[fr]
Moderators: Lobster, MU, raffy
Post new topic   Reply to topic View previous topic :: View next topic
Page 3 of 6 [86 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6 Next
Author Message
ASRI éducation


Joined: 09 May 2009
Posts: 3203
Location: France

PostPosted: Mon 06 Apr 2015, 14:11    Post subject:  

Thank you mikeb!

My test:
1 - Replace the existing rox-filer in /usr/local/apps/ROX-filer.
2 - Restart X.
3 - Open /usr/share/applications, then try with file abiword.desktop.

Result:
- With Comment[fr_FR] it is ok.
- With Comment[fr] it is not ok (comment is in english).
This is the beginning of a solution. Alas, usually the desktop files indicate only the first two characters of the language: en, de, fr, es, it...

Regards
rox_comment_fr_NOT_OK_20150406.jpg
 Description   
 Filesize   56.13 KB
 Viewed   365 Time(s)

rox_comment_fr_NOT_OK_20150406.jpg

rox_comment_fr_FR_OK_20150406.jpg
 Description   
 Filesize   56.66 KB
 Viewed   390 Time(s)

rox_comment_fr_FR_OK_20150406.jpg


_________________
Projet ASRI éducation => Association | Forum | Dépôt | Espace kids
Back to top
View user's profile Send private message Visit poster's website 
augras

Joined: 11 Nov 2013
Posts: 1446
Location: france

PostPosted: Mon 06 Apr 2015, 14:12    Post subject:  

Hi mikeb
Thanks for your works.
I just try on tahrpup6.0.2 and it works with fr_FR in the .desktop file but not with just fr.
Unfortunately when there is a french comment it seems to be with just fr and not fr_FR. I just take a look on few files and it was always like this !
Thanks again.
Philippe
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 2007
Location: Germany

PostPosted: Mon 06 Apr 2015, 14:20    Post subject:  

Quote:
With Comment[fr_FR] it is ok.
With Comment[fr] it is not ok (comment is in english).

Confirmed!

My .desktop files have only [de]. After changing some of them to [de_DE] it shows immediately comments in DE. No need at all to replace the original binary nor to restart X here. Just executed the extracted binary from its extraction directory for testing.

_________________
RSH

"you only wanted to work your Puppies in German", "you are a separatist in that you want Germany to secede from Europe" (musher0) Laughing

No, but I gave my old drum kit away for free to a music store collecting instruments for refugees! Wink
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 10958
Location: Gatineau (Qc), Canada

PostPosted: Mon 06 Apr 2015, 14:23    Post subject:  

mikeb wrote:
Did you replace the existing rox-filer in /usr/local/apps/ROX-filer .

If its truly stopped including pinboard and LANG is set which it sounds like then hmmmm

well the previous post about extra fallbacks may apply. IE your specific LANG variable may not be in there ... utf8 should be ok but fr_FR will not find fr as it stands... editing a desktop file would be the test...echo $LANG and ensure there is an entry to match.
Every desktop file seems to have a different set of languages or none.

I used rox's own extraction and handling of LANG

I can fix but in any other language its a 20 second job but in the obtuse bitch known as c it will be half an hour for multiple rebuilds and tests. Very Happy

mike


Hi, mikeb.

Thanks for these details.

FWIW... Wink I'm French-Canadian and these are the varioous LANG
variables that I insert in /etc/profile.local:
Code:
export LANG="fr_CA.utf8"
export LANGUAGE="fr_CA.utf8"
export LC_CTYPE="fr_CA.utf8"
export LC_NUMERIC="fr_CA.utf8"
export LC_TIME="fr_CA.utf8"
export LC_DATE="fr_CA.utf8"
export LC_MONETARY="fr_CA.utf8"
export LC_MESSAGES="fr_CA.utf8"
export LC_PAPER="fr_CA.utf8"
export LC_NAME="fr_CA.utf8"
export LC_ADDRESS="fr_CA.utf8"
export LC_TELEPHONE="fr_CA.utf8"
export LC_MEASUREMENT="fr_CA.utf8"
export LC_IDENTIFICATION="fr_CA.utf8"
export LC_ALL=""


But < Comment[fr] > or < GenericName[fr] > in *.desktop files are
recognized by my system. (Hmmm... how would I know that?) In any
case I can use the French-from-France localization files OOTB.

If it may be a hindrance Wink, here are the contents of file
aOOwriter.desktop. It has the most comments[xy] that I know of and it
probably holds the Guinness record of fattest *.desktop file.

I'll try a full reboot and see what that does.

BFN.

musher0
writer.desktop.zip
Description 
zip

 Download 
Filename  writer.desktop.zip 
Filesize  9.9 KB 
Downloaded  234 Time(s) 

_________________
musher0
~~~~~~~~~~
"Logical entities must not be multiplied beyond necessity." | |
« Il ne faut pas multiplier les entités logiques sans nécessité. » (Ockham)
Back to top
View user's profile Send private message 
mikeb


Joined: 23 Nov 2006
Posts: 11071

PostPosted: Mon 06 Apr 2015, 14:30    Post subject:  

Ok so general consensus is the need to handle fr and fr_FR variation of LANG variables... ok will add that and post the result later.... not in Lucid at the moment and REALLY hungry...

Now what's the system definition of later?

if anyone wants this for older pups ROX 2.10 works ok...its before they changed from glade which is where the library changes are needed..just shout. Functionally there seems little difference in the two versions apart from this.


mike
Back to top
View user's profile Send private message 
ASRI éducation


Joined: 09 May 2009
Posts: 3203
Location: France

PostPosted: Mon 06 Apr 2015, 14:33    Post subject:  

mikeb wrote:
Ok so general consensus is the need to handle fr and fr_FR variation of LANG variables... ok will add that and post the result later.... not in Lucid at the moment and REALLY hungry...

Thank you in advance.
No actual emergency, you have time to eat. Wink

_________________
Projet ASRI éducation => Association | Forum | Dépôt | Espace kids
Back to top
View user's profile Send private message Visit poster's website 
musher0


Joined: 04 Jan 2009
Posts: 10958
Location: Gatineau (Qc), Canada

PostPosted: Mon 06 Apr 2015, 14:43    Post subject:  

Hurrah! Comment[fr_CA] works!

If it's a simple matter of changing Comment[fr] to Comment[fr_CA], then
replaceit can do it in a jiffy:

Code:
cd /usr/share/applications
for i in `ls -1 *.desktop`
do replaceit --input=$i "Comment[fr]" "Comment[fr_CA]"
done


People from the East side of the Great Pond will use fr_BE, fr_FR or
fr_CH of course.

Some may think that it's not be exactly kosher to do so. Anyway, the
micro-script is there if you need it.

Just a thought. Bon appétit! Smile

musher0

_________________
musher0
~~~~~~~~~~
"Logical entities must not be multiplied beyond necessity." | |
« Il ne faut pas multiplier les entités logiques sans nécessité. » (Ockham)

Last edited by musher0 on Mon 06 Apr 2015, 14:58; edited 1 time in total
Back to top
View user's profile Send private message 
L18L

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

PostPosted: Mon 06 Apr 2015, 14:46    Post subject: Rox and desktop files
Subject description: how to display translated Comments
 

ASRI éducation wrote:
No actual emergency, you have time to eat. Wink

Back to top
View user's profile Send private message 
mikeb


Joined: 23 Nov 2006
Posts: 11071

PostPosted: Mon 06 Apr 2015, 14:51    Post subject:  

fichiers Desktop sont très exigeantes
don't blame me though my translation was worse...

I don't want to pass out while compiling.... please don't hold any breath during this food related pause

Actually i will slip a note into the version output to distinguish the build.

mike
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 10958
Location: Gatineau (Qc), Canada

PostPosted: Mon 06 Apr 2015, 15:00    Post subject:  

mikeb wrote:
fichiers Desktop sont très exigeantes
don't blame me though my translation was worse...

I don't want to pass out while compiling.... please don't hold any breath during this food related pause

Actually i will slip a note into the version output to distinguish the build.

mike


Stop babbling! Go! Your hamburg steak will get cold!!!

_________________
musher0
~~~~~~~~~~
"Logical entities must not be multiplied beyond necessity." | |
« Il ne faut pas multiplier les entités logiques sans nécessité. » (Ockham)
Back to top
View user's profile Send private message 
mikeb


Joined: 23 Nov 2006
Posts: 11071

PostPosted: Mon 06 Apr 2015, 15:07    Post subject:  

Ah ha...the formula that states productivity is inversly proportional to time spent on the forum.

Well I am the chef so its a bit time consuming and I post inbetween ingredients. Smile

If I try and edit .c files I would burn the result.

Mike
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 10958
Location: Gatineau (Qc), Canada

PostPosted: Mon 06 Apr 2015, 16:24    Post subject:  

Let's see. The recipe says: add a pinch of C on the steak, then dice the
carrot onto edit.c, and stir... Smile

_________________
musher0
~~~~~~~~~~
"Logical entities must not be multiplied beyond necessity." | |
« Il ne faut pas multiplier les entités logiques sans nécessité. » (Ockham)
Back to top
View user's profile Send private message 
mikeb


Joined: 23 Nov 2006
Posts: 11071

PostPosted: Mon 06 Apr 2015, 17:24    Post subject:  

Ahhh string manipulation is so painfully ugly... well only took and hour or so to split about the _ ...actually my printf did not show until closing this time just to confuse.

Ok this should try full LANG and then just the first part and finally use fallback

mike
Back to top
View user's profile Send private message 
musher0


Joined: 04 Jan 2009
Posts: 10958
Location: Gatineau (Qc), Canada

PostPosted: Mon 06 Apr 2015, 21:01    Post subject:  

Ahhh, what mikeb can do on a full stomach!!!

Magnificent! Fantastic! How can we ever repay you! Wow! Yippee!
Many, many thanks! (Background noise of audience applauding... fade-out)
Smile Cool Laughing Very Happy
Absolutely_Terrific!!!_2015-04-06.jpg
 Description   
 Filesize   63.49 KB
 Viewed   238 Time(s)

Absolutely_Terrific!!!_2015-04-06.jpg


_________________
musher0
~~~~~~~~~~
"Logical entities must not be multiplied beyond necessity." | |
« Il ne faut pas multiplier les entités logiques sans nécessité. » (Ockham)
Back to top
View user's profile Send private message 
LazY Puppy


Joined: 21 Nov 2014
Posts: 2007
Location: Germany

PostPosted: Mon 06 Apr 2015, 21:13    Post subject:  

Quote:
Magnificent! Fantastic!

Confirmed! Very Happy

_________________
RSH

"you only wanted to work your Puppies in German", "you are a separatist in that you want Germany to secede from Europe" (musher0) Laughing

No, but I gave my old drum kit away for free to a music store collecting instruments for refugees! Wink
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 3 of 6 [86 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Puppy Projects » Localization Project
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0570s ][ Queries: 14 (0.0053s) ][ GZIP on ]