Summary

In this chapter we have looked at a couple of aspects of Windows Forms that you can use to write more sophisticated, responsive, or visually appealing applications.

In the first half of the chapter, we went under the hood to examine the message loop that underpins the event-based architecture of the System.Windows.Forms classes. We learned in particular how to integrate this architecture into multithreaded applications, demonstrating how to implement a dialog box that allows the user to abort a lengthy operation.

In the second half of the chapter, we examined three topics of relevance to the visual appearance of windows: customizing the shape of forms and controls, customizing the appearance of some controls by implementing them as owner-draw controls, and using GDI to leverage additional graphics features. On the one hand, we saw how implementing controls as owner-draw controls with non-rectangular regions can give you controls that look truly spectacular. On the other hand, we saw an example of one of the features that GDI can give you - Blitting from the screen - and we worked through an example that shows how you can very easily use this feature to programmatically take screenshots.

To some extent, what this chapter has presented could be seen as a quick flick through some of the tricks you can use to improve Windows Forms: it's not possible to be comprehensive in a single chapter. Nevertheless, the concepts presented here should give you some idea of the sort of things you can do to make sure that your Windows Forms-based applications are responsive, genuinely multitasked, and look significantly more professional and attractive than many of the applications on the market.



Advanced  .NET Programming
Advanced .NET Programming
ISBN: 1861006292
EAN: 2147483647
Year: 2002
Pages: 124

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net