Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 6th September 2006, 06:26   #1
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
Talking Background Color (MUI + IOEx) of Installer

Hey all,
I figured it out how to change the bgcolor of the installer.
Including the controls.
But there is one thing I cannot get to work.
I've got 2 custom pages. In the First I change the color including the section where the buttons are.

code:

InstallOptionsEx::initDialog /NOUNLOAD "$TEMP\First.ini"
FindWindow $R1 "#32770" ""
Pop $R1
SetCtlColors $R1 0x000000 0x919CA0
SetCtlColors $HWNDPARENT 0x000000 0x919CA0
InstallOptionsEx::Show



After leaving the first custompage it loads the second page.
But with different colors. I want it to load the default colors.

code:

InstallOptionsEx::initDialog /NOUNLOAD "$TEMP\Second.ini"
FindWindow $R1 "#32770" ""
Pop $R1
SetCtlColors $R1 0x000000 0xD4D0C8
SetCtlColors $HWNDPARENT 0x000000 0xD4D0C8
InstallOptionsEx::Show



But this doesn't work. Can it be done? Or am I looking in the wrong direction.


Glimmerman
The Glimmerman is offline   Reply With Quote
Old 7th September 2006, 00:17   #2
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
nobody.
The Glimmerman is offline   Reply With Quote
Old 8th September 2006, 15:58   #3
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,336
If you want the custom page to use the default colors, simply don't change its colors. If you're talking about $HWNDPARENT getting back the default Windows color, you could use the /BRANDING switch with no other parameters. It should set the default gray color.

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 11th September 2006, 10:34   #4
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
@kichik

If I use the /BRANDING option.
Like this:
SetCtlColors $HWNDPARENT /BRANDING
(Or any other var used in FindWindow.)

It uses the colors I used in my first custom page.
And it does not change to the default grey color.

A bug maybe? Or My error.
The Glimmerman is offline   Reply With Quote
Old 15th September 2006, 08:04   #5
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,336
The branding color is the default gray color of Windows. If that's not the default color you're looking for, I don't know which default color you refer to.

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 15th September 2006, 14:17   #6
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
I know what you mean.
Thats the color I want.
But my first custom page is this color (0x919CA0)
The whole page.
My second custom page right after clicking the next button.
Thats the page I want grey (default color).
But when I use branding I takes the color I use above ( My first custom page color) and not the default grey color I want.
The Glimmerman is offline   Reply With Quote
Old 15th September 2006, 16:12   #7
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,336
I can't see how this could happen. Attach your script, it might shed some light.

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 18th September 2006, 06:03   #8
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
Here's my script. The part that doesn't work.
If you want I can pm the whole script to you.


thx
Attached Files
File Type: zip my script.zip (4.1 KB, 164 views)
The Glimmerman is offline   Reply With Quote
Old 22nd September 2006, 11:08   #9
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,336
Well, /BRANDING won't help here because it's transparent and the color "behind" the dialog is still the old color until you move the window.

Since SetCtlColors doesn't accept variables, you can't call GetSysColor yourself and set that color as the background. You can, however, add another label to the main dialog. You can then set a color to that label and hide it using ShowWindow when you want the original color.

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 25th September 2006, 10:14   #10
The Glimmerman
Junior Member
 
Join Date: Jul 2006
Posts: 43
mmm I will try this out.

Thx kichik
The Glimmerman 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