Method AddColumn
AddColumn(string?, float, Action?)
Adds a new column to the list control with the specified title, optional width, and optional click handler. This method adds a new column to Columns and also to the Header. Both the column in the collection and the header column are linked via the ColumnKey property.
public virtual ListControlColumn AddColumn(string? title, float width, Action? onClick = null)
Parameters
titlestringThe display title of the column. Can be null to indicate an unnamed column.
widthfloatThe suggested width of the column, or null to use the default width.
onClickActionAn optional action to invoke when the column header is clicked. If null, no click handler is assigned.
Returns
- ListControlColumn
A ListControlColumn instance representing the newly added column.
Remarks
The returned column is immediately added to the control and can be further customized after creation. If a width is specified, it is used as the column's suggested width. The click handler, if provided, is associated with the column header.