Implement pure version of Rule widget
This commit is contained in:
parent
31d814b43c
commit
0fbd1d98b5
3 changed files with 116 additions and 6 deletions
|
|
@ -1,4 +1,5 @@
|
|||
pub mod image;
|
||||
pub mod rule;
|
||||
pub mod tree;
|
||||
|
||||
mod button;
|
||||
|
|
@ -25,6 +26,7 @@ pub use image::Image;
|
|||
pub use pick_list::PickList;
|
||||
pub use radio::Radio;
|
||||
pub use row::Row;
|
||||
pub use rule::Rule;
|
||||
pub use scrollable::Scrollable;
|
||||
pub use slider::Slider;
|
||||
pub use space::Space;
|
||||
|
|
@ -234,3 +236,13 @@ pub fn horizontal_space(width: Length) -> Space {
|
|||
pub fn vertical_space(height: Length) -> Space {
|
||||
Space::with_height(height)
|
||||
}
|
||||
|
||||
/// Creates a horizontal [`Rule`] with the given height.
|
||||
pub fn horizontal_rule<'a>(height: u16) -> Rule<'a> {
|
||||
Rule::horizontal(height)
|
||||
}
|
||||
|
||||
/// Creates a vertical [`Rule`] with the given width.
|
||||
pub fn vertical_rule<'a>(width: u16) -> Rule<'a> {
|
||||
Rule::horizontal(width)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue