Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 21st December 2006, 12:51   #1
fluidz91
Member
 
Join Date: Jun 2006
Location: Paris - FR
Posts: 58
Dynamically change translation of languague file nsh ?

Hi,

is it possible to dynamically change the !define MUI_TEXT_WELCOME_INFO_TITLE found in French.nsh in a script ?

I need to do this because the name of application is "logiciel de recherche..."

and !define MUI_TEXT_WELCOME_INFO_TITLE "Bienvenue dans le programme d'installation de $(^NameDA)"

i want to change "de" by "du" but don't want to make the change directly in the French.nsh because the name of the app can change and i need the original text with "de" !

Thanks.
fluidz91 is offline   Reply With Quote
Old 21st December 2006, 15:05   #2
elfi.nator
Junior Member
 
Join Date: Dec 2006
Posts: 4
the easy way make a bakup of the language.nsh (with original text.

shortly heavier make some defines in the language nsh

example
!define MyCustomText "de" or du however is needed you must change it manually.

!define MUI_TEXT_WELCOME_INFO_TITLE "Bienvenue dans le programme d'installation ${MyCustomText} $(^NameDA)"
elfi.nator is offline   Reply With Quote
Old 22nd December 2006, 09:00   #3
fluidz91
Member
 
Join Date: Jun 2006
Location: Paris - FR
Posts: 58
Thank you very much, i'll try this.

Regards.
fluidz91 is offline   Reply With Quote
Old 4th January 2007, 13:27   #4
fluidz91
Member
 
Join Date: Jun 2006
Location: Paris - FR
Posts: 58
Hi,

it works perfectly as expected, except with file french.nlf for windows caption where i have the variable displaying instead of its value :

"Installation ${MyCustomText} MyAppNAme"

Any clue ?

thank you
fluidz91 is offline   Reply With Quote
Old 4th January 2007, 20:19   #5
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,337
You can't use that trick in NLF files. You'll have to change that string with the appropriate command, or LangString. On the NLF, before each line, the name of the internal LangString it fills is listed. Use that with the following:
code:
LangString ^SomeString ${LANG_FRENCH} "Installation ${MyCustomText} MyAppNAme"

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 5th January 2007, 09:24   #6
fluidz91
Member
 
Join Date: Jun 2006
Location: Paris - FR
Posts: 58
Hi kichik,

ok i think i get it ! Thx
fluidz91 is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump