|
|
Browse by Tags
All Tags » Code » History
Sorry, but there are no more tags available to filter with.
-
If you want to register a window class and use a system color
as its background color, you set the hbrBackground member
to the desired color, plus one, cast to an HBRUSH:
wc.hbrBackground = (HBRUSH)(COLOR_WINDOW + 1);
Windows 95 introduced ''system color brushes'',
which are a magic type of brush which always paint in the
corresponding ...
-
Last time, I talked about the historical background for
the CS_OWNDC class style and why it starts out
sounding like a good idea but when you think about it some more
turns out to be an awful idea.
The CS_CLASSDC class style is the same thing, but worse,
for it takes all the problems of CS_OWNDC and magnifies them.
Recall that the CS_OWNDC ...
-
Recall that window DCs are most commonly used only temporarily.
If you need to draw into a window, you call
BeginPaint
or, if outside of a paint cycle, GetDC,
although painting outside of a paint cycle is generally to be avoided.
The window manager produces a DC for the window and returns it.
You use the DC, then restore it to its original state ...
|
|
|