pub struct AutomaticNotchedShape {
pub host: ShapeBorderRef,
pub guest: Option<ShapeBorderRef>,
}Expand description
A NotchedShape created from [ShapeBorder]s.
Two shapes can be provided. The host is the shape of the widget that
uses the NotchedShape (typically a BottomAppBar). The guest is
subtracted from the host to create the notch (typically to make room
for a FloatingActionButton).
Fields§
§host: ShapeBorderRefThe shape of the widget that uses the NotchedShape (typically a
BottomAppBar).
This shape cannot depend on the TextDirection, as no text direction
is available to NotchedShapes.
guest: Option<ShapeBorderRef>The shape to subtract from the host to make the notch.
This shape cannot depend on the TextDirection, as no text direction
is available to NotchedShapes.
If this is null, get_outer_path ignores the guest
rectangle.
Implementations§
Source§impl AutomaticNotchedShape
impl AutomaticNotchedShape
Sourcepub fn new(host: impl Into<ShapeBorderRef>) -> AutomaticNotchedShape
pub fn new(host: impl Into<ShapeBorderRef>) -> AutomaticNotchedShape
Creates a NotchedShape that is defined by two [ShapeBorder]s.
The guest may be null, in which case no notch is created even
if a guest rectangle is provided to get_outer_path.
Sourcepub fn guest(self, guest: impl Into<ShapeBorderRef>) -> AutomaticNotchedShape
pub fn guest(self, guest: impl Into<ShapeBorderRef>) -> AutomaticNotchedShape
Dart AutomaticNotchedShape(host, guest).
Trait Implementations§
Source§impl Clone for AutomaticNotchedShape
impl Clone for AutomaticNotchedShape
Source§fn clone(&self) -> AutomaticNotchedShape
fn clone(&self) -> AutomaticNotchedShape
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more