Version

Features Overview (xamPropertyGrid)

Topic Overview

Purpose

This topic explains the features supported by the control from developer perspective.

In this topic

This topic contains the following sections:

Introduction

XamPropertyGrid summary

The xamPropertyGrid control provides the user with a friendly properties editing experience of a single object or multiple objects. The user has the ability to edit plain properties or complex list type properties.

Properties are edited using different editors depending of the property type. The user has the ability to browse quickly in large property lists using features like filtering, sorting or grouping.

The control provides a large number of customizations like changing the default property type editors, showing and hiding of filtering and description area, customizing the properties lists by including/excluding attached or read-only properties and many more.

The following screenshot shows the xamPropertyGrid while showing/editing a lot of object’s properties grouped by categories:

xamPropertyGrid 01.png

Main Features

Main features summary chart

The following table summarizes the main features of the xamPropertyGrid control. Additional details are available after the summary table.

Feature Description

The control supports binding to a single object or multiple objects.

Note
Note

When the control is bound to multiple objects only properties available in all objects will be presented in the properties list. If you need to exclude such merged property you need to add a MergebleProperty attribute. For more information please look at the List of Supported Attributes topic.

The control has a robust brush editor which lets the user to edit properties of type Brush including gradient brushes.

The control supports the definition of custom editors.

The control supports configuring of how bound and unbound dependency properties are shown.

The control has a description area used for displaying information regarding the currently selected property.

The control supports drill down into collections/lists using expandable properties.

The filtering feature allows the user to specify filter criteria for property names to enable efficient browsing of long property lists.

The grouping feature groups properties by category in an expandable/collapsible tree node.

The control uses replaceable property generators to discover the properties it should display for the currently selected object(s).

The control allows the user to reset the value of a property to its default value.

The sorting feature allows the user to sort the property list by property name.

Binding to object(s)

The control supports binding to a single or multiple objects. Binding to multiple objects allows the user to change a property value simultaneously on multiple objects.

Brush editor

In addition to built-ins editors for basic property types the xamPropertyGrid ships with a Visual Studio-like editor for manipulating properties of type Brush. It provides an UI for editing solid color brushes, gradient color brushes and a list of predefined brush resources.

Solid color editor:
xamPropertyGrid_03.png

Gradient color editor:
xamPropertyGrid_04.png

Predefined brush resources:
xamPropertyGrid_Brush_Resources.png

Custom editor definitions

Each property type has its own default editor (for example enumerations are edited by using a ComboBox) however you can create custom editors for specific property types, property names and/or property categories.

Dependency properties support

The control supports visualization of dependency objects' dependency properties which depends on the value of the PreventEditingOfBoundProperties property and of whether the dependency property has a local value or a binding expression.
The following table maps the dependency property displaying behavior of the controls depending on the configuration:

PreventEditingOfBoundProperties is false PreventEditingOfBoundProperties is true

Dependency property has a local value

The local value is displayed

The local value is displayed

Dependency property has a binding expression

The binding expression’s evaluated value is displayed

No value is displayed and the editor has an orange color border applied to it

Description area

The description area at the bottom of the control contains the following information about the currently selected property:

  • Property type

  • Property description

The description area can be shown or hidden.

Expandable properties

The control allows the user to drill down into more complex properties (like collections or lists) using a special expand/collapse glyph on the left of the property.

Filtering

The control allows the user to enter a filter value in the text box located in the filtering area at the top of the control. This filter is used as "contains" filter for displaying the property list, and the pipe symbol (i.e., "|") can be used to specify multiple filter criteria which are combined using an "Or" operator. In addition you can programmatically add custom filters (based on the "ICondition" interface) which are combined using an "and" operator with the value specified by the user.

Grouping

The control supports grouping of properties based on their categories - categories are assigned via the CategoryAttribute. The categories are expandable/collapsible. The properties in each category are sorted alphabetically.

Property generators

The control uses property generators to discover the properties to display for the currently selected object(s). The control ships with 2 built-in property generators - one uses reflection and the other uses TypeDescriptor to discover properties. You can also create your own custom property generators.

Reset property value

The control allows the user to reset a property to its default value using a glyph located at the right side of the property value.

Sorting

The sorting feature allows the user to sort all properties ascending regardless of their category. This forms an alphabetically sorted list containing all properties and no category groups are shown.

Topics

The following topics provide additional information related to this topic.

Topic Purpose

This topic provides an overview of the visual elements of the control.

This topic explains what actions can be performed by the user.

This topic lists the attributes which are used by the control when retrieving properties’ list from the objects.