Positioning .net controls while resizing -
09-14-2005
, 09:20 AM
I have a form with a number of .net controls (buttons, scrollbars etc)
I have overridden WndProc and done all erasing of background areas and
painting the foreground myself. This allowed me to draw (graphs) on
the form.
I double buffer my drawing and when I re-size the window, all my stuff
re-draws perfectly as do any windows controls that are 'anchored' in
place.
Any windows controls I explicitly place on the form by altering .top
and .left jump around and flicker. If I re-size quickly they sometimes
ending up in the wrong place but will jump back when I make a small
movement again!
Any ideas? I tried a really simple app just with 2 buttons, one
anchored and one with it's position set in code when the form is
re-sized. Even that flickered a little so I must me missing something
basic...
Thanks in advance!
Andy |