This Blog


Favorite Posts


Major speed enhancements in WinForms grid (coming soon in v17.2)

Now that we’ve published the beta for v17.2, it’s time to reveal a major new enhancement for our WinForms grid. After reading this, I’m going to bet you’ll be downloading the installer and trying it out for yourself. Let us know your results!

WinForms. It’s been around since the very first days of .NET. Our first control for the run-time, released before .NET had even come out of beta (2002!), was XtraGrid, and we’ve released numerous other controls and suites for the platform since then. And after 15 years, Microsoft has pretty much frozen new development for WinForms. It’s got that taint of “legacy”.

And yet… People are still writing new thick-client apps for Windows. They have existing successful business apps in daily use that need maintaining and enhancing. Indeed, in every major release we provide new functionality and even new controls for WinForms. It is not going away.

MicrosoftDirectXOne big issue is that, compared to 15 years ago, the monitors and display adapters we use for Windows have become faster and have much higher resolution and WinForms has not kept up. We are now talking about and using 4K screens, so called because they are roughly 4,000 pixels horizontally (the main standard is 3840×2160, which is twice the resolution horizontally and vertically of the 1080p standard, or 4 times the number of pixels). Not only that, but the standard for drawing graphics on the screen has changed: it used to be GDI+ but is now DirectX. One of the big differences between the two is DirectX renders graphics through hardware acceleration, whereas the older GDI+ does not; simply put, DirectX is faster. Poor old WinForms still uses GDI+ under the hood.

Given all this, our WinForms team at DevExpress decided to do an experiment, or a spike in development-speak: could they take one of our more complicated WinForms controls—oh, let’s say that original control we wrote, the good old data grid – and change its rendering code to use DirectX and hardware acceleration instead of the “built-in” WinForms GDI+? Would anyone notice the purported speed improvements?

[…time passes, lots of work is done…]

Well? The result? Wow. To be blunt: this is going to revolutionize WinForms.

A big example: one of the most intensive rendering tasks we can do with the data grid is to scroll the rows in the grid pixel-by-pixel. On one of our hi-res test machines, with GDI+ we get about 22 frames per second. In other words, what’s happening in crude terms is for each frame the code is scrolling the data rows by a pixel and then adding another single row of pixels. Every second on the test machine, we can do that 22 times with GDI+. Just about flicker free. With DirectX? 72 FPS, over three times faster. That’s just butter smooth. Our competition, for the same task, is way behind (which also goes to show how well we’d optimized the grid up to now).

With a scroll by page example (where each frame is a new page), we used to get 25 FPS. With DirectX, 35 FPS.

But that’s not all. In essence, all of this work is done way down in the depths of the grid. The DirectX grid is totally compatible with the old GDI+ grid: all that needs to be done is to set a single option. So, you already have an app with our grid but want that extra rendering speed? Recompile with v17.2, set the option, and you’re away. Get on your users’ Christmas card lists again.

There are some limitations that you should be aware of with this new functionality. The biggest one is that it does not work under Windows versions that are older than 8, with Windows 7 being the biggest example. I’d have to say that, given that the end of extended support for Windows 7 is only 2 years away, is not that big of an issue. For these older operating system versions, if you set the DirectX hardware-acceleration option, it’s simply ignored and you automatically just get standard GDI+ speeds. (Ditto, if there’s some issue with DirectX rendering, there’s an auto-fallback to GDI+).

UPDATE 20-Nov-2017: Windows 7 is now supported!

Next, if you are doing any of your own drawing in the grid by using the window handle for example, it’ll be ignored, but then again it’s bad practice. If, however, you do have some custom draw handlers that use e.Graphics , you must now use the e.Cache.* methods instead. We plan to introduce some special tools and/or modes to catch potential problems with custom draw later.

In v17.2, the only control that will have this enhanced DirectX support will be the aforementioned data grid, XtraGrid. We have plans to upgrade our other major controls in future versions (v18.1, v18.2, and so on). Note that we have our ideas on the order to enhance them (tree list, pivot grid, and so on), but we’d love to hear from you what would be most important to you in your WinForms apps.

Published Nov 02 2017, 03:30 PM by
Bookmark and Share


Christopher Jay

Can you expand on "it will be really resource hungry"?  How bad?  Unusable by our clients who have lower-spec machines?

November 2, 2017 3:40 PM

Jacobo Amselem

Very exciting news!

Can you add an "automatic" option, so if the underlying OS is under win8 then fallback to GDI+?

November 2, 2017 4:17 PM

Julian Bucknall (DevExpress)

Christopher: It seems I was premature to talk about resources. Yes, DirectX uses more resources than GDI+, but we haven't measured the effect in the grid in any meaningful way (unlike the speed improvements I mentioned).

Cheers, Julian

November 2, 2017 5:59 PM

Julian Bucknall (DevExpress)

Jacobo: I didn't make that clear in the original text, but I have now. There is an automatic fallback to GDI+ should the machine the code is running on warrant it (eg, it's Windows 7).

Cheers, Julian

November 2, 2017 6:00 PM


Sounds great Julian.

November 2, 2017 6:38 PM

T. Thijs

Will this work in remote desktop sessions ?

November 3, 2017 2:56 AM

Christopher Jay

I nominate the GalleryControl for this feature  :)

November 3, 2017 7:55 AM

Mike Falcon (DevExpress)

T. Thijs:

Yes - it works way faster than GDI+ via remote desktop sessions

November 3, 2017 8:57 AM

Chris Royle (LOB)

"To be blunt: this is going to revolutionize WinForms." - throwing expectation management out the Windows.

The inevitable question, is this available within XAF Win applications by setting the appropriate option ?

November 3, 2017 9:05 AM

Julian Bucknall (DevExpress)

Chris: Well, yes. There's no "UseDirectXExceptForXAF" option. :) Again: currently it's only the grid, and only for Windows 8+, but apart from that, any WinForms app with a grid will benefit. It's "just" the rendering engine...

Cheers, Julian

November 3, 2017 11:27 AM

Richard Stevens

And now you've turned them loose to do the same thing on the VCL cxGrid, yes? Fab. Thank you!

November 3, 2017 12:12 PM

Julian Bucknall (DevExpress)

Richard: Now, now, now. Can't reveal everything in one go! :P

Cheers, Julian

November 3, 2017 12:35 PM

Heiko Mueller

WHAT GREAT NEWS... Since ages I ask myself why the hell Windows/GDI doesn't use all this powerfull graphic processors. With a DirectX-Version of DevExpress a dream will be come thrue... With all this possibilties of a modern display technology - like better transitions, effects like blur and so on.

November 4, 2017 11:47 AM

Randy Jean

This is great news!

November 4, 2017 7:54 PM

Stephen J White

Wow. When I saw this I was ecstatic! You guys have done a lot to keep Winforms viable and it just amazes me that you continue to put so much time and effort into it.

Here's hoping you get all the basic editors on Direct X in the near future!

November 6, 2017 11:15 PM

Stepan Lauryn

Hi Julian,

Do you plan migrate SpreadSheet control do DirectX? I used spreadsheat control for drawing my complex scheduling plain. And speed is critical for our Customer on large screen.



November 7, 2017 10:31 PM

Mike Falcon (DevExpress)


We're going to extend DirectX support to other controls

November 8, 2017 9:28 AM

Paul Singh 1

Julian i have a question on winforms 17.2 , it has Drag and Drop capability , correct?

i downloaded 17.2 and tried to create a grid with data , and was trying to see how to use Drag and Drop in this version , i could not find that option under behavior management , can you give an example of drag and drop on grid in 17.2 , this option is available in 17.2 beta , it says that on major add ons for this version.

Thanks , Paul

November 9, 2017 8:55 AM

Mike Falcon (DevExpress)


You can check Drag & Drop demo in XtraGrid demos.

In release version there will be slightly different appearance and behavior for drag drop.  

November 10, 2017 1:17 PM


XtraScheduler please, in timeline view I get long redraw rates if there are a lot of resources and appointments on screen.

November 14, 2017 11:04 AM

Paul Singh 1

Thanks Mike i will check this out , so Drag and Drop is available in XtraGrid for winforms , correct ?

November 16, 2017 12:43 PM

Bernd Niedergesaess

Definitly the XtraTreeList needs to follow next, as this is for sure as much used as the XtraGrid.

And then the XtraScheduler...

November 16, 2017 11:33 PM

Gabriel Araujo 1

I second the request for the XtraScheduler, that's a typical control that's used on big screens with loads of activities on it!

November 16, 2017 11:41 PM

Dmitry Babich (DevExpress)


Yes, you can find this functionality in our Demo Center: launch "WinForms Data Grid and Editors" demo and open the "Drag & Drop" module.

November 17, 2017 3:12 AM

Istvan Kardkovacs

What can I say. Wow! I've tried it and it was really fast. My candidate for the next control is the chart. On 4K screen a simple chart eats 30-40 Mb memory.

November 18, 2017 12:38 AM

Václav Jaroš

Faster DirectX rendering in XtraScheduler would be great pleasure for our customers!

November 20, 2017 4:30 AM


Are stand-alone editor controls support directx mode?

November 22, 2017 11:49 AM

Julian Bucknall (DevExpress)

@QUALCO SA: As stated, it's the grid only that supports DirectX. Also, the whole point about switching to DirectX is faster rendering, which is most beneficial for controls that occupy a big area of the screen. Small controls like standalone editors, not so much. That's not to say we won't make them support DirectX in the future, more that it makes sense to target "big" controls first: tree grid, vertical grid, scheduler, charting, what have you.

November 22, 2017 3:11 PM

David Shannon

"first: tree grid...

That's what I wanted to hear...

November 25, 2017 5:50 PM

Eaton Z.

Does this apply to the WinForms' grids carousel mode too? Was hoping to see some nice improvements there when clicking between items, but there is no discernible difference.

November 26, 2017 7:49 PM

Erhan Uzsay

Very nice feature. We are waiting this for VCL scheduler.

November 27, 2017 10:38 PM

Kervin Gomez M.

Julian, I've tested both GDI+ and DirectX WinForms Demos 17.2.4 and I can't see any difference with XtraGrid. Also opened source code from both and can't find the WindowsFormsSettings.ForceDirectXPaint method in the DirectX version. It's not called anywhere in the source code. Can you provide a sample project where we can see the difference?

December 14, 2017 5:32 AM

Dmitry Babich (DevExpress)


In previous releases, we made a lot of optimizations in our GridControl. That's why it has great performance on regular screens even with the regular GDI+ engine.

To see the difference, I'd recommend using a 4K display and expanding a form with GridControl to make it occupy the entire screen. The bigger area for rendering you have, the bigger difference there is in performance between GDI and DirectX. This way, you will notice the difference when scrolling, for example.

As for the ForceDirectXPaint method call, we introduced command line support in our demos and call this method implicitly. We just run the same demo with the /directx parameter to switch the rendering engine to DirectX.

If you still have questions regarding DirectX, feel free to contact our support team. We will provide you with required code snippets.

December 14, 2017 6:37 AM


Hi Julian,

That's very nice to hear! Glad you are still improving Winforms. We use Winforms extensively to display real-time data(financial market data, orders, trades, logs, etc.). It works and performs well for our needs. Simple and intuitive to program. This new feature will be a good option to try if we need to optimize rendering/scrolling performance in future.

One area where we face issues is custom group row summary calculation in XtraGrid when we use 5+ levels of grouping and 100+ columns, sorting and load layout operations become very slow, taking 5-15 seconds to complete. Also performance improvements for XtraTreeList control in terms of speed and memory usage when adding nodes and scrolling would be welcome.

But overall, want to take this opportunity to mention that DevExpress is a great toolkit for a Windows desktop applications developer. Thanks for all the work you do! It makes our lives much easier :) Thank you.

January 22, 2018 2:23 PM

Eugene Paradizov

Please get XtraScheduler control's rendering implemented as DirectX, especially the timeline (gantt) view, and add pixel scrolling while you're at it. Having no pixel scrolling and slow rendering are the two biggest flaws at this point.

February 10, 2018 9:15 AM

About Julian Bucknall (DevExpress)

Julian is the Chief Technology Officer at Developer Express. You can reach him directly at julianb@devexpress.com. You can also follow him on Twitter with the ID JMBucknall.

Chat is one of the many ways you can contact members of the DevExpress Team.
We are available Monday-Friday between 7:30am and 4:30pm Pacific Time.

If you need additional product information, write to us at info@devexpress.com or call us at +1 (818) 844-3383


DevExpress engineers feature-complete Presentation Controls, IDE Productivity Tools, Business Application Frameworks, and Reporting Systems for Visual Studio, Delphi, HTML5 or iOS & Android development. Whether using WPF, ASP.NET, WinForms, HTML5 or Windows 10, DevExpress tools help you build and deliver your best in the shortest time possible.

Copyright © 1998-2018 Developer Express Inc.
All trademarks or registered trademarks are property of their respective owners