Chapter 6. Rendering, layout, and transforming
This chapter covers
- UI elements and framework elements
- The layout system
- The rendering pipeline
- Using 2D and 3D transformations
Over the past few chapters, we covered some fairly big-picture topics, such as how to have Silverlight work in and out of the browser and how to use XAML. Those are all important to understand in order to create Silverlight applications that work in or out of the browser. XAML and the property system are also important, and we build upon that knowledge in every subsequent chapter, including this one.
In this chapter, we’re going to dig back down under the covers and look at some fundamentals of the core user interface base classes and the rendering and layout systems that make everything fit on the screen and render to the user.
Silverlight’s rendering process involves a number of steps, and has provisions for several developer-provided optimizations to the process. Silverlight also has a far more advanced layout system than simple left/top positioning of elements on the screen. The multipass layout system handles measuring and arranging elements across the entire visual tree.
Once the rendering, layout, and core object fundamentals are down, we’ll have some fun with performing 2D transformations on our objects. If you’ve ever wanted to rotate or scale an object on the screen, you’ll find the section on render transformations to your liking.