ExPropertyGrid
ExPropertyGrid is a PropertyGrid that can show or hide properties and categories without changing the selected
object, and gives access to the buttons of its tool strip.
Filtering properties
| Property | Description |
|---|---|
BrowsableAttributes |
Shows only the properties with these attributes, for example categories. |
HiddenAttributes |
Hides the properties with these attributes. |
BrowsableProperties |
Names of the properties to show. |
HiddenProperties |
Names of the properties to hide. |
FirstHideAllProperties |
Starts with no properties, so only the browsable attributes and properties are shown. |
grid.HiddenProperties = ["Tag", "Name"];
grid.HiddenAttributes = new AttributeCollection(new CategoryAttribute("Data"));
grid.SelectedObject = button;
SelectedObject passes a wrapper of the object to the base PropertyGrid, which applies the filters. The getter still
returns the original object.
Tool strip
InnerToolStrip is the tool strip of the grid, ButtonCategorized, ButtonAlphabetical, ButtonPropertyPages and
Separator its items. A theme handler can give the tool strip its own renderer through InnerToolStrip. The images of
the buttons are available in SortByCategoryImage, SortByPropertyImage and ShowPropertyPageImage.
ExPropertyGrid implements ISearchable: Search(text) shows only the properties whose names contain the text, an
empty text shows all of them again. The search box of ExOptionsView uses it on grids in its pages.
Theme
| Theme color | Used for |
|---|---|
PanelBackColor, PanelForeColor |
Grid background, help and commands. |
BoxBackColor, BoxForeColor |
Properties and category names. |
ButtonBackColor |
Lines and category rows. |
BorderColor |
Borders of the view and the help. |
HighlightBackColor, HighlightForeColor |
Selected property. |
DarkScrollBars |
Scroll bar of the properties. |
The tool strip of the grid gets the theme from the handler the application registered for ToolStrip, so it looks like
the other tool strips of the application. Without such a handler the custom style colors it by the theme.


