CreateWindow/Ex function creates object in different fonts
Posted on 1998-06-30
I have an application that consists of about 15/20 buttons on about 20/30 forms. Depending upon the user's
rights and current and last activity performed, about 4-5 of them are active.
I recently derived a class to handle the common activities, Instead of creating 30 forms with the same
button map below, I decided to use CreateWindow function and creates button at runtime.
Positioning of button worked out very fine simply by use of bounding static control and computing
each size from it.
Problem is that button fonts are always Bold. While I know the WM_PAINT and Windows DC
functions, I do want to write separate Windowproc to redraw buttons (effectively re-inventing wheel)
I also tried CreateWindowEx but with no luck