Drawing Custom List Elements

Custom element drawing is another way in which you can give an ordinary, plain-looking Windows Forms application a little extra flare to make it stand out from its competitors. The concept involves overriding the way that certain controls draw their items and replacing that logic with your own code. This enables you to create list boxes that have decorated appearances and much more. The next section will show you the technology behind creating these custom elements and present a few sample custom elements created from a ListBox and a MenuItem.

Get Microsoft® Visual C#® .NET 2003 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.