HOME PAGE | DOWNLOAD | TUTORIALS | XtraReports
Devexpress

Saturday, July 14, 2012

XtraGrid - Customizing the Look & Feel

In this lesson, I’ll demonstrate how to customize the appearance of the XtraGrid Control. You will learn how to apply a pre-defined style scheme to a view, how to specify the view’s paint style, and how to modify the Grid’s overall look and feel.
1.       The Grid provides 44 pre-defined style schemes.
2.       To apply one of them, I run the designer for the grid and switch to the “Style Schemes” page.
3.       The Style Schemes are listed here.
4.       I select a style scheme, and the preview section displays a sample view with the selected scheme applied to it.
5.       I can also select the Paint Style.
6.       This specifies the manner in which Scroll Bars, Borders and Buttons are drawn for the view.
7.       So, I can experiment with different combinations and see how the appearance changes.
8.       For now, I’ll choose the “Pastel 1” scheme, and reset the Paint Style to Default.
9.       This means that the view’s appearance will now be controlled by the Grid Control.
10.   I apply the changes, and close the designer.
11.   Now, I’ll show you how to change the paint style at the grid level.
12.   I click the grid control link to access the grid settings.
13.   By default, all Developer Express controls read their “Look And Feel” settings from the centralized controller.
14.   To let the grid be in control of its own paint style, let’s disable the “Use Default Look And Feel” Option.
15.   Now, I can change the skin used to paint the grid control.
16.   You can see that all the changes are immediately reflected in the grid.
So, now you know the basics of customizing the XtraGrid Control’s appearance.

Enhanced by Zemanta

No comments:

Post a Comment