From 7d900944555bf63bd08a9ba5721ca04c6bea59b6 Mon Sep 17 00:00:00 2001 From: Melissa Date: Fri, 13 Mar 2026 09:17:45 +0100 Subject: [PATCH] Made GetMaxSizeFromConstraint a protected method (#20877) --- src/Avalonia.Controls/TextBlock.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Avalonia.Controls/TextBlock.cs b/src/Avalonia.Controls/TextBlock.cs index c70d06ae7f..5c798f6a83 100644 --- a/src/Avalonia.Controls/TextBlock.cs +++ b/src/Avalonia.Controls/TextBlock.cs @@ -363,7 +363,10 @@ namespace Avalonia.Controls internal bool HasComplexContent => Inlines != null && Inlines.Count > 0; - private protected Size GetMaxSizeFromConstraint() + /// + /// Gets the maximum available size based on the constraint of the control + /// + protected Size GetMaxSizeFromConstraint() { var maxWidth = double.IsNaN(_constraint.Width) ? 0.0 : _constraint.Width; var maxHeight = double.IsNaN(_constraint.Height) ? 0.0 : _constraint.Height;