Class GridStackedHeaderRowDescriptor
Represents a class of GridStackedHeaderRowDescriptor which declares a stackedHeader row with one or multiple GridStackedHeaderDescriptor elements. GridStackedHeaderRowDescriptor descriptors are managed by the GridStackedHeaderRowDescriptorCollection which is returned by the StackedHeaderRows property of a GridTableDescriptor.
Inheritance
Implements
Inherited Members
Namespace: Syncfusion.Windows.Forms.Grid.Grouping
Assembly: Syncfusion.Grid.Grouping.Windows.dll
Syntax
public class GridStackedHeaderRowDescriptor : DescriptorBase, ICustomTypeDescriptor, IDisposable, ICloneable, IItemPropertiesSource, IGridTableCellAppearanceSource
Remarks
Each group in the GridTable has a GridStackedHeaderSection. The StackedHeader section has as many rows as there are GridStackedHeaderRowDescriptors. Each GridStackedHeaderRowDescriptor has a collection of GridStackedHeaderDescriptor columns. The GridStackedHeaderDescriptor defines the VisibleColumns or ColumnSets for which a combined header should be displayed before the normal column headers.
If you leave the VisibleColumns collection empty than this header will be used as default header for all columns that were not explicitly associated with another header.
So, if you want to just add an extra Caption then you could add a StackedHeaderRow with only one StackedHeader that has an empty VisibleColumns collection.
Constructors
GridStackedHeaderRowDescriptor()
Initializes a new instance of the GridStackedHeaderRowDescriptor class.
Declaration
public GridStackedHeaderRowDescriptor()
GridStackedHeaderRowDescriptor(String)
Initializes a new instance of the GridStackedHeaderRowDescriptor with a specified row name.
Declaration
public GridStackedHeaderRowDescriptor(string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The row name. |
GridStackedHeaderRowDescriptor(String, GridStackedHeaderDescriptor[])
Initializes a new instance of the GridStackedHeaderRowDescriptor class with a row name and a collection of GridStackedHeaderRowDescriptorCollection class.
Declaration
public GridStackedHeaderRowDescriptor(string name, GridStackedHeaderDescriptor[] headers)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The row name. |
GridStackedHeaderDescriptor[] | headers | A collection of GridStackedHeaderDescriptor |
Properties
Appearance
Gets or sets the default GridTableCellAppearance with default GridTableCellStyleInfo information for all cell elements that display data of this stackedHeader row.
Declaration
public GridTableCellAppearance Appearance { get; set; }
Property Value
Type |
---|
GridTableCellAppearance |
Collection
Gets the collection this descriptor belongs to.
Declaration
public GridStackedHeaderRowDescriptorCollection Collection { get; }
Property Value
Type |
---|
GridStackedHeaderRowDescriptorCollection |
Engine
Gets the GridEngine that this stackedHeader column descriptor belongs to.
Declaration
public GridEngine Engine { get; }
Property Value
Type |
---|
GridEngine |
Headers
Gets the collection of GridStackedHeaderDescriptor elements.
Declaration
public GridStackedHeaderDescriptorCollection Headers { get; }
Property Value
Type |
---|
GridStackedHeaderDescriptorCollection |
Name
Gets or sets the name of this descriptor. This name is used to look up the stackedHeader in the GridStackedHeaderRowDescriptorCollection.
Declaration
public virtual string Name { get; set; }
Property Value
Type |
---|
System.String |
TableDescriptor
Gets the TableDescriptor that this descriptor belongs to.
Declaration
public GridTableDescriptor TableDescriptor { get; }
Property Value
Type |
---|
GridTableDescriptor |
Methods
CalculateLayout()
Performs layout calculation.
Declaration
public void CalculateLayout()
Clone()
Creates a copy of this descriptor.
Declaration
public GridStackedHeaderRowDescriptor Clone()
Returns
Type | Description |
---|---|
GridStackedHeaderRowDescriptor | A copy of this descriptor. |
Dispose(Boolean)
Overrides and manages the unwanted resources.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing |
Overrides
EnsureLayout()
Ensures the layout.
Declaration
public void EnsureLayout()
Equals(Object)
Determines a value indicating whether the specified System.Object is equal to the current System.Object or not.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The System.Object to compare with the current System.Object. |
Returns
Type | Description |
---|---|
System.Boolean | True if the specified System.Object is equal to the current System.Object; Otherwise False. |
Overrides
FindHeaderByVisibleColumn(String)
Gets the stacked header for a given column.
Declaration
public GridStackedHeaderDescriptor FindHeaderByVisibleColumn(string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | Name of the visible column. |
Returns
Type | Description |
---|---|
GridStackedHeaderDescriptor | Stacked header. |
GetHashCode()
Gets a hash function for a particular type.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | A hash code for the current object. |
Overrides
GetName()
Overrides and gets the name of the descriptor.
Declaration
public override string GetName()
Returns
Type | Description |
---|---|
System.String | Descriptor name. |
Overrides
InitializeFrom(GridStackedHeaderRowDescriptor)
Initializes this object and copies properties from another object. PropertyChanging and PropertyChanged events are raised for every property that is modified. If both objects are equal, no events are raised.
Declaration
public void InitializeFrom(GridStackedHeaderRowDescriptor other)
Parameters
Type | Name | Description |
---|---|---|
GridStackedHeaderRowDescriptor | other | The source object. |
OnPropertyChanged(DescriptorPropertyChangedEventArgs)
Triggered when the PropertyChanged event is done.
Declaration
protected virtual void OnPropertyChanged(DescriptorPropertyChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
DescriptorPropertyChangedEventArgs | e | A DescriptorPropertyChangedEventArgs contains the event data. |
OnPropertyChanging(DescriptorPropertyChangedEventArgs)
Triggered when the PropertyChanging event is done.
Declaration
protected virtual void OnPropertyChanging(DescriptorPropertyChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
DescriptorPropertyChangedEventArgs | e | A DescriptorPropertyChangedEventArgs contains the event data. |
ResetAppearance()
Discards any changes for the Appearance object.
Declaration
public void ResetAppearance()
ShouldSerializeAppearance()
Determines a value indicating whether Appearance has been modified and contents should be serialized at design-time or not.
Declaration
public bool ShouldSerializeAppearance()
Returns
Type | Description |
---|---|
System.Boolean | True if contents were changed; False otherwise. |
ToString()
Overrides and gets the string representation the current object.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | String representation of the current object. |
Overrides
Events
PropertyChanged
Occurs when a property is changed.
Declaration
public event DescriptorPropertyChangedEventHandler PropertyChanged
Event Type
Type |
---|
DescriptorPropertyChangedEventHandler |
PropertyChanging
Occurs before a property is changed.
Declaration
public event DescriptorPropertyChangedEventHandler PropertyChanging
Event Type
Type |
---|
DescriptorPropertyChangedEventHandler |
Explicit Interface Implementations
IItemPropertiesSource.GetItemProperties()
Declaration
PropertyDescriptorCollection IItemPropertiesSource.GetItemProperties()
Returns
Type |
---|
System.ComponentModel.PropertyDescriptorCollection |
IGridTableCellAppearanceSource.GetAppearance()
Gets the appearance of the current object.
Declaration
GridTableCellAppearance IGridTableCellAppearanceSource.GetAppearance()
Returns
Type |
---|
GridTableCellAppearance |
IGridTableCellAppearanceSource.GetBaseAppearance()
Gets the base appearance of the current object.
Declaration
GridTableCellAppearance IGridTableCellAppearanceSource.GetBaseAppearance()
Returns
Type |
---|
GridTableCellAppearance |
IGridTableCellAppearanceSource.RaiseAppearanceChanged(GridTableCellStyleInfoChangedEventArgs)
Declaration
void IGridTableCellAppearanceSource.RaiseAppearanceChanged(GridTableCellStyleInfoChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
GridTableCellStyleInfoChangedEventArgs | e |
IGridTableCellAppearanceSource.RaiseAppearanceChanging(GridTableCellStyleInfoChangedEventArgs)
Declaration
void IGridTableCellAppearanceSource.RaiseAppearanceChanging(GridTableCellStyleInfoChangedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
GridTableCellStyleInfoChangedEventArgs | e |
ICloneable.Clone()
Declaration
object ICloneable.Clone()
Returns
Type |
---|
System.Object |