TextBlock.MaxLines Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
public:
property int MaxLines { int get(); void set(int value); };
int MaxLines();
void MaxLines(int value);
public int MaxLines { get; set; }
var int32 = textBlock.maxLines;
textBlock.maxLines = int32;
Public Property MaxLines As Integer
<TextBlock MaxLines="int"/>
Property Value
int
The maximum number of lines of text shown in the TextBlock. The default is 0, which is a special value that represents "Auto" behavior. The value cannot be negative.
Remarks
Use the MaxLines property to specify the maximum number of lines of text shown in a text block. The text control will adjust its height to show no more than the specified number of lines, regardless of the font size, font style, or text length.
Negative integer values are invalid, and will cause a run-time exception.
Applies to
Geri Bildirim
https://aka.ms/ContentUserFeedback.
Çok yakında: 2024 boyunca, içerik için geri bildirim mekanizması olarak GitHub Sorunları’nı kullanımdan kaldıracak ve yeni bir geri bildirim sistemiyle değiştireceğiz. Daha fazla bilgi için bkz.Gönderin ve geri bildirimi görüntüleyin