pub struct LayoutNode {Show 15 fields
pub bounds: Rect,
pub clip: Rect,
pub visible: bool,
pub enabled: bool,
pub layout_direction: LayoutDirection,
pub scroll: Option<ScrollLayout>,
pub table: Option<Box<TableGeometry>>,
pub split: Option<Box<SplitGeometry>>,
pub tab_header: Option<Rect>,
pub tab_close: Option<Rect>,
pub tumbler: Option<Box<TumblerGeometry>>,
pub switch_position: Option<f32>,
pub swipe_delegate: Option<Box<SwipeDelegateGeometry>>,
pub styled_text: Option<Box<StyledTextLayout>>,
pub children: Vec<LayoutNode>,
/* private fields */
}Fields§
§bounds: Rect§clip: RectRectangular part of the ancestor clip.
visible: bool§enabled: bool§layout_direction: LayoutDirection§scroll: Option<ScrollLayout>§table: Option<Box<TableGeometry>>§split: Option<Box<SplitGeometry>>§tab_header: Option<Rect>Header hit box of a tab, independent of the page visibility.
tab_close: Option<Rect>Close button bounds within a tab header or standalone tab button.
tumbler: Option<Box<TumblerGeometry>>§switch_position: Option<f32>Logical thumb position while a switch gesture is active.
swipe_delegate: Option<Box<SwipeDelegateGeometry>>§styled_text: Option<Box<StyledTextLayout>>§children: Vec<LayoutNode>Implementations§
Source§impl LayoutNode
impl LayoutNode
pub fn attached_scroll_geometry(&self) -> Option<ScrollBarGeometry>
pub fn scroll_control_geometry(&self, node: &Node) -> Option<ScrollBarGeometry>
Sourcepub fn scroll_bars(
&self,
node: &Node,
) -> impl Iterator<Item = ScrollBarGeometry>
pub fn scroll_bars( &self, node: &Node, ) -> impl Iterator<Item = ScrollBarGeometry>
Bars share the viewport’s offsets and do not change content or header layout.
Source§impl LayoutNode
impl LayoutNode
pub fn split_handle_range(&self, path: &[usize]) -> Option<SplitHandleRange>
Source§impl LayoutNode
impl LayoutNode
pub fn list_section_headers(&self) -> &[ListSectionHeader]
Sourcepub fn layout_direction_override(&self) -> Option<LayoutDirection>
pub fn layout_direction_override(&self) -> Option<LayoutDirection>
The nearest explicit direction, including an inherited declaration.
pub fn image_playback<'a>( &self, node: &'a Node, ) -> Option<(&'a Rc<ImagePlaybackRegistration>, bool)>
pub fn allows_overflow(&self) -> bool
pub fn child_clip_shape(&self) -> Option<RoundedClip>
pub fn local_transform(&self) -> Affine
Sourcepub fn table_pane_clip(&self) -> Option<(Rect, Affine)>
pub fn table_pane_clip(&self) -> Option<(Rect, Affine)>
An exact table pane clip, expressed in the parent space before this item’s transform.
pub fn world_transform(&self) -> Affine
Sourcepub fn map_from_window(&self, point: Point) -> Option<Point>
pub fn map_from_window(&self, point: Point) -> Option<Point>
Undo the visual transform, returning pre-transform layout coordinates.
pub fn map_delta_from_window(&self, delta: Point) -> Option<Point>
pub fn map_to_window(&self, point: Point) -> Point
pub fn window_bounds(&self, rect: Rect) -> Rect
Sourcepub fn clip_rect(&self, rect: Rect) -> Rect
pub fn clip_rect(&self, rect: Rect) -> Rect
Rectangular projection of the clipping region in layout coordinates.
pub fn visible_window_bounds(&self, rect: Rect) -> Rect
pub fn contains_clip_point(&self, point: Point) -> bool
Sourcepub fn child_paint_order(&self) -> impl DoubleEndedIterator<Item = usize> + '_
pub fn child_paint_order(&self) -> impl DoubleEndedIterator<Item = usize> + '_
Back to front. Scene indices stay in declaration order for routing.
pub fn children_in_paint_order<'a>( &'a self, node: &'a Node, ) -> impl DoubleEndedIterator<Item = (usize, &'a Node, &'a LayoutNode)> + 'a
pub fn text_link_regions(&self) -> impl Iterator<Item = (usize, Rect)> + '_
Sourcepub fn dialog_title_height(&self, _node: &Node) -> f32
pub fn dialog_title_height(&self, _node: &Node) -> f32
Reserved title height using the text metrics prepared for this layout.
pub fn group_header(&self, node: &Node) -> Rect
pub fn scroll_on(&self, orientation: Orientation) -> Option<ScrollLayout>
Sourcepub fn dialog_paths(&self) -> &[Vec<usize>]
pub fn dialog_paths(&self) -> &[Vec<usize>]
Paths of visible modal overlays, in declaration order.
Sourcepub fn overlay_paths(&self) -> &[Vec<usize>]
pub fn overlay_paths(&self) -> &[Vec<usize>]
Paths of all open overlays, in declaration order.
Sourcepub fn child_at(&self, index: usize) -> Option<&Self>
pub fn child_at(&self, index: usize) -> Option<&Self>
Look up a laid-out child by its logical scene index.