pub trait RenderSliverEdgeInsetsPadding: RenderSliver + RenderObjectWithChildMixin<ChildType = AnyRenderSliver> {
Show 13 methods
// Required method
fn resolved_padding(
self: RenderHandle<Self>,
app: &App,
) -> Option<EdgeInsets>;
// Provided methods
fn before_padding(self: RenderHandle<Self>, app: &App) -> f64 { ... }
fn after_padding(self: RenderHandle<Self>, app: &App) -> f64 { ... }
fn main_axis_padding(self: RenderHandle<Self>, app: &App) -> f64 { ... }
fn cross_axis_padding(self: RenderHandle<Self>, app: &App) -> f64 { ... }
fn setup_parent_data(
self: RenderHandle<Self>,
app: &mut App,
child: AnyRenderObject,
) { ... }
fn perform_layout(self: RenderHandle<Self>, app: &mut App) { ... }
fn hit_test_children(
self: RenderHandle<Self>,
app: &mut App,
result: &mut SliverHitTestResult<'_>,
main_axis_position: f64,
cross_axis_position: f64,
) -> bool { ... }
fn child_main_axis_position(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> f64 { ... }
fn child_cross_axis_position(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> f64 { ... }
fn child_scroll_offset(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> Option<f64> { ... }
fn apply_paint_transform(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
transform: &mut Matrix4,
) { ... }
fn paint(
self: RenderHandle<Self>,
app: &mut App,
context: &mut PaintingContext,
offset: Offset,
) { ... }
}Expand description
A sliver that insets another sliver by applying resolved padding on each side.
Flutter’s RenderSliverEdgeInsetsPadding: the shared bodies of a padding sliver, over the
resolved_padding the implementor supplies.
Required Methods§
Sourcefn resolved_padding(self: RenderHandle<Self>, app: &App) -> Option<EdgeInsets>
fn resolved_padding(self: RenderHandle<Self>, app: &App) -> Option<EdgeInsets>
The amount to pad the child in each dimension.
The offsets are specified in terms of visual edges, left, top, right, and bottom. These
values are not affected by the TextDirection.
Must be Some and contain no negative values when perform_layout is called.
Provided Methods§
Sourcefn before_padding(self: RenderHandle<Self>, app: &App) -> f64
fn before_padding(self: RenderHandle<Self>, app: &App) -> f64
The padding in the scroll direction on the side nearest the 0.0 scroll direction.
Only valid after layout has started, since before layout the render object doesn’t know what direction it will be laid out in.
Sourcefn after_padding(self: RenderHandle<Self>, app: &App) -> f64
fn after_padding(self: RenderHandle<Self>, app: &App) -> f64
The padding in the scroll direction on the side furthest from the 0.0 scroll offset.
Only valid after layout has started.
Sourcefn main_axis_padding(self: RenderHandle<Self>, app: &App) -> f64
fn main_axis_padding(self: RenderHandle<Self>, app: &App) -> f64
The total padding in the crate::SliverConstraints::axis_direction. (In other words,
for a vertical downwards-growing list, the sum of the padding on the top and bottom.)
Only valid after layout has started.
Sourcefn cross_axis_padding(self: RenderHandle<Self>, app: &App) -> f64
fn cross_axis_padding(self: RenderHandle<Self>, app: &App) -> f64
The total padding in the cross-axis direction. (In other words, for a vertical downwards-growing list, the sum of the padding on the left and right.)
Only valid after layout has started.
Sourcefn setup_parent_data(
self: RenderHandle<Self>,
app: &mut App,
child: AnyRenderObject,
)
fn setup_parent_data( self: RenderHandle<Self>, app: &mut App, child: AnyRenderObject, )
The body of Flutter’s setupParentData override.
Sourcefn perform_layout(self: RenderHandle<Self>, app: &mut App)
fn perform_layout(self: RenderHandle<Self>, app: &mut App)
The body of Flutter’s performLayout override.
Sourcefn hit_test_children(
self: RenderHandle<Self>,
app: &mut App,
result: &mut SliverHitTestResult<'_>,
main_axis_position: f64,
cross_axis_position: f64,
) -> bool
fn hit_test_children( self: RenderHandle<Self>, app: &mut App, result: &mut SliverHitTestResult<'_>, main_axis_position: f64, cross_axis_position: f64, ) -> bool
The body of Flutter’s hitTestChildren override.
Sourcefn child_main_axis_position(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> f64
fn child_main_axis_position( self: RenderHandle<Self>, app: &App, child: AnyRenderObject, ) -> f64
The body of Flutter’s childMainAxisPosition override.
Sourcefn child_cross_axis_position(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> f64
fn child_cross_axis_position( self: RenderHandle<Self>, app: &App, child: AnyRenderObject, ) -> f64
The body of Flutter’s childCrossAxisPosition override.
Sourcefn child_scroll_offset(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
) -> Option<f64>
fn child_scroll_offset( self: RenderHandle<Self>, app: &App, child: AnyRenderObject, ) -> Option<f64>
The body of Flutter’s childScrollOffset override.
Sourcefn apply_paint_transform(
self: RenderHandle<Self>,
app: &App,
child: AnyRenderObject,
transform: &mut Matrix4,
)
fn apply_paint_transform( self: RenderHandle<Self>, app: &App, child: AnyRenderObject, transform: &mut Matrix4, )
The body of Flutter’s applyPaintTransform override.
Sourcefn paint(
self: RenderHandle<Self>,
app: &mut App,
context: &mut PaintingContext,
offset: Offset,
)
fn paint( self: RenderHandle<Self>, app: &mut App, context: &mut PaintingContext, offset: Offset, )
The body of Flutter’s paint override.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".