Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Any update on this.
It makes an enormous different in scrolling speed for a complex layout
I t make the unusable usable.
Although I cannot provide you with an estimate for the introduction of this functionality, I can say that we are keenly aware of just how needed it is. In fact, once it is implemented, you will be automatically notified. Thank you kindly for your input on our product
With all the work on DirectX implementation and Performance I would hope this could get a look in. The XtraLayout control is a great way to provide a managable/adaptive/responsive interface for WinForms. Currently the performance for scrolling is so chunky.
If Breaking Changes are an issue could a new XtraScrollableLayoutControl be created? Not a great name admittantly but just a thought?
Hi Michael,
At the moment, we don't have plans to implement a new LayoutControl version. Still, improving LayoutControl performance remains one of our goals. I would appreciate it if you could send us a sample project demonstrating the layout you are creating with the help of LayoutControl. This will help us better understand your scenario and the way you are using LayoutControl.
Well if no-one is coming up with a solution after ten years, it ain't happening so I'll post something.
Attached is some fairly short code which is a custom LayoutControl (LayoutControlAce) I use and, relevant here, a LayoutControlAceScrollManager class which basically takes a LayoutControlAce in its ctor and then inserts an XtraScrollControl between the LayoutControlAce and its parent to deal with the scrolling. It supports WM_MOUSEWHEEL messages too.
Scrolling is then very fast.
The LayoutControlAce adds a couple of features to a LayoutControl but is basically the same - you can remove the bits you don't need. It does however have a ScrollManager internal property so that its UpdateMinSize() can be called automatically.
On the Form (or UserControl or whatever) containing your slow-scrolling LayoutControl, Just replace it with a LayoutControlAce (I just finger-poke a couple of lines in the .Designer file) and add this in the ctor to try it out and see if it works well for your scenario:
new LayoutControlAceScrollManager(myTestLayoutControlAce);
The UpdateMinSize() is public so if you make a lot of changes or populate your LayoutControl in code, you can follow this pattern:
myLayoutControlAce.BeginUpdate(); try { // Your layout control population code here } finally { layoutControlAceScrollManager.UpdateMinSize(); myLayoutControlAce.EndUpdate(); }
Hi,
Thank you for sharing your solution. I reviewed it and see that it is very complex and relies on some internal mechanisms which are designed for internal use only and aren't meant to be used in your code.
As a possible solution, I would recommend creating tabbed groups. For this, you can either use built-in Tabbed Groups or add a new Tab Control to the target form and add separate Layout Controls to each tab page. The latter approach is recommended in the case of a large number of controls as it significantly improves performance.
Nevertheless, we keep this on our radars and will definitely improve this behavior if we find a reliable solution. Once this is done, we will publish this on our What's New page.
When I wrote this code originally, it was necessary otherwise my large Layout scenario was unusable.
Things have improved greatly in LayoutControl since then.
However, even just six months ago, someone wanted better performance so I posted this to see if it made a difference for them.
The code involved for scrolling isn't very complex at all.
The only override in LayoutControlAce is InvalidateRootOffsetControlsAndScrolls() which doesn't alter the default behaviour at all but uses that as the moment to update AutoScrollMinSize on the XtraScrollableControl. And that method is virtual not internal.
So which internal mechanism are you referring to?
The WM_MOUSEWHEEL support is also not necessary but it is better than the support currently in the LayoutControl whereby the mouse wheel only scrolls when not over another control - so if you have a large layout - several screens high - and want to scroll through it with the mouse wheel, it works but only as long as another control doesn't scroll under the mouse whereby it stops and you have to move your mouse and try again.
And what is this suggestion about Tabs?? You are expecting folks to redesign their Layout?
Thank you for the clarification. I understand your situation and agree that the change of the existing layouts can require a lot of work (if your application design permits this at all). Since we haven't found a way to improve the scrolling performance of Layout Control yet, I would like to share some more information on how to improve your application performance.
If your application design requires displaying many controls simultaneously, you can build the required layout using our TablePanels and StackPanels. By using these controls, you can build quite complex layouts.
We improved these controls in the upcoming version (20.1). Now, they support auto-size, the ability to temporarily hide specific rows and columns, and some others features.