From 5a866a031f6d7b81c1f9abafa6efdd0c3ad36f8f Mon Sep 17 00:00:00 2001 From: Ian Hickson Date: Sun, 16 Jul 2023 17:36:30 -0700 Subject: [PATCH] Clarify the whole "CustomPainters default to Size.zero" thing. (#130624) Fixes https://github.com/flutter/flutter/issues/52707 --- packages/flutter/lib/src/widgets/basic.dart | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/flutter/lib/src/widgets/basic.dart b/packages/flutter/lib/src/widgets/basic.dart index 655b3e875e..100f68d584 100644 --- a/packages/flutter/lib/src/widgets/basic.dart +++ b/packages/flutter/lib/src/widgets/basic.dart @@ -600,11 +600,13 @@ class BackdropFilter extends SingleChildRenderObjectWidget { /// `setState` or `markNeedsLayout` during the callback (the layout for this /// frame has already happened). /// -/// Custom painters normally size themselves to their child. If they do not have -/// a child, they attempt to size themselves to the [size], which defaults to -/// [Size.zero]. [size] must not be null. +/// Custom painters normally size themselves to their [child]. If they do not +/// have a child, they attempt to size themselves to the specified [size], which +/// defaults to [Size.zero]. The parent [may enforce constraints on this +/// size](https://docs.flutter.dev/ui/layout/constraints). /// -/// [isComplex] and [willChange] are hints to the compositor's raster cache. +/// The [isComplex] and [willChange] properties are hints to the compositor's +/// raster cache. /// /// {@tool snippet} ///