diff options
author | 2020-05-22 22:15:44 +0200 | |
---|---|---|
committer | 2020-05-23 01:51:34 +0200 | |
commit | 230bd6f7475752352ca9985802db0633e3508d9f (patch) | |
tree | 55ba66173ef8b5c34784945609daf5b6dc77d6aa /native/src/widget/pane_grid/content.rs | |
parent | 2ab7341fa50865d6f0c26da59f945321ef839c5f (diff) | |
download | iced-230bd6f7475752352ca9985802db0633e3508d9f.tar.gz iced-230bd6f7475752352ca9985802db0633e3508d9f.tar.bz2 iced-230bd6f7475752352ca9985802db0633e3508d9f.zip |
Write documentation for new `pane_grid` API
Diffstat (limited to 'native/src/widget/pane_grid/content.rs')
-rw-r--r-- | native/src/widget/pane_grid/content.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/native/src/widget/pane_grid/content.rs b/native/src/widget/pane_grid/content.rs index 6b0bd99a..8822083e 100644 --- a/native/src/widget/pane_grid/content.rs +++ b/native/src/widget/pane_grid/content.rs @@ -1,12 +1,30 @@ use crate::pane_grid::Axis; +/// The content of a [`PaneGrid`]. +/// +/// [`PaneGrid`]: struct.PaneGrid.html #[derive(Debug, Clone)] pub enum Content<T> { + /// A split of the available space. Split { + /// The direction of the split. axis: Axis, + + /// The ratio of the split in [0.0, 1.0]. ratio: f32, + + /// The left/top [`Content`] of the split. + /// + /// [`Content`]: enum.Node.html a: Box<Content<T>>, + + /// The right/bottom [`Content`] of the split. + /// + /// [`Content`]: enum.Node.html b: Box<Content<T>>, }, + /// A [`Pane`]. + /// + /// [`Pane`]: struct.Pane.html Pane(T), } |