Share via


IViewHandler.GetDesiredSize(Double, Double) 方法

定义

根据所需大小和约束计算视图的实际大小。

public:
 Microsoft::Maui::Graphics::Size GetDesiredSize(double widthConstraint, double heightConstraint);
public Microsoft.Maui.Graphics.Size GetDesiredSize (double widthConstraint, double heightConstraint);
abstract member GetDesiredSize : double * double -> Microsoft.Maui.Graphics.Size
Public Function GetDesiredSize (widthConstraint As Double, heightConstraint As Double) As Size

参数

widthConstraint
Double

视图宽度的约束。

heightConstraint
Double

视图高度的约束。

返回

与此处理程序关联的视图的计算大小。

适用于