Old 14th August 2012, 08:53   #1
SunToo
Junior Member
 
Join Date: Apr 2007
Posts: 38
How to set installer name after .onInit

Hi,
is there any way to set the content of the installer attribute "Name" after the method .onInit to adapt the caption of all Windows.

Note: I don't want to set the whole caption of the windows, just the "Name" part to maintain the language dependent part ("Setup", "Installation de" ...) added by NSIS. So

SendMessage $HWNDPARENT ${WM_SETTEXT} 0 "STR:Title"

is not what I'm looking for.
SunToo is offline   Reply With Quote
Old 14th August 2012, 21:12   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,163
Name can be a variable that you set in .onInit

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 15th August 2012, 05:11   #3
SunToo
Junior Member
 
Join Date: Apr 2007
Posts: 38
Hi Anders,
changing the variable value after .onInit has no impact on the caption of the windows. It only changes the text within the pages that use the name.
SunToo is offline   Reply With Quote
Old 15th August 2012, 05:23   #4
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,163
Well, how often do you need to change it? Per page?

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 15th August 2012, 05:28   #5
SunToo
Junior Member
 
Join Date: Apr 2007
Posts: 38
Just one time after .onInit.
SunToo is offline   Reply With Quote
Old 15th August 2012, 06:10   #6
MSG
Major Dude
 
Join Date: Oct 2006
Posts: 1,892
Couldn't you grab the text currently displayed on the menubar with wm_gettext or something, and cut off the software name to get the language-dependent part?
MSG is offline   Reply With Quote
Old 15th August 2012, 06:13   #7
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,163
$(^SetupCaption) is the default caption and it is just "$(^Name) Setup", you can find the rest of the strings @ http://nsis.svn.sourceforge.net/view...n=&view=markup and you can now build a string for use with WM_SETTEXT

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast 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