We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Initial toolbar drawing causes screen flashing

Thread ID:

Created:

Updated:

Platform:

Replies:

26282 Mar 18,2005 02:17 PM UTC Mar 21,2005 05:46 PM UTC Windows Forms 4
loading
Tags: Tools
Mick Speake
Asked On March 18, 2005 02:17 PM UTC

Although I pre-register all MDI child types the intial drawing of the menus/toolbars causes the screen to flash. This effect is exacerbated when the screen background is set to a bit map. It looks like the following happens :- - backdrop is painted - menus/toolbar painted - backdrop repainted Can you suggest a way to avoid this? I enclose the XPmenusMDI example with the following changes :- - application opens maximised - backdrop is set to logo.jpg I know it is only a small point but I would like to achieve the same slick look as in for example starting Word. Thanks, Mick XPMenusMDI2_9651.zip

Administrator [Syncfusion]
Replied On March 18, 2005 07:45 PM UTC

Hi Mick, There were some issues with flickering in v3.0 of XPMenus. There are some workarounds/hacks that can be done to reduce the flickering, you could wait for our next release, or you could create a DirectTrac incident and request the build that the XPMenu flicker was fixed in. If you prefer the former, please let me know and I''ll provide you the list of workarounds. Regards, Gregory Austin Syncfusion Inc.

Mick Speake
Replied On March 19, 2005 09:12 AM UTC

Thanks for the feedback, Gregory. I''ll try the workarounds, first, if you could let me have the details. Regards, Mick

Administrator [Syncfusion]
Replied On March 21, 2005 04:05 PM UTC

Hi Mick, After reviewing your application, there are two things that cause the flickering. The first is that the background image is set (and therefore sized) before the Toolbars have been loaded. This can be prevented by adding a call to SuspendLayout() before setting the background image in the constructor. You can then start a short Timer at the end of your Form.Load event handler, that calls ResumeLayout(true) when it''s done. This will prevent the background image from being sized until after the Toolbars are loaded. The second problem is that your application is being immediately Maximized after loading. This effectively doubles the flickering you experience. This can be avoided by not maximizing your window and setting the Form size to the WorkingArea of the Primary Screen. public MainForm() { //Majority of Constructor this.Size = System.Windows.Forms.Screen.PrimaryScreen.WorkingArea.Size; this.SuspendLayout(); //Set background image } private void Form1_Load(sender, e) { //Current Code this.timer1.Start() } private void timer1_Start(sender, e) { this.ResumeLayout(true); } These changes should make your application look much better. Please let me know if you have any further questions or concerns. Regards, Gregory Austin Syncfusion Inc.

Mick Speake
Replied On March 21, 2005 05:46 PM UTC

Thanks, Gregory, That''s a big improvement. Regards, Mick

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;