Is there a way to support translations?

Please let our ADS show!

This sites offers only FREE software and it's supported by a few advertisement boxes (no intrusive popups).
Please:

  • disable your AdBlocker by adding CoolSoft website to whitelist
  • give the proper cookie consent
  • enable JavaScript for this website

This seconds wait is to let you update your browser configuration...

Ok, I've done the required changes... now show me your content!
!!! Please enable JavaScript !!!
Anonymous user
Is there a way to support translations?

Is there a way to support translations? Normally in the script we would use someting like

${NSD_CreateLabel} 59u 72u 163u 13u $(SELECT_CPU_TEXT)

to use localized text.
This will not work with the Dialog Designer because it always enclose text associated with a control with quoation marks.

A extra option would be useful "use translation macro" or something similar... and when set, the text should be written as $(TEXT) without quotation marks

Posts: 1972
Joined: 25 Mar 2012 - 01:19
It already works

Composing a string by adding a variable inside a quited string is allowed in NSIS; the following code:

${NSD_CreateButton} 13u 68u 80u 23u "$(message)"

and creates a button with the content of "message" variable as caption.

You could also write:

${NSD_CreateButton} 13u 68u 80u 23u "prefix $(message) suffix"

and have the string automatically composed.

Please note that the lang string / variable must be defined before the line is executed.
If you tried this code into NSISDialogDesigner, the button appears with $(message) as caption, because the variable is not defined and there's no way to define it.
F5 will compile only a part of the script, no more that what's needed to give the user a visual preview of the form (see the content of %temp%\NSISDialogDesigner folder while the IDE is running).
Header, footer and custom script parts are not compiled because they could contain references to missing functions (included into your real script).

Just try a real script, define your language vars, include the .nsdinc file and it should work.
If it's not working, please send me your project (or at least a part of it).

Anonymous user
Yes, it's working! Very

Yes, it's working! Very great! (there was some bug with my macros)...

I wished only it has a editor so I must not switch every time between Eclipse and NSIS Dialog Editor :P