5.20231.904
wijmo.grid.sheet Class HeaderRow Wijmo API Class

HeaderRow Class

Represents a row used to display column header information for a bound sheet.

Heirarchy

  • Row
    • HeaderRow

Constructors

constructor

Properties

align

align: string | null

Gets or sets the horizontal alignment of cells in the column or row.

The default value for this property is null, which causes the grid to select the alignment automatically based on the column's dataType (numbers are right-aligned, Boolean values are centered, and other types are left-aligned).

If you want to override the default alignment, set this property to 'left', 'right', 'center', or 'justify'.

allowDragging

allowDragging: boolean

Gets or sets a value that indicates whether the user can move the column or row to a new position with the mouse.

The default value for this property is true.

allowMerging

allowMerging: boolean

Gets or sets a value that indicates whether cells in the column or row can be merged.

The default value for this property is false.

allowResizing

allowResizing: boolean

Gets or sets a value that indicates whether the user can resize the column or row with the mouse.

The default value for this property is true.

binding

binding: string | null

Gets or sets the name of the property the column is bound to.

The default value for this property is null, which means the column is not bound to any data fields.

This property is set automatically for auto-generated columns (see FlexGrid.autoGenerateColumns).

collectionView

collectionView: ICollectionView

Gets the ICollectionView bound to this column or row.

cssClass

cssClass: string | null

Gets or sets a CSS class name to use when rendering data (non-header) cells in the column or row.

The default value for this property is null.

cssClassAll

cssClassAll: string | null

Gets or sets a CSS class name to use when rendering all cells (data and headers) in the column or row.

The default value for this property is null.

dataIndex

dataIndex: number

Gets the index of this row's data item within the current data view.

This may be different from the row's index property if there are group rows (which do not correspond to any data items) or in classes that bind multiple rows to individual data items.

dataItem

dataItem: any

Gets or sets the item in the data collection that the item is bound to.

The grid sets this property automatically when binding to data sources defined by the FlexGrid.itemsSource property.

The dataItem property of group header rows is automatically set to a wijmo.CollectionViewGroup object that contains information about the group.

dataMap

dataMap: DataMap | null

Gets or sets the DataMap used to convert raw values into display values for the column or row.

By default, data-mapped cells have drop-down lists that can be used for quick editing. You can change the type of editor by setting the column's dataMapEditor property.

The default value for this property is null.

dataMapEditor

dataMapEditor: DataMapEditor

Gets or sets a value that indicates the type of editor to use when editing data-mapped cells in this column or row.

The default value for this property is DataMapEditor.DropDownList, which adds drop-down buttons to cells to columns that have a dataMap and are not read-only.

Clicking on the drop-down buttons causes the grid to show a list where users can select the value for the cell.

The DataMapEditor.RadioButtons setting causes the grid to show radio buttons for each option. The buttons can be clicked with the mouse or keyboard (by pressing each option's initial letter or the space key to cycle through the options.)

Note that drop-down lists are available only if the wijmo.input.ListBox class is loaded/imported by the application.

dataType

dataType: DataType | null

Gets or sets the type of value stored in the column or row.

Values are coerced into the proper type when editing the grid.

The default value for this property is null, which causes the grid not to perform any data type coercion.

This property is set automatically for auto-generated columns (see FlexGrid.autoGenerateColumns).

dropDownCssClass

dropDownCssClass: string | null

Gets or sets a CSS class name to add to drop-downs in this column or row.

The drop-down buttons are shown only if the column has a dataMap set and is editable. Clicking on the drop-down buttons causes the grid to show a list where users can select the value for the cell.

Note that drop-down lists are available only if the wijmo.input.ListBox class is loaded/imported by the application.

The default value for this property is null.

format

format: string | null

Gets or sets the format string used to convert raw values into display values for the column or row (see Globalize).

The default value for this property is null, which causes the grid to use default formats that depend on the data type.

grid

grid: FlexGrid

Gets the FlexGrid that owns this column or row.

height

height: number | null

Gets or sets the height of the row.

You can use the renderHeight property to retrieve the actual height of the row, taking into account visibility, min/max limits, and default height settings.

The default value for this property is null, which causes the grid to use the default row height defined by the FlexGrid.rows collection.

index

index: number

Gets the index of the column or row in the parent collection.

inputType

inputType: string | null

Gets or sets the "type" attribute of the HTML input element used to edit values in this column or row.

The default value for this property is null, which causes the grid to use the type "tel" for numeric columns, and "text" for all other non-boolean column types.

The "tel" input type causes mobile devices to show a numeric keyboard that includes a negative sign and a decimal separator.

Use this property to change the default setting if the default does not work well for the current culture, device, or application. In these cases, try setting the property to "number" or simply "text."

isContentHtml

isContentHtml: boolean

Gets or sets a value that indicates whether cells in this column or row contain HTML content rather than plain text.

This property only applies to regular cells. Row and column header cells contain plain text by default. If you want to display HTML in column or row headers, you must use the FlexGrid.formatItem event and set the cell's innerHTML content in code.

Unless the column's isReadOnly property is set to true, cells that show HTML can be edited. By default, the editor will show HTML markup and users will be able to change it. If the column has a dataMap, however, the drop-down list will show formatted items and the editor will show plain text instead of HTML markup.

The default value for this property is false.

isReadOnly

isReadOnly: boolean

Gets or sets a value that indicates whether cells in the column or row can be edited.

The default value for this property is false.

isRequired

isRequired: boolean | null

Gets or sets a value that determines whether values in this column or row are required.

The default value for this property is to null, which means dates, booleans, and numeric values are required, but non-masked string columns may contain empty strings.

When set to true, values are required and empty strings are not allowed.

When set to false, null values and empty strings are allowed.

isSelected

isSelected: boolean

Gets or sets a value that indicates whether the column or row is selected.

The default value for this property is false.

isVisible

isVisible: boolean

Gets a value that indicates whether the column or row is visible and not collapsed.

This property is read-only. To change the visibility of a column or row, use the visible property instead.

mask

mask: string | null

Gets or sets a mask to use while editing values in this column or row.

The format used to define the mask is the same used by the wijmo.input.InputMask control.

If specified, the mask must be compatible with the value of the format property. For example, the mask '99/99/9999' can be used for entering dates formatted as 'MM/dd/yyyy'.

The default value for this property is null, which means any character is accepted at any position.

maxLength

maxLength: number | null

Gets or sets the maximum number of characters that the can be entered into cells in this column or row.

The default value for this property is null, which allows entries with any number of characters.

multiLine

multiLine: boolean

Gets or sets a value that indicates whether the content of cells in this column or row should wrap at new line characters (\n).

The default value for this property is false.

pos

pos: number

Gets the position of the column or row in pixels.

renderHeight

renderHeight: number

Gets the render height of the row.

The value returned takes into account the row's visibility, default size, and min and max sizes.

renderSize

renderSize: number

Gets the render size of the column or row.

This property accounts for visibility, default size, and min and max sizes.

size

size: number | null

Gets or sets the size of the column or row.

Setting this property to null or negative values causes the element to use the parent collection's default size.

sortMemberPath

sortMemberPath: string | null

Gets or sets the name of the property to use when sorting this column.

Use this property in cases where you want the sorting to be performed based on values other than the ones specified by the binding property.

The default value for this property is null, which causes the grid to use the value of the binding property to sort the column.

visible

visible: boolean

Gets or sets a value that indicates whether the column or row is visible.

The default value for this property is true.

visibleIndex

visibleIndex: number

Gets the index of the column or row in the parent collection ignoring invisible elements (isVisible).

wordWrap

wordWrap: boolean

Gets or sets a value that indicates whether the content of cells in this column or row should wrap to fit the available column width.

The default value for this property is false.

Methods

onGridChanged

onPropertyChanged

  • onPropertyChanged(): void

Events

gridChanged

gridChanged: Event<RowCol, EventArgs>

Occurs when the value of the grid property changes.