Detecting WM_SYSCOLORCHANGE Message in Form_Paint 
Author Message
 Detecting WM_SYSCOLORCHANGE Message in Form_Paint

Hello VB'ers,

Is there any simple method of determining if the VB Form_Paint Event (or a
PictureBox's Paint Event) was caused by a WM_SYSCOLORCHANGE Message?

I don't want to go to the effort of subclassing and watching for this
message, or using any OCX's etc. either.
That is a lot of work for just one silly message.

Currently I just track a module-level variable to see if ButtonFace changes,
and then go about any Palette-fixes for any of the "owner-draw" type images
that need their 3D Colors re-set.
However, it is possible to change the other system colors and still mess me
up (I guess I need to track one to three system colors).
I'm using DIBColorTable API's to modify image palettes for owner UI
elements, note that these are not standard VB intrinsic controls so I have
to handle the color tracking myself.

Thanks,
David
lilchips.com



Wed, 29 Dec 2004 18:35:52 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Detecting Messages in Message Que?

2. Form_Paint gets decoupled ???

3. labels dissapear mysteriously with Form_Paint

4. Strange behavior of Form_Paint and X close button.

5. Form_Paint occurs 3 times?

6. Problem with MDI and Form_Paint

7. How to unload a form while its still busy with Form_Paint

8. SelectClipRgn fails in Form_Paint()

9. How detect folder that messages are incomming

10. Detecting unread message(s) in folder and highlighting all folders above

11. Detecting unread message(s) in folder and highlighting all folders above

12. Detect IMAP message store programmatically?

 

 
Powered by phpBB® Forum Software