AdjustWidthOnlyVisible: Boolean;
AdjustWidthOnlyVisible: boolean;
The AdjustWidthOnlyVisible property determines the method of column width autofit.
Available values:
True. Autofit takes into account only width of the visible component elements. The width of elements available on scrolling is ignored.
False. Default value. Autofit takes into account width of all the elements.
To automatically adjust width, double click the border between the columns.
Executing the example requires a form containing:
The RdsDictionaryBox component with the RdsDictionaryBox1 identifier.
The UiRdsDictionary component that contains a loaded MDM dictionary used as a data source for RdsDictionaryBox1.
The CheckBox components with the ChB_Adjust, ChB_Header, and ChB_Highlight identifiers.
A button with the Button1 identifier.
The example is a handler of the OnClick event for the Button1 button.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Begin
RdsDictionaryBox1.AdjustWidthOnlyVisible := ChB_Adjust.Checked;
RdsDictionaryBox1.ShowHeaderButton := ChB_Header.Checked;
RdsDictionaryBox1.HighlightTrack := ChB_Highlight.Checked;
End Sub Button1OnClick;
After executing the example parameters of RdsDictionaryBox1 are set in accordance with checkboxes' states:
ChB_Adjust controls the IRdsDictionaryBox.AdjustWidthOnlyVisible property (method of column width autofit).
ChB_Header controls the IRdsDictionaryBox.ShowHeaderButton property (visibility of the button that opens column header menu).
ChB_Highlight controls the IRdsDictionaryBox.HighlightTrack property (highlighting elements on mouseover).
If the checkbox is selected, respective property is set to True, if the checkbox is not selected, the property is set to False.
Executing the example requires a .NET form that contains:
The RdsDictionaryBoxNet component with the rdsDictionaryBoxNet1 identifier.
The UiRdsDictionaryNet component that contains a loaded MDM dictionary used as a data source for rdsDictionaryBoxNet1.
The CheckBox components with the ChB_Adjust, ChB_Header, and ChB_Highlight identifiers.
A button with the button1 identifier.
The example is a handler of the Click event for the button1 button.
Private Sub button1_Click(sender: System.Object; e: System.EventArgs);
Begin
rdsDictionaryBoxNet1.CtrlBox.AdjustWidthOnlyVisible := ChB_Adjust.Checked;
rdsDictionaryBoxNet1.CtrlBox.ShowHeaderButton := ChB_Header.Checked;
rdsDictionaryBoxNet1.CtrlBox.HighlightTrack := ChB_Highlight.Checked;
End Sub;
After executing the example parameters of rdsDictionaryBoxNet1 are set in accordance with checkboxes' states. If the checkbox is selected, respective property is set to True, if the checkbox is not selected, the property is set to False. The checkboxes and controlled properties are described in the result of Fore Example execution.
See also: