Function zng_wgt_size_offset::force_size
source · pub fn force_size(child: impl UiNode, size: impl IntoVar<Size>) -> impl UiNode
Expand description
P
Exact size of the widget ignoring the contextual max.
When set the widget is layout with exact size constraints, ignoring the contextual max. Relative values are computed from the constraints maximum bounded size.
Note that this property deliberately breaks layout and causes out-of-bounds rendering. You
can use size
instead to set an exact size that is coerced by the contextual max.
§force_width
and force_height
You can use the force_width
and force_height
properties to only set the size of one dimension.