Reputation: 631
I am evaluating nsis. I want to create an installer (using mui2) which will use the provided Unicode strings (for titles, buttons, labels etc.) and not to use any "localization".
For example: the application title contains unicode characters from different languages (let's say: "Λεξικό-Dictionary-Речник
" will be the whole title, regardless of the user "language")
Is there a simple way to use the provided exact unicode strings independently of the mui language?
EDIT (as commented) : The above is about having own Unicode strings for buttons and, in general, UI text (no localization). Is not about any source (or destination) "filename" or "path".
Upvotes: 4
Views: 6888
Reputation: 631
The problem was I saved the file as UTF8 (!!!). After saving the file from Notepad as Unicode the problem disappeared.
Upvotes: 0
Reputation: 101666
NSIS will not translate the name, just make sure you save the .NSI source file as UTF-8 with BOM/Signature or UTF-16 with a BOM if you use non-ASCII characters.
Unicode True
Name "Λεξικό-Dictionary-Речник"
OutFile "MyInstaller.exe"
InstallDir "$ProgramFiles\$(^Name)"
!include MUI2.nsh
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_LANGUAGE English
Section
SetOutPath $InstDir
File /r "c:\myfiles\*.*"
SectionEnd
It is also possible to manually construct Unicode characters from Unicode code points:
Section
MessageBox MB_OK "${U+2115}SIS" # DOUBLE-STRUCK CAPITAL N + "SIS"
SectionEnd
Upvotes: 7