Skip to main content

TableViewColumn Class

Definition

Assembly:Avalonia.Controls
Package:Avalonia
public class TableViewColumn

Inheritance: object -> AvaloniaObject -> Animatable -> StyledElement -> TableViewColumn

Implements: IHeadered

Constructors

NameDescription
TableViewColumnNo summary available.

TableViewColumn Constructor

public TableViewColumn()

Methods

NameDescription
ApplyStylingApplies styling to the control if the control is initialized and styling is not already applied. Inherited from StyledElement.
BeginInitInherited from StyledElement.
EndInitInherited from StyledElement.
TryGetResourceInherited from StyledElement.
Bind (8 overloads)Binds a Avalonia.AvaloniaProperty to an Avalonia.Data.BindingBase. Inherited from AvaloniaObject.
CheckAccessReturns a value indicating whether the current thread is the UI thread. Inherited from AvaloniaObject.
ClearValue (4 overloads)Clears a Avalonia.AvaloniaProperty's local value. Inherited from AvaloniaObject.
CoerceValueCoerces the specified Avalonia.AvaloniaProperty. Inherited from AvaloniaObject.
EqualsCompares two objects using reference equality. Inherited from AvaloniaObject.
GetBaseValueInherited from AvaloniaObject.
GetHashCodeGets the hash code for the object. Inherited from AvaloniaObject.
GetValue (3 overloads)Gets a Avalonia.AvaloniaProperty value. Inherited from AvaloniaObject.
IsAnimatingChecks whether a Avalonia.AvaloniaProperty is animating. Inherited from AvaloniaObject.
IsSetChecks whether a Avalonia.AvaloniaProperty is set on this object. Inherited from AvaloniaObject.
SetCurrentValue (2 overloads)Sets the value of a dependency property without changing its value source. Inherited from AvaloniaObject.
SetValue (3 overloads)Sets a Avalonia.AvaloniaProperty value. Inherited from AvaloniaObject.
VerifyAccessChecks that the current thread is the UI thread and throws if not. Inherited from AvaloniaObject.

Properties

NameDescription
ActualWidthGets the actual width of the column, in device independent pixels. If the column hasn't yet been measured, returns double.NaN.
BindingGets or sets a binding that retrieves the cell value from the row data item. Use this for simple property display, e.g. Binding="{Binding Name}".
CanUserEffectivelyResizeGets whether the column can be effectively resized. The value of this property depends on both Avalonia.Controls.TableViewColumn.CanUserResize and Avalonia.Controls.TableView.CanUserResizeColumns.
CanUserResizeGets or sets whether the column can be resized. Set to null to use the value from Avalonia.Controls.TableView.CanUserResizeColumns. The default is null.
CellTemplateGets or sets the data template used to display cell content. When set, the whole row data item is passed as the template's data context.
CellThemeGets or sets the theme to apply to the cells. It must target Avalonia.Controls.TableViewCell.
HeaderGets or sets the column header content.
HeaderTemplateGets or sets the data template used to display the header.
HeaderThemeGets or sets the theme to apply to the header. It must target Avalonia.Controls.TableViewColumnHeader.
HorizontalContentAlignmentGets or sets the horizontal alignment of the content within a cell.
TableViewGets the Avalonia.Controls.TableViewColumn.TableView associated with this column.
WidthGets or sets the column width. Supports pixel, star (*) and auto sizing.
ActualThemeVariantGets the UI theme that is currently used by the element, which might be different than the RequestedThemeVariantProperty. Inherited from StyledElement.
ClassesGets or sets the styled element's classes. Inherited from StyledElement.
DataContextGets or sets the control's data context. Inherited from StyledElement.
IsInitializedGets a value that indicates whether the element has finished initialization. Inherited from StyledElement.
NameGets or sets the name of the styled element. Inherited from StyledElement.
ParentGets the styled element's logical parent. Inherited from StyledElement.
ResourcesGets or sets the styled element's resource dictionary. Inherited from StyledElement.
StyleKeyGets the type by which the element is styled. Inherited from StyledElement.
StylesGets the styles for the styled element. Inherited from StyledElement.
TemplatedParentGets the styled element whose lookless template this styled element is part of. Inherited from StyledElement.
ThemeGets or sets the theme to be applied to the element. Inherited from StyledElement.
TransitionsGets or sets the property transitions for the control. Inherited from Animatable.
DispatcherReturns the Avalonia.AvaloniaObject.Dispatcher that this Avalonia.AvaloniaObject is associated with. Inherited from AvaloniaObject.
ItemInherited from AvaloniaObject.

ActualWidth Property

Gets the actual width of the column, in device independent pixels. If the column hasn't yet been measured, returns double.NaN.

public double ActualWidth { get; set; }

Binding Property

Gets or sets a binding that retrieves the cell value from the row data item. Use this for simple property display, e.g. Binding="{Binding Name}".

public Avalonia.Data.BindingBase Binding { get; set; }

CanUserEffectivelyResize Property

Gets whether the column can be effectively resized. The value of this property depends on both Avalonia.Controls.TableViewColumn.CanUserResize and Avalonia.Controls.TableView.CanUserResizeColumns.

public bool CanUserEffectivelyResize { get; set; }

CanUserResize Property

Gets or sets whether the column can be resized. Set to null to use the value from Avalonia.Controls.TableView.CanUserResizeColumns. The default is null.

public Nullable<bool> CanUserResize { get; set; }

CellTemplate Property

Gets or sets the data template used to display cell content. When set, the whole row data item is passed as the template's data context.

public Avalonia.Controls.Templates.IDataTemplate CellTemplate { get; set; }

Remarks

This property takes priority over Avalonia.Controls.TableViewColumn.Binding.

CellTheme Property

Gets or sets the theme to apply to the cells. It must target Avalonia.Controls.TableViewCell.

public Avalonia.Styling.ControlTheme CellTheme { get; set; }

Header Property

Gets or sets the column header content.

public object Header { get; set; }

HeaderTemplate Property

Gets or sets the data template used to display the header.

public Avalonia.Controls.Templates.IDataTemplate HeaderTemplate { get; set; }

HeaderTheme Property

Gets or sets the theme to apply to the header. It must target Avalonia.Controls.TableViewColumnHeader.

public Avalonia.Styling.ControlTheme HeaderTheme { get; set; }

HorizontalContentAlignment Property

Gets or sets the horizontal alignment of the content within a cell.

public Avalonia.Layout.HorizontalAlignment HorizontalContentAlignment { get; set; }

TableView Property

Gets the Avalonia.Controls.TableViewColumn.TableView associated with this column.

public Avalonia.Controls.TableView TableView { get; set; }

Width Property

Gets or sets the column width. Supports pixel, star (*) and auto sizing.

public Avalonia.Controls.GridLength Width { get; set; }

Fields

NameDescription
ActualWidthPropertyDefines the Avalonia.Controls.TableViewColumn.ActualWidth property.
BindingPropertyDefines the Avalonia.Controls.TableViewColumn.Binding property.
CanUserEffectivelyResizePropertyDefines the Avalonia.Controls.TableViewColumn.CanUserEffectivelyResize property.
CanUserResizePropertyDefines the Avalonia.Controls.TableViewColumn.CanUserResize property.
CellTemplatePropertyDefines the Avalonia.Controls.TableViewColumn.CellTemplate property.
CellThemePropertyDefines the Avalonia.Controls.TableViewColumn.CellTheme property.
HeaderPropertyDefines the Avalonia.Controls.TableViewColumn.Header property.
HeaderTemplatePropertyDefines the Avalonia.Controls.TableViewColumn.HeaderTemplate property.
HeaderThemePropertyDefines the Avalonia.Controls.TableViewColumn.HeaderTheme property.
HorizontalContentAlignmentPropertyDefines the Avalonia.Controls.TableViewColumn.HorizontalContentAlignment property.
TableViewPropertyDefines the Avalonia.Controls.TableViewColumn.TableView property.
WidthPropertyDefines the Avalonia.Controls.TableViewColumn.Width property.
DataContextPropertyDefines the Avalonia.StyledElement.DataContext property. Inherited from StyledElement.
NamePropertyDefines the Avalonia.StyledElement.Name property. Inherited from StyledElement.
ParentPropertyDefines the Avalonia.StyledElement.Parent property. Inherited from StyledElement.
TemplatedParentPropertyDefines the Avalonia.StyledElement.TemplatedParent property. Inherited from StyledElement.
ThemePropertyDefines the Avalonia.StyledElement.Theme property. Inherited from StyledElement.
TransitionsPropertyDefines the Avalonia.Animation.Animatable.Transitions property. Inherited from Animatable.

ActualWidthProperty Field

Defines the Avalonia.Controls.TableViewColumn.ActualWidth property.

public Avalonia.DirectProperty<Avalonia.Controls.TableViewColumn, double> ActualWidthProperty

BindingProperty Field

Defines the Avalonia.Controls.TableViewColumn.Binding property.

public Avalonia.StyledProperty<Avalonia.Data.BindingBase> BindingProperty

CanUserEffectivelyResizeProperty Field

Defines the Avalonia.Controls.TableViewColumn.CanUserEffectivelyResize property.

public Avalonia.DirectProperty<Avalonia.Controls.TableViewColumn, bool> CanUserEffectivelyResizeProperty

CanUserResizeProperty Field

Defines the Avalonia.Controls.TableViewColumn.CanUserResize property.

public Avalonia.StyledProperty<Nullable<bool>> CanUserResizeProperty

CellTemplateProperty Field

Defines the Avalonia.Controls.TableViewColumn.CellTemplate property.

public Avalonia.StyledProperty<Avalonia.Controls.Templates.IDataTemplate> CellTemplateProperty

CellThemeProperty Field

Defines the Avalonia.Controls.TableViewColumn.CellTheme property.

public Avalonia.StyledProperty<Avalonia.Styling.ControlTheme> CellThemeProperty

HeaderProperty Field

Defines the Avalonia.Controls.TableViewColumn.Header property.

public Avalonia.StyledProperty<object> HeaderProperty

HeaderTemplateProperty Field

Defines the Avalonia.Controls.TableViewColumn.HeaderTemplate property.

public Avalonia.StyledProperty<Avalonia.Controls.Templates.IDataTemplate> HeaderTemplateProperty

HeaderThemeProperty Field

Defines the Avalonia.Controls.TableViewColumn.HeaderTheme property.

public Avalonia.StyledProperty<Avalonia.Styling.ControlTheme> HeaderThemeProperty

HorizontalContentAlignmentProperty Field

Defines the Avalonia.Controls.TableViewColumn.HorizontalContentAlignment property.

public Avalonia.StyledProperty<Avalonia.Layout.HorizontalAlignment> HorizontalContentAlignmentProperty

TableViewProperty Field

Defines the Avalonia.Controls.TableViewColumn.TableView property.

public Avalonia.DirectProperty<Avalonia.Controls.TableViewColumn, Avalonia.Controls.TableView> TableViewProperty

WidthProperty Field

Defines the Avalonia.Controls.TableViewColumn.Width property.

public Avalonia.StyledProperty<Avalonia.Controls.GridLength> WidthProperty

Events

NameDescription
ActualThemeVariantChangedRaised when the theme variant is changed on the element or an ancestor of the element. Inherited from StyledElement.
AttachedToLogicalTreeRaised when the styled element is attached to a rooted logical tree. Inherited from StyledElement.
DataContextChangedOccurs when the Avalonia.StyledElement.DataContext property changes. Inherited from StyledElement.
DetachedFromLogicalTreeRaised when the styled element is detached from a rooted logical tree. Inherited from StyledElement.
InitializedOccurs when the styled element has finished initialization. Inherited from StyledElement.
ResourcesChangedOccurs when a resource in this styled element or a parent styled element has changed. Inherited from StyledElement.
PropertyChangedRaised when a Avalonia.AvaloniaProperty value changes on this object. Inherited from AvaloniaObject.