documentation
This commit is contained in:
parent
5c87d987cf
commit
eb8e1c4303
3 changed files with 11 additions and 6 deletions
|
@ -2,7 +2,9 @@ use crate::Padding;
|
|||
use egui::{Pos2, Rect, Response, Rgba, Sense, Ui, Vec2};
|
||||
|
||||
pub(crate) enum CellSize {
|
||||
/// Absolute size in points
|
||||
Absolute(f32),
|
||||
/// Take all available space
|
||||
Remainder,
|
||||
}
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
/// Configure padding of grid or table
|
||||
/// TODO: Use padding settings of egui?
|
||||
#[derive(Clone, Debug)]
|
||||
pub struct Padding {
|
||||
pub(crate) inner: f32,
|
||||
|
|
|
@ -1,18 +1,19 @@
|
|||
#[derive(Clone, Debug)]
|
||||
pub enum Size {
|
||||
/// in points
|
||||
/// Absolute size in points
|
||||
Absolute(f32),
|
||||
/// 0.0 to 1.0
|
||||
/// Relative size relative to all available space. Values must be in range `0.0..=1.0`
|
||||
Relative(f32),
|
||||
/// [`Size::Relative`] with a minimum size in points
|
||||
RelativeMinimum {
|
||||
/// 0.0 to 1.0
|
||||
/// Relative size relative to all available space. Values must be in range `0.0..=1.0`
|
||||
relative: f32,
|
||||
/// in points
|
||||
/// Absolute minimum size in points
|
||||
minimum: f32,
|
||||
},
|
||||
/// multiple remainders get each the same space
|
||||
/// Multiple remainders each get the same space
|
||||
Remainder,
|
||||
/// multiple remainders get each the same space, at least the minimum
|
||||
/// [`Size::Remainder`] with a minimum size in points
|
||||
RemainderMinimum(f32),
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue