Skip to main content
A newer version of this page is available. .

LayoutSerializationOptions.RestoreLayoutGroupAppearanceGroup Property

Gets or sets whether the appearance settings of groups are loaded when a layout is loaded from a data store.

Namespace: DevExpress.XtraLayout

Assembly: DevExpress.XtraLayout.v19.1.dll

Declaration

[DefaultValue(false)]
public virtual bool RestoreLayoutGroupAppearanceGroup { get; set; }

Property Value

Type Default Description
Boolean **false**

A Boolean value that specifies whether the corresponding appearance options are restored when a layout is restored.

Property Paths

You can access this nested property as listed below:

Object Type Path to RestoreLayoutGroupAppearanceGroup
DataLayoutControl
.OptionsSerialization.RestoreLayoutGroupAppearanceGroup
LayoutControl
.OptionsSerialization.RestoreLayoutGroupAppearanceGroup

Remarks

A layout can be saved to a data store via the LayoutControl.SaveLayoutToRegistry, LayoutControl.SaveLayoutToStream or LayoutControl.SaveLayoutToXml method, and then restored using a corresponding RestoreFrom… method.

When a layout is saved, the appearance settings of groups (LayoutItemContainer.AppearanceGroup) and items (BaseLayoutItem.AppearanceItemCaption) are saved as well. However, by default they are not restored when the layout is loaded. To ensure restoration of the appearance settings of layout groups, set the RestoreLayoutGroupAppearanceGroup property to true. To ensure restoration of the appearance settings of layout items, set the LayoutSerializationOptions.RestoreAppearanceItemCaption property to true.

Consider an example. Assume, a LayoutControl’s layout has been saved to an XML file. An end-user then customizes the appearance of specific layout items as required, via the Customization Form‘s Property Grid, and then intends to load the saved layout. If the LayoutSerializationOptions.RestoreAppearanceItemCaption property is set to false, changes to the items’ appearance will be kept. If this property is set to true, the new appearance will be overridden by the default appearance settings stored in the XML file.

See Also