Label.AutoEllipsis Label.AutoEllipsis Label.AutoEllipsis Label.AutoEllipsis Property

定義

取得或設定值,指出省略字元 (...) 是否會顯示在 Label 的右邊緣,表示 Label 文字超過 Label 的指定長度。Gets or sets a value indicating whether the ellipsis character (...) appears at the right edge of the Label, denoting that the Label text extends beyond the specified length of the Label.

public:
 property bool AutoEllipsis { bool get(); void set(bool value); };
[System.ComponentModel.Browsable(true)]
public bool AutoEllipsis { get; set; }
member this.AutoEllipsis : bool with get, set
Public Property AutoEllipsis As Boolean

屬性值

如果要以省略符號表示還有其他標籤文字,則為 true,否則為 falsetrue if the additional label text is to be indicated by an ellipsis; otherwise, false. 預設為 falseThe default is false.

備註

當使用者true使用滑鼠傳遞控制項時,將設定AutoEllipsis為以顯示超出寬度的文字。 LabelSet AutoEllipsis to true to display text that extends beyond the width of the Label when the user passes over the control with the mouse. 如果AutoSizetrue,則標籤會擴大以符合文字,而且不會出現省略號。If AutoSize is true, the label will grow to fit the text and an ellipsis will not appear.

重要

如果Label字型高於的高度,且AutoEllipsistrue,則您必須將設AutoSizefalse ,才能繪製文字。If the font is taller than the height of the Label and AutoEllipsis is true, you must set AutoSize to false for text to be drawn.

適用於

另請參閱