flyakite
5th February 2006 00:35 UTC
XPstyle on not applying to check boxes
I have a small tool that I am using "XPstyle on" in without the MUI. The XPstyle is applying itself to the buttons, but not to the checkboxes on the components page.
I opened the tool in Resource Hacker, and NSIS included the default flat black/white checkboxes. Yet, in another tool with a custom page and XPstyle on specified, the check boxes are not included, and the XPstyle is applied fully.
Does anyone have any idea what might be causing NSIS to include the default check boxes and use them, even with XPstyle on?
Thanks
Afrow UK
5th February 2006 11:41 UTC
The check boxes in the tree view on the Components page are not Windows check boxes. They are from a bitmap image at compile-time.
Modern UI uses:
CheckBitmap "${NSISDIR}\Contrib\Graphics\Checks\modern.bmp"
-Stu
{_trueparuex^}
5th February 2006 11:47 UTC
That's normal. XPstyle don't have effect on the checks because NSIS uses it's own bitmap to draw them.
To change the check bitmap use CheckBitmap function
CheckBitmap "${NSISDIR}\Contrib\Graphics\Checks\modern.bmp"
Edit: Great timing :/flyakite
6th February 2006 03:46 UTC
While I understand both reasons presented, why does the same action not occur on custom pages with InstallOptions? The images are not included at compile time, and it uses Windows to draw the correct images, so that it fits the style when XPstyle is on. Why can't the same behavior be applied to the default installer checkbox controls?
Afrow UK
6th February 2006 18:32 UTC
The tree view control implemented on the InstFiles page is not a list of check box controls (if that is what you are thinking unless you mean something else) and therefore does not inherit the Windows bitmaps of the selected Windows theme.
All other check box controls do inherit the Windows bitmaps (or should do).
Perhaps you could produce a screenshot if you mean otherwise.
-Stu
l_d_allan
6th February 2006 22:38 UTC
Just curious ... is there a simple way to use a circular bitmap to represent a RadioButton on the Components page? .... the square CheckBox that shows up implies (to me at least) multiple choices are acceptable, rather than mutually exclusive.
(see the one-section.nsi example ... which results in two groups of 3 radio buttons, except they are square check-boxes rather than circular.)
Afrow UK
7th February 2006 08:06 UTC
You'd have to create your own bitmap like the one in the ${NSISDIR}\Contrib\Graphics\Checks folder.
-Stu
Kemenaran
7th February 2006 11:40 UTC
Flyakite, if it is what you're interrested in, I have a bitmap that produce OSX-like checkboxes for NSIS ;)