34 instantiations of SizeRequest
Microsoft.Maui (1)
Primitives\SizeRequest.cs (1)
43 public static implicit operator SizeRequest(Size size) => new SizeRequest(size);
Microsoft.Maui.Controls (27)
BoxView\BoxView.cs (1)
49 return new SizeRequest(new Size(40, 40));
Compatibility\Handlers\iOS\ViewRenderer.cs (1)
58 new SizeRequest(this.GetDesiredSizeFromHandler(widthConstraint, heightConstraint),
Compatibility\Handlers\VisualElementRenderer.cs (1)
166 return new SizeRequest(size, minSize);
Compatibility\iOS\Extensions\UIViewExtensions.cs (1)
51 return new SizeRequest(request, minimum);
ContentPresenter.cs (2)
56 var childRequest = new SizeRequest(); 62 return new SizeRequest
ImageElement.cs (2)
55 return new SizeRequest(new Size(0, 0)); 98 return new SizeRequest(new Size(width, height));
Items\ItemsView.cs (1)
204 return new SizeRequest(request, minimumSize);
LegacyLayouts\AbsoluteLayout.cs (2)
109 return new SizeRequest(bestFitSize, minimum); 227 return new SizeRequest(new Size(width, height), new Size(minWidth, minHeight));
LegacyLayouts\FlexLayout.cs (3)
440 return new SizeRequest(new Size(widthConstraint, heightConstraint)); 444 return new SizeRequest(new Size(widthConstraint, heightConstraint)); 483 return new SizeRequest(new Size(widthConstraint, heightConstraint));
LegacyLayouts\GridCalc.cs (2)
57 return new SizeRequest(new Size(0, 0)); 84 var result = new SizeRequest(request, minimum);
LegacyLayouts\Layout.cs (1)
205 return new SizeRequest(new Size(size.Request.Width + Padding.HorizontalThickness, size.Request.Height + Padding.VerticalThickness),
LegacyLayouts\RelativeLayout.cs (1)
238 return new SizeRequest(new Size(boundsRectangle.Right, boundsRectangle.Bottom));
LegacyLayouts\StackLayout.cs (2)
85 return new SizeRequest(); 91 var result = new SizeRequest(_layoutInformation.Bounds.Size, _layoutInformation.MinimumSize);
ListView\ListView.cs (1)
442 return new SizeRequest(request, minimumSize);
ScrollView\ScrollView.cs (1)
286 return new SizeRequest();
TableView\TableView.cs (1)
142 return new SizeRequest(request, minimumSize);
TemplatedView\TemplatedView.cs (2)
51 var childRequest = new SizeRequest(); 58 return new SizeRequest
VisualElement\VisualElement.cs (2)
1166 var r = new SizeRequest(request, minimum); 1312 return new SizeRequest(new Size(-1, -1));
Microsoft.Maui.Controls.Compatibility (6)
iOS\HandlerToRendererShim.cs (1)
75 return new SizeRequest(size, size);
iOS\Platform.cs (2)
228 return new SizeRequest(iView.Handler.GetDesiredSize(widthConstraint, heightConstraint)); 232 return new SizeRequest(Size.Zero);
iOS\Renderers\CheckBoxRendererBase.cs (1)
81 sizeConstraint = new SizeRequest(new Size(width, height), new Size(MinimumSize, MinimumSize));
iOS\Renderers\EntryRenderer.cs (1)
72 return new SizeRequest(new Size(baseResult.Request.Width, height));
iOS\Shapes\ShapeRenderer.cs (1)
304 return new SizeRequest(new Size(
121 references to SizeRequest
Microsoft.Maui (11)
Primitives\SizeRequest.cs (11)
13 public struct SizeRequest : IEquatable<SizeRequest> 41 public bool Equals(SizeRequest other) => Request.Equals(other.Request) && Minimum.Equals(other.Minimum); 43 public static implicit operator SizeRequest(Size size) => new SizeRequest(size); 45 public static implicit operator Size(SizeRequest size) => size.Request; 47 public override bool Equals(object? obj) => obj is SizeRequest other && Equals(other); 51 public static bool operator ==(SizeRequest left, SizeRequest right) => left.Equals(right); 53 public static bool operator !=(SizeRequest left, SizeRequest right) => !(left == right); 62 Size size => (SizeRequest)size, 70 if (value is SizeRequest sizeRequest)
Microsoft.Maui.Controls (63)
BoxView\BoxView.cs (1)
47 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
Compatibility\Handlers\iOS\ViewRenderer.cs (1)
55 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
Compatibility\Handlers\NavigationPage\iOS\NavigationRenderer.cs (1)
80 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
Compatibility\Handlers\VisualElementRenderer.cs (2)
146 var sizeRequest = GetDesiredSize(widthConstraint, heightConstraint); 162 public virtual SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
Compatibility\iOS\Extensions\UIViewExtensions.cs (1)
43 public static SizeRequest GetSizeRequest(this UIView self, double widthConstraint, double heightConstraint,
ContentPresenter.cs (2)
52 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 56 var childRequest = new SizeRequest();
Image\Image.cs (2)
78 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 80 SizeRequest desiredSize = base.OnMeasure(double.PositiveInfinity, double.PositiveInfinity);
ImageButton\ImageButton.cs (2)
150 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 154 SizeRequest desiredSize = base.OnMeasure(double.PositiveInfinity, double.PositiveInfinity);
ImageElement.cs (2)
46 public static SizeRequest Measure(IImageElement ImageElementManager, SizeRequest desiredSize, double widthConstraint, double heightConstraint)
IndicatorView\IndicatorView.cs (1)
134 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
IPlatformSizeService.cs (1)
8 SizeRequest GetPlatformSize(VisualElement view, double widthConstraint, double heightConstraint);
Items\ItemsView.cs (1)
193 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
LegacyLayouts\AbsoluteLayout.cs (5)
95 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 101 SizeRequest desiredSize = ComputeBoundingRegionDesiredSize(child); 161 static SizeRequest ComputeBoundingRegionDesiredSize(View view) 166 var sizeRequest = new Lazy<SizeRequest>(() => view.Measure(double.PositiveInfinity, double.PositiveInfinity, MeasureFlags.IncludeMargins)); 234 SizeRequest sizeRequest;
LegacyLayouts\FlexLayout.cs (1)
436 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
LegacyLayouts\GridCalc.cs (8)
53 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 84 var result = new SizeRequest(request, minimum); 200 SizeRequest sizeRequest = child.Measure(widthRequest, heightRequest, MeasureFlags.IncludeMargins); 233 SizeRequest sizeRequest = child.Measure(widthRequest, heightRequest, MeasureFlags.IncludeMargins); 544 SizeRequest sizeRequest = child.Measure(w, GetAssignedRowHeight(child), MeasureFlags.IncludeMargins); 573 SizeRequest sizeRequest = child.Measure(acw, h, MeasureFlags.IncludeMargins); 675 SizeRequest sizeRequest = child.Measure(widthConstraint, hConstraint, MeasureFlags.IncludeMargins); 736 SizeRequest sizeRequest = child.Measure(wConstraint, heightConstraint, MeasureFlags.IncludeMargins);
LegacyLayouts\Layout.cs (7)
198 public override SizeRequest Measure(double widthConstraint, double heightConstraint, MeasureFlags flags = MeasureFlags.None) 202 SizeRequest size = base.Measure(widthConstraint - Padding.HorizontalThickness, heightConstraint - Padding.VerticalThickness, flags); 247 SizeRequest request = child.Measure(region.Width, region.Height, MeasureFlags.IncludeMargins); 264 SizeRequest request = child.Measure(region.Width, region.Height, MeasureFlags.IncludeMargins); 487 internal static void LayoutChildIntoBoundingRegion(View child, Rect region, SizeRequest childSizeRequest) 511 SizeRequest request = canUseAlreadyDoneRequest ? childSizeRequest : child.Measure(region.Width, region.Height, MeasureFlags.IncludeMargins); 528 SizeRequest request = canUseAlreadyDoneRequest ? childSizeRequest : child.Measure(region.Width, region.Height, MeasureFlags.IncludeMargins);
LegacyLayouts\RelativeLayout.cs (1)
204 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
LegacyLayouts\StackLayout.cs (8)
80 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 91 var result = new SizeRequest(_layoutInformation.Bounds.Size, _layoutInformation.MinimumSize); 129 layout.Requests = new SizeRequest[Children.Count]; 173 SizeRequest request = child.Measure(widthConstraint, double.PositiveInfinity, MeasureFlags.IncludeMargins); 208 SizeRequest request = child.Measure(double.PositiveInfinity, heightConstraint, MeasureFlags.IncludeMargins); 265 SizeRequest newRequest = child.Measure(newWidth, heightConstraint, MeasureFlags.IncludeMargins); 337 SizeRequest newRequest = child.Measure(widthConstraint, newHeight, MeasureFlags.IncludeMargins); 481 public SizeRequest[] Requests;
ListView\ListView.cs (1)
422 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
RadioButton\RadioButton.cs (1)
293 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
ScrollView\ScrollView.cs (2)
283 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 306 SizeRequest contentRequest;
TableView\TableView.cs (1)
135 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
TemplatedView\TemplatedView.cs (2)
47 protected override SizeRequest OnMeasure(double widthConstraint, double heightConstraint) 51 var childRequest = new SizeRequest();
VisualElement\VisualElement.cs (9)
496 readonly Dictionary<Size, SizeRequest> _measureCache = new Dictionary<Size, SizeRequest>(); 1123 SizeRequest GetSizeRequest(double widthConstraint, double heightConstraint) 1126 if (_measureCache.TryGetValue(constraintSize, out SizeRequest cachedResult)) 1136 SizeRequest result = OnMeasure(widthConstraint, heightConstraint); 1166 var r = new SizeRequest(request, minimum); 1197 public virtual SizeRequest Measure(double widthConstraint, double heightConstraint, MeasureFlags flags = MeasureFlags.None) 1209 SizeRequest result = GetSizeRequest(widthConstraint, heightConstraint); 1309 protected virtual SizeRequest OnMeasure(double widthConstraint, double heightConstraint)
Microsoft.Maui.Controls.Compatibility (47)
iOS\Cells\ViewCellRenderer.cs (1)
126 var result = renderer.Element.Measure(width, height, MeasureFlags.IncludeMargins);
iOS\CollectionView\HeightConstrainedTemplatedCell.cs (1)
38 var desiredBounds = VisualElementRenderer.Element.Measure(double.PositiveInfinity, bounds.Height,
iOS\CollectionView\HorizontalCell.cs (1)
21 var measure = VisualElementRenderer.Element.Measure(double.PositiveInfinity,
iOS\CollectionView\HorizontalTemplatedHeaderView.cs (1)
26 var measure = VisualElementRenderer.Element.Measure(double.PositiveInfinity,
iOS\CollectionView\ItemsViewController.cs (2)
389 var request = formsElement.Measure(double.PositiveInfinity, CollectionView.Frame.Height, MeasureFlags.IncludeMargins); 394 var request = formsElement.Measure(CollectionView.Frame.Width, double.PositiveInfinity, MeasureFlags.IncludeMargins);
iOS\CollectionView\ItemsViewRenderer.cs (1)
31 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\CollectionView\VerticalCell.cs (1)
21 var measure = VisualElementRenderer.Element.Measure(ConstrainedDimension,
iOS\CollectionView\VerticalSupplementaryView.cs (1)
26 var measure = VisualElementRenderer.Element.Measure(ConstrainedDimension,
iOS\CollectionView\WidthConstrainedTemplatedCell.cs (1)
38 var desiredBounds = VisualElementRenderer.Element.Measure(bounds.Width, double.PositiveInfinity,
iOS\Extensions\LayoutExtensions.cs (1)
16 public delegate SizeRequest? GetDesiredSizeDelegate(
iOS\HandlerToRendererShim.cs (1)
72 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\IVisualElementRenderer.cs (1)
28 SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint);
iOS\NativeViewWrapperRenderer.cs (1)
24 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Platform.cs (1)
216 public static SizeRequest GetNativeSize(VisualElement view, double widthConstraint, double heightConstraint)
iOS\Renderers\CarouselPageRenderer.cs (1)
53 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\CheckBoxRendererBase.cs (2)
53 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) 55 var sizeConstraint = base.GetDesiredSize(widthConstraint, heightConstraint);
iOS\Renderers\EntryRenderer.cs (2)
60 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) 62 var baseResult = base.GetDesiredSize(widthConstraint, heightConstraint);
iOS\Renderers\IndicatorViewRenderer.cs (1)
168 var indicatorLayoutSizeRequest = indicatorLayout.Measure(double.PositiveInfinity, double.PositiveInfinity, MeasureFlags.IncludeMargins);
iOS\Renderers\LabelRenderer.cs (3)
30 SizeRequest _perfectSize; 58 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) 73 var result = base.GetDesiredSize(widthConstraint, heightConstraint);
iOS\Renderers\ListViewRenderer.cs (8)
61 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) 75 var request = e.Measure(width, double.PositiveInfinity, MeasureFlags.IncludeMargins); 97 var request = e.Measure(width, height, MeasureFlags.IncludeMargins); 405 var request = footerView.Measure(width, double.PositiveInfinity, MeasureFlags.IncludeMargins); 427 var request = headerView.Measure(width, double.PositiveInfinity, MeasureFlags.IncludeMargins); 498 var request = footerView.Measure(width, double.PositiveInfinity, MeasureFlags.IncludeMargins); 544 var request = headerView.Measure(width, double.PositiveInfinity, MeasureFlags.IncludeMargins); 954 var req = target.Measure(tableView.Frame.Width, double.PositiveInfinity, MeasureFlags.IncludeMargins);
iOS\Renderers\NavigationRenderer.cs (1)
65 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\PageRenderer.cs (1)
50 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\PhoneFlyoutPageRenderer.cs (1)
69 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\ScrollViewRenderer.cs (1)
48 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\SwipeViewRenderer.cs (3)
1317 var swipeItemViewSizeRequest = horizontalSwipeItemView.Measure(double.PositiveInfinity, double.PositiveInfinity, MeasureFlags.IncludeMargins); 1339 var swipeItemViewSizeRequest = verticalSwipeItemView.Measure(double.PositiveInfinity, double.PositiveInfinity, MeasureFlags.IncludeMargins); 1367 var swipeItemViewSizeRequest = swipeItemView.Measure(double.PositiveInfinity, double.PositiveInfinity, MeasureFlags.IncludeMargins);
iOS\Renderers\TabbedRenderer.cs (1)
58 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\TabletFlyoutPageRenderer.cs (1)
199 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\TableViewRenderer.cs (1)
25 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Renderers\UIContainerView.cs (1)
76 var request = _view.Measure(Frame.Width, double.PositiveInfinity, MeasureFlags.None);
iOS\Renderers\WkWebViewRenderer.cs (1)
80 public SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)
iOS\Shapes\ShapeRenderer.cs (2)
89 public override SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint) 302 public SizeRequest GetDesiredSize()
iOS\VisualElementRenderer.cs (1)
151 public virtual SizeRequest GetDesiredSize(double widthConstraint, double heightConstraint)