Struct kas_theme::DimensionsParams [−][src]
pub struct DimensionsParams {
pub outer_margin: f32,
pub inner_margin: f32,
pub text_margin: f32,
pub frame_size: f32,
pub button_frame: f32,
pub scrollbar_size: Vec2,
pub slider_size: Vec2,
pub progress_bar: Vec2,
}Expand description
Parameterisation of Dimensions
All dimensions are multiplied by the DPI factor, then rounded to the
nearest integer. Example: (2.0 * 1.25).round() = 3.0.
Fields
outer_margin: f32Space between elements
inner_margin: f32Margin inside a frame before contents
text_margin: f32Margin between text elements
frame_size: f32Frame size
Button frame size (non-flat outer region)
scrollbar_size: Vec2Scrollbar minimum handle size
slider_size: Vec2Slider minimum handle size
progress_bar: Vec2Progress bar size (horizontal)
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for DimensionsParamsimpl Send for DimensionsParamsimpl Sync for DimensionsParamsimpl Unpin for DimensionsParamsimpl UnwindSafe for DimensionsParamsBlanket Implementations
Mutably borrows from an owned value. Read more
pub fn cast_trunc(self) -> T
pub fn cast_trunc(self) -> TCast to integer, truncating Read more
pub fn cast_nearest(self) -> T
pub fn cast_nearest(self) -> TCast to the nearest integer Read more
pub fn cast_floor(self) -> T
pub fn cast_floor(self) -> TCast the floor to an integer Read more
pub fn try_cast_trunc(self) -> Result<T, Error>
pub fn try_cast_trunc(self) -> Result<T, Error>Try converting to integer with truncation Read more
pub fn try_cast_nearest(self) -> Result<T, Error>
pub fn try_cast_nearest(self) -> Result<T, Error>Try converting to the nearest integer Read more
pub fn try_cast_floor(self) -> Result<T, Error>
pub fn try_cast_floor(self) -> Result<T, Error>Try converting the floor to an integer Read more
pub fn try_cast_ceil(self) -> Result<T, Error>
pub fn try_cast_ceil(self) -> Result<T, Error>Try convert the ceiling to an integer Read more