Changing Win32 menu colors

colors, menu, winapi

Solution

If I believe your comment to Rob, it is for a skinned application, with special look and feel. So the way to go is probably indeed, as ferek points out (in an unfriendly way...) to use owner-drawn menus: you will be able to define precisely their look.

Problem

Is there a way to change the colors used by plain Win32 menus (background, text, and highlight) for a single process, without using SetSysColors? (SetSysColors does a global change, which is bad, and if you crash or forget to set the colors back with SetSysColors again before exiting, they will not be restored until you logout.)

Original source