Class
ColumnDefinition

This class represents a GanttView column definition. A collection of ColumnDefinitions is used for describing the tree-list part of the GanttView control.

Definition

Namespace:Telerik.Windows.Controls.GanttView

Assembly:Telerik.Windows.Controls.GanttView.dll

Syntax:

cs-api-definition
public class ColumnDefinition : ColumnDefinitionBase, INotifyPropertyChanged, IHierarchical

Inheritance: objectPlatformIndependentFreezableColumnDefinitionBaseColumnDefinition

Derived Classes: TreeColumnDefinition

Implements: IHierarchicalINotifyPropertyChanged

Inherited Members ColumnDefinitionBase.HeaderPropertyColumnDefinitionBase.IsFrozenColumnPropertyColumnDefinitionBase.ColumnWidthPropertyColumnDefinitionBase.WidthPropertyColumnDefinitionBase.GetSubItems()ColumnDefinitionBase.OnPropertyChanged(PropertyChangedEventArgs)ColumnDefinitionBase.OnPropertyChanged(string)ColumnDefinitionBase.OnPropertyChanged<T>(Expression<Func<T>>)ColumnDefinitionBase.HeaderColumnDefinitionBase.ColumnWidthColumnDefinitionBase.WidthColumnDefinitionBase.IsFrozenColumnColumnDefinitionBase.PropertyChangedPlatformIndependentFreezable.CreateInstanceCore()

Constructors

ColumnDefinition()

Declaration

cs-api-definition
public ColumnDefinition()

Fields

CellEditTemplateProperty

Identifies the CellEditTemplate dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty CellEditTemplateProperty

Field Value

DependencyProperty

CellHighlightTemplateProperty

Identifies the CellHighlightTemplate dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty CellHighlightTemplateProperty

Field Value

DependencyProperty

CellSelectionTemplateProperty

Identifies the CellSelectionTemplate dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty CellSelectionTemplateProperty

Field Value

DependencyProperty

CellTemplateProperty

Identifies the CellTemplate dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty CellTemplateProperty

Field Value

DependencyProperty

IsResizableProperty

Identifies the IsResizable dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty IsResizableProperty

Field Value

DependencyProperty

MaxWidthProperty

Identifies the MaxWidth dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty MaxWidthProperty

Field Value

DependencyProperty

MinWidthProperty

Identifies the MinWidth dependency property.

Declaration

cs-api-definition
public static readonly DependencyProperty MinWidthProperty

Field Value

DependencyProperty

Properties

CellEditTemplate

Gets or sets the template of the cells in this column when in Edit mode. If this template is not set, editing is not allowed in the corresponding column. This is a dependency property.

Declaration

cs-api-definition
public DataTemplate CellEditTemplate { get; set; }

Property Value

DataTemplate

Remarks

The DataContext of this template is the event in the given row.

CellHighlightTemplate

Gets or sets the template of the cells in this column when the mouse is over the cell. If this property is not set, the value of the CellTemplate is used. This is a dependency property.

Declaration

cs-api-definition
public DataTemplate CellHighlightTemplate { get; set; }

Property Value

DataTemplate

Remarks

Please notice that the DataContext of this template is not actually the event in the given row, but a Proxy object containing the following properties: Start, End, Title, FormattedValue, OriginalEvent. The OriginalEvent is the event in the row and the FormattedValue is the value extracted through the MemberBinding.

CellSelectionTemplate

Gets or sets the template of the cells in this column when the mouse is over the cell. If this property is not set, the value of the CellTemplate is used.

Declaration

cs-api-definition
public DataTemplate CellSelectionTemplate { get; set; }

Property Value

DataTemplate

Remarks

Please notice that the DataContext of this template is not actually the event in the given row, but a Proxy object containing the following properties: Start, End, Title, FormattedValue, OriginalEvent. The OriginalEvent is the event in the row and the FormattedValue is the value extracted through the MemberBinding.

CellTemplate

Gets or sets the template of the cells in this column when in normal state. If the CellHighlightTemplate or CellSelectionTemplate are not set, the selected or highlighted cells also use this template. This is a dependency property.

Declaration

cs-api-definition
public DataTemplate CellTemplate { get; set; }

Property Value

DataTemplate

Remarks

When this template is set the GanttView's rendering is slower than using directly the MemberBinding property, so consider carefully if you need to use this property or not. Please notice that the DataContext of this template is not actually the event in the given row, but a Proxy object containing the following properties: Start, End, Title, FormattedValue, OriginalEvent. The OriginalEvent is the event in the row and the FormattedValue is the value extracted through the MemberBinding. Use FormattedValue for best performance.

IsResizable

Gets or sets a value indicating whether the column can be resized through the column resizer or not.

Declaration

cs-api-definition
public bool IsResizable { get; set; }

Property Value

bool

MaxWidth

Gets or sets the maximum width of the column. The value of this property doesn't restrict the ColumnWidth property.

Declaration

cs-api-definition
public double MaxWidth { get; set; }

Property Value

double

MemberBinding

Gets or sets the binding to be used to evaluate the Cell content.

Declaration

cs-api-definition
public Binding MemberBinding { get; set; }

Property Value

Binding

MinWidth

Gets or sets the minimum width of the column. The value of this property doesn't restrict the ColumnWidth property.

Declaration

cs-api-definition
public double MinWidth { get; set; }

Property Value

double

Methods

CreateInstanceOverride()

When implemented in a derived class, creates a new instance of the Telerik.Windows.Core.PlatformIndependentFreezable derived class.

Declaration

cs-api-definition
protected override PlatformIndependentFreezable CreateInstanceOverride()

Returns

PlatformIndependentFreezable

The new instance.

Overrides PlatformIndependentFreezable.CreateInstanceOverride()

GetDataContextForItemOverride(object)

When overridden in the derived class this method determines which is the actual data item for the row for a given item from the list (in most cases an HierarchicalItem).

Declaration

cs-api-definition
protected virtual object GetDataContextForItemOverride(object itemData)

Parameters

itemData

object

The original item from the source collection. In most cases this is an HierarchicalItem.

Returns

object

The item to be used as a data item for the cell, generated for this column for the given data item. The default implementation just extracts the SourceItem from the HierarchicalItem.