Screen goes mental for a bit when resizing the form

  • Thread starter Thread starter Simon Harvey
  • Start date Start date
S

Simon Harvey

Hi everyone,

I have a windows form application that looks a little bit like outlook
in that it has a menu system on the left and then the main area to the
right has a horizontal splitter thing going on.

Many of the controls are contained in panels, which are in turn
contained in user controls.

The problem is when the user resizes or maximises the form, the screen
goes mental for a bit.

Is there anyway I can prevent this from happening. I'd just like the
whole thing to be a bit "cleaner"

Many thanks

Simon
 
#1 What do you mean by "goes mental" Computing is an exact science....

#2 Are you doing your own layout or custom drawing?

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.
 
Hi

I'm not doing any custom drawing - just using user controls with docked
panels.

In terms of it's mentalness, it flickers a lot and it seems that you can
almost see the internal panels trying to resize themselves to take up
more space. It's particularly prominent on larger moniters.

Is there any way to reduce this?

Many thanks

Simon
 
You should be able to disable the update while the form is being
rezised. You might try using Suspend/ResumeLayout or Begin/EndUpdat. I
made a quick look in the docs for how to detect the sizing but I
didn't see an OnSizeChanging (etc) to override. There may be an event
on the form or on Panel that you can handle for this, otherwise you
might have to do it in mouse down/up handlers. HTH.
 
Back
Top