TreeListOptionsView.BestFitMaxNodeCount Property
Gets or sets the number of data nodes whose content is processed to apply best fit to columns.
Namespace: DevExpress.XtraTreeList
Assembly: DevExpress.XtraTreeList.v24.1.dll
NuGet Packages: DevExpress.Win.Navigation, DevExpress.Win.TreeList
Declaration
[DefaultValue(-1)]
[XtraSerializableProperty]
public virtual int BestFitMaxNodeCount { get; set; }
Property Value
Type | Default | Description |
---|---|---|
Int32 | -1 | An integer value specifying the number of data nodes that are processed to apply best fit to columns. |
Property Paths
You can access this nested property as listed below:
Object Type | Path to BestFitMaxNodeCount |
---|---|
TreeList |
|
Remarks
When applying the best fit feature to a column, the column is resized so that it displays the complete contents of its header, footer cell and data cells. The number of data nodes taken into account for this calculation is specified by the BestFitMaxNodeCount property:
- If set to -1, all nodes are processed.
- If set to a positive integer, the TreeList processes the specified number of nodes starting from the top visible node.
- If set to 0 forces the TreeList to ignore data cell content when applying the best fit feature. In this case, columns are resized to fit the contents of their header and footer cells only.
Note
Setting the BestFitMaxNodeCount property to a non-default value automatically sets the TreeListOptionsView.BestFitNodes property to Custom. To use the All, Visible or Display mode, reset the BestFitMaxNodeCount property to its default value.
You can apply the best fit feature to columns using the TreeList.BestFitColumns or TreeListColumn.BestFit methods. End-users can also use the best fit feature via the column header context menu.