diff options
author | 2021-09-20 14:33:02 +0700 | |
---|---|---|
committer | 2021-09-20 15:12:43 +0700 | |
commit | 5fae6e59ffbc5913761df638dc7f0c35b7f43bc9 (patch) | |
tree | 02cbacf17780d1df9e37b38a33c0f882ab9312d7 /native/src/widget/column.rs | |
parent | 95e4791a1e4611f0db703ac2911f56b391469b5f (diff) | |
download | iced-5fae6e59ffbc5913761df638dc7f0c35b7f43bc9.tar.gz iced-5fae6e59ffbc5913761df638dc7f0c35b7f43bc9.tar.bz2 iced-5fae6e59ffbc5913761df638dc7f0c35b7f43bc9.zip |
Introduce and use `CrossAlign` enum for `Column` and `Row`
Diffstat (limited to 'native/src/widget/column.rs')
-rw-r--r-- | native/src/widget/column.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/native/src/widget/column.rs b/native/src/widget/column.rs index 52a2e80c..83e5760a 100644 --- a/native/src/widget/column.rs +++ b/native/src/widget/column.rs @@ -5,7 +5,7 @@ use crate::event::{self, Event}; use crate::layout; use crate::overlay; use crate::{ - Align, Clipboard, Element, Hasher, Layout, Length, Padding, Point, + Clipboard, CrossAlign, Element, Hasher, Layout, Length, Padding, Point, Rectangle, Widget, }; @@ -20,7 +20,7 @@ pub struct Column<'a, Message, Renderer> { height: Length, max_width: u32, max_height: u32, - align_items: Align, + align_items: CrossAlign, children: Vec<Element<'a, Message, Renderer>>, } @@ -41,7 +41,7 @@ impl<'a, Message, Renderer> Column<'a, Message, Renderer> { height: Length::Shrink, max_width: u32::MAX, max_height: u32::MAX, - align_items: Align::Start, + align_items: CrossAlign::Start, children, } } @@ -87,7 +87,7 @@ impl<'a, Message, Renderer> Column<'a, Message, Renderer> { } /// Sets the horizontal alignment of the contents of the [`Column`] . - pub fn align_items(mut self, align: Align) -> Self { + pub fn align_items(mut self, align: CrossAlign) -> Self { self.align_items = align; self } |