I''m using XP Menus and toolbars. All of my mdi client windows inferit from a baseform that has two toolbars associated with it. When I open/close forms, the toolbar is cleared and redrawn each time, causing a lot of flicker. Is this normal?
ADAdministrator Syncfusion Team June 3, 2004 05:31 PM
I have created a test sample as per your specifications, and do see a minimum amount of flicker when one of the MDI child forms are closed. I am afraid, this cannot be avoided, since the menu merging feature forces the main menu bars and toolbars to be redrawn without the merged BarItems of the child (when the MDI child is closed). Let me know if you have any suggestions in this regard. We appreciate your interest in Syncfusion products.
AUAndy UllmanJune 4, 2004 06:01 AM
Thanks for your reply.
I can see the flicker in your sample, but it isn''t as bad as mine (probably because I''ve got more toolbars and they have icons on them).
I reran an older version of my app, which uses 126.96.36.199, and the flicker problem is much worse in 188.8.131.52. The new version seems to clear the menu briefly, then redraw ALL client windows at new positions, then redraw the menu and shift ALL client windows down again. If you''ve got a lot of windows open, it really looks bad and I think is unacceptable.
In version 184.108.40.206, the toolbar flickers briefly but the main menu and client windows are unaffected.
As for suggestions about redrawing the toolbars in general, I wonder if you could add some intelligence to determine if the toolbars need to be redrawn when a client window is opened/closed. I noticed that if I open multiple copies of the same form, there is no redraw. In my app, I''m opening different forms, but they derive from one common form that has the childbarmanager/toolbars, so perhaps the code could be enhanced to recognize that no redraw is necessary in this case.
AUAndy UllmanJune 4, 2004 06:36 AM
Please check out the attached sample. I modified the XPMenus sample so that it displays derived forms, in addition to the original 2 forms. You''ll notice there is no flickering opening/closing the original 2 forms. If you go to the File menu and choose ''New Derived Form'' a few times, there will be lots of flicker. Clearly there is a problem with derived forms.
The other interesting thing is that this sample does not display the jerking up and down of the client windows that I described. My app (and your test sample) both have this problem. What''s going on?
ADAdministrator Syncfusion Team June 7, 2004 05:49 AM
Thanks for the detailed update and the sample application. I do see that the menus get redrawn (resulting in a flicker) only if the derived forms are closed, and closing the base form does not result in redrawing of the menus. I have notified the development team in this regard, and will update you as soon as I have more information available.
ADAdministrator Syncfusion Team June 10, 2004 01:07 PM
I''ve only briefly skimmed over your posts but with regards to windows jumping you may want to check the size of your icons in the toolbars and make sure they are all consistent. The toolbar will resize to fit the icons within it - and therefore if say a toolbar is added with an icon 1 pixel taller than the icons in the other toolbar then all the ''frames'' below will shift a pixel and redraw.
This may be part of your issue.
ADAdministrator Syncfusion Team June 10, 2004 08:35 PM
Thanks for your inputs on this issue. I have conveyed this to the development team, and will update you as soon as I have more information available. We appreciate your interest in Syncfusion products.
KMKrijn MichielsJune 16, 2004 01:16 AM
I was just wondering about the possibility of merging a MainFrameBarManager with a derived ChildFramebarManager (or merge the mainframebarmanager with a second mainframebarmanager).
1. When we derive childforms from one baseform with a childframebarmanager, the mainframebarmanager is constantly updating. This is useless when no custom menus or toolbars are added on the derived forms.
2. Custom added toolbars will only be visible when the form of that specific type is opened instead of staying visible when one of the derived forms from the baseform.
I would be great if there was a function RegisterMdiChildTypes that takes childframebarmanagers as a parameter.
An option if the toolbars must be visible when none of the childforms are opened.
KMKrijn MichielsJune 17, 2004 11:07 AM
I want to use a MDI application where I could load several ''sub'' applications and run them all at the same time. With the use of derived forms the main form is constantly updating as mentioned in several forum items.
I''ve managed to create a workaround for this problem.
1. Do not create forms, create usercontrols instead
2. Create one form for each ''subapplication''. Add a childframebarmanager on the form and design your menus.
Add some code to the form :
Public Sub New(control as UserControl)
control.Dock = Docking.Fill
(maybe you want to put this code in a baseform first !)
Now you can start different subapplicationforms wich use the same ChildFrameBarManager without flickering (because the MDIChild form type doesn''t change). :
For example :
Dim fillInForm as New SubApplication1FillInForm()
Dim subApplication1Form as new SubApplication1Form(fillinForm)
subApplication1Form.MDIParent = Me
The SubApplication1FillInForm is the usercontrol that looks like a regular form.
The SubApplication1Form is the container form that contains the ChildFrameBarManager and the usercontrol passed as parameter in the constructor.
Is this the way it has to be done, or is there a better one ?
ADAdministrator Syncfusion Team June 22, 2004 02:43 AM
Yes, this looks like a very good workaround for the problem you are facing.
The reason the menus treat each derived form as unique is because there is no way it can find out that the contents of the derived forms are the same.
We could provide a bool property in the manager through which the developer can say that there is in fact no new items added in the dervied bar manager. But, this could result it unforseen errors if this property gets set mistakenly and especially since we cannot ensure the validity of this setting.
AUAndy UllmanJune 22, 2004 06:23 AM
Please note I have opened direct-trac incident 11974 with respect to this issue.
>Yes, this looks like a very good workaround for the problem you are facing.
>The reason the menus treat each derived form as unique is because there is no way it can find out that the contents of the derived forms are the same.
>We could provide a bool property in the manager through which the developer can say that there is in fact no new items added in the dervied bar manager. But, this could result it unforseen errors if this property gets set mistakenly and especially since we cannot ensure the validity of this setting.