Click here to Skip to main content
15,902,939 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: CStatic Image Painting problem Pin
Mark Salsbery26-Sep-07 7:55
Mark Salsbery26-Sep-07 7:55 
GeneralRe: CStatic Image Painting problem Pin
shivrajbhosale27-Sep-07 7:27
shivrajbhosale27-Sep-07 7:27 
GeneralRe: CStatic Image Painting problem Pin
Mark Salsbery27-Sep-07 7:39
Mark Salsbery27-Sep-07 7:39 
AnswerRe: CStatic Image Painting problem Pin
Hamid_RT26-Sep-07 18:55
Hamid_RT26-Sep-07 18:55 
GeneralRe: CStatic Image Painting problem Pin
shivrajbhosale27-Sep-07 7:29
shivrajbhosale27-Sep-07 7:29 
AnswerRe: CStatic Image Painting problem Pin
zakkas248327-Sep-07 0:20
zakkas248327-Sep-07 0:20 
GeneralRe: CStatic Image Painting problem Pin
shivrajbhosale27-Sep-07 7:24
shivrajbhosale27-Sep-07 7:24 
GeneralRe: CStatic Image Painting problem Pin
Shog927-Sep-07 8:10
sitebuilderShog927-Sep-07 8:10 
shivrajbhosale wrote:
Will invalidate the Dialog. and that causes flickering.

The dialog - especially the part of the dialog known as "the place where the Static control used to be" - is the bit that needs to be repainted. Invalidating the Static control isn't gonna do anything for it... since, as you may have noticed, the Static control isn't there anymore.

You can probably get by with calling InvalidateRect() on the dialog, specifying the area formerly occupied by the control. If you set the WS_CLIPCHILDREN style on the dialog, it'll even avoid drawing over the overlapping parts of the Static control (which is fine, unless that control or others use the WS_TRANSPARENT style...).

Frankly, i doubt there's much value in using a Static control for this purpose - it's one thing if you're just trying to display an icon or something as a fixed part of the dialog, but if you're gonna be doing anything non-trivial you might as well go all-out and render onto the dialog directly. Or create a custom control.


every night, i kneel at the foot of my bed and thank the Great Overseeing Politicians for protecting my freedoms by reducing their number, as if they were deer in a state park. -- Chris Losinger, Online Poker Players?

QuestionTab Control -- dialog resource question Pin
Izk26-Sep-07 7:01
Izk26-Sep-07 7:01 
AnswerRe: Tab Control -- dialog resource question Pin
Maximilien26-Sep-07 7:13
Maximilien26-Sep-07 7:13 
GeneralRe: Tab Control -- dialog resource question Pin
Izk26-Sep-07 9:09
Izk26-Sep-07 9:09 
GeneralRe: Tab Control -- dialog resource question -- Update solution Pin
Izk27-Sep-07 8:38
Izk27-Sep-07 8:38 
GeneralRe: Tab Control -- dialog resource question -- Updated further Pin
Izk27-Sep-07 10:59
Izk27-Sep-07 10:59 
QuestionGood C site for C++ programmer Pin
Mark J. Miller26-Sep-07 5:48
Mark J. Miller26-Sep-07 5:48 
AnswerRe: Good C site for C++ programmer Pin
Jeremy Falcon26-Sep-07 5:57
professionalJeremy Falcon26-Sep-07 5:57 
GeneralRe: Good C site for C++ programmer Pin
Mark J. Miller26-Sep-07 6:19
Mark J. Miller26-Sep-07 6:19 
GeneralRe: Good C site for C++ programmer Pin
Matthew Faithfull26-Sep-07 6:32
Matthew Faithfull26-Sep-07 6:32 
GeneralRe: Good C site for C++ programmer Pin
Jeremy Falcon26-Sep-07 7:32
professionalJeremy Falcon26-Sep-07 7:32 
GeneralRe: Good C site for C++ programmer Pin
John R. Shaw26-Sep-07 22:10
John R. Shaw26-Sep-07 22:10 
QuestionRe: Good C site for C++ programmer Pin
David Crow26-Sep-07 6:04
David Crow26-Sep-07 6:04 
AnswerRe: Good C site for C++ programmer Pin
Eytukan27-Sep-07 8:05
Eytukan27-Sep-07 8:05 
AnswerRe: Good C site for C++ programmer Pin
Mark J. Miller26-Sep-07 7:41
Mark J. Miller26-Sep-07 7:41 
GeneralRe: Good C site for C++ programmer Pin
Eytukan27-Sep-07 8:15
Eytukan27-Sep-07 8:15 
AnswerRe: Good C site for C++ programmer Pin
Hamid_RT26-Sep-07 19:01
Hamid_RT26-Sep-07 19:01 
QuestionSerialization of enumerated types Pin
bob1697226-Sep-07 5:05
bob1697226-Sep-07 5:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.