Improving UI responsiveness of a Marquee through threading
Posted on 2010-04-05
I am looking to improve the responsiveness of a UI control in a .NET project. It is a scrolling Marquee that displays RSS feeds. I am using the NetMarquee control from an online source. It provides a simple control to allow scrolling text. However, the issue is that when I perform other tasks on the UI it causes the Marquee to stutter. This is particularly true when I load images onto the UI. I am working to reduce the workload of the image load, but that isn't really the issue. It is just the indicator of the issue. The issue is that the Marquee is affected by the load on the UI. I want to isolate the Marquee if possible.
What I would like to do is operate the Marquee entirely on its own thread. It is a self-contained component that would not need to contact the other UI components in any way. The reverse is true as well. So far I have found ways to marshal calls to and from worker threads, but this does not help me. The issue is that the control itself is getting bogged down.
Is there a way to isolate one control? I can create it at runtime, but I have heard that you cannot create a control with a parent on a different thread. Is there a way to get around this?
As far as .NET languages go, I can do this in VB.NET or C#, so examples in either would be helpful. I would welcome any suggestions about how to make this control operate better. I am using Visual Studio 2008 to create these forms. If Visual Studio 2010 would bring new features that I could leverage, I would move ahead to that platform to accomplish this task.