pub struct HypexUi {
pub egui_ctx: Context,
pub design_tokens: DesignTokens,
pub static_image_cache: Arc<Mutex<StaticImageCache>>,
}
Fields§
§egui_ctx: Context
§design_tokens: DesignTokens
Colors, styles etc loaded from a design_tokens.json
static_image_cache: Arc<Mutex<StaticImageCache>>
Implementations§
source§impl HypexUi
impl HypexUi
sourcepub fn load_and_apply(egui_ctx: &Context) -> Self
pub fn load_and_apply(egui_ctx: &Context) -> Self
Create HypexUi
and apply style to the given egui context.
pub fn rerun_logo(&self) -> Arc<RetainedImage>
sourcepub fn view_padding() -> f32
pub fn view_padding() -> f32
Margin on all sides of views.
pub fn window_rounding() -> f32
pub fn normal_rounding() -> f32
pub fn small_rounding() -> f32
pub fn table_line_height() -> f32
pub fn table_header_height() -> f32
pub fn top_bar_margin() -> Margin
sourcepub fn top_bar_height() -> f32
pub fn top_bar_height() -> f32
Height of the top-most bar.
sourcepub fn title_bar_height() -> f32
pub fn title_bar_height() -> f32
Height of the title row in the blueprint view and selection view, as well as the tab bar height in the viewport view.
pub fn native_window_rounding() -> f32
pub fn top_panel_frame(&self) -> Frame
pub fn bottom_panel_margin(&self) -> Vec2
sourcepub fn bottom_panel_frame(&self) -> Frame
pub fn bottom_panel_frame(&self) -> Frame
For the streams view (time panel)
pub fn small_icon_size() -> Vec2
pub fn setup_table_header(_header: &mut TableRow<'_, '_>)
pub fn setup_table_body(body: &mut TableBody<'_>)
pub fn warning_text(&self, text: impl Into<String>) -> RichText
pub fn error_text(&self, text: impl Into<String>) -> RichText
sourcepub fn loop_selection_color() -> Color32
pub fn loop_selection_color() -> Color32
The color we use to mean “loop this selection”
sourcepub fn loop_everything_color() -> Color32
pub fn loop_everything_color() -> Color32
The color we use to mean “loop all the data”
sourcepub fn paint_watermark(&self)
pub fn paint_watermark(&self)
Paint a watermark
pub fn top_bar_style( &self, native_pixels_per_point: Option<f32>, fullscreen: bool, style_like_web: bool ) -> TopBarStyle
pub fn icon_image(&self, icon: &Icon) -> Arc<RetainedImage>
pub fn checkbox( &self, ui: &mut Ui, selected: &mut bool, text: impl Into<WidgetText> ) -> Response
pub fn radio_value<Value: PartialEq>( &self, ui: &mut Ui, current_value: &mut Value, alternative: Value, text: impl Into<WidgetText> ) -> Response
pub fn large_collapsing_header<R>( &self, ui: &mut Ui, label: &str, default_open: bool, add_body: impl FnOnce(&mut Ui) -> R )
sourcepub fn grid_left_hand_label(&self, ui: &mut Ui, label: &str) -> Response
pub fn grid_left_hand_label(&self, ui: &mut Ui, label: &str) -> Response
Workaround for putting a label into a grid at the top left of its row.
sourcepub fn selection_grid(&self, ui: &mut Ui, id: &str) -> Grid
pub fn selection_grid(&self, ui: &mut Ui, id: &str) -> Grid
Two-column grid to be used in selection view.
sourcepub fn draw_shadow_line(&self, ui: &mut Ui, rect: Rect, direction: Direction)
pub fn draw_shadow_line(&self, ui: &mut Ui, rect: Rect, direction: Direction)
Draws a shadow into the given rect with the shadow direction given from dark to light
pub fn selectable_label_with_icon( &self, ui: &mut Ui, icon: &Icon, text: impl Into<WidgetText>, selected: bool ) -> Response
sourcepub fn text_format_body(&self) -> TextFormat
pub fn text_format_body(&self) -> TextFormat
Text format used for regular body.
sourcepub fn text_format_key(&self) -> TextFormat
pub fn text_format_key(&self) -> TextFormat
Text format used for labels referring to keys and buttons.
sourcepub fn paint_time_cursor(
&self,
painter: &Painter,
x: f32,
y: RangeInclusive<f32>,
stroke: Stroke
)
pub fn paint_time_cursor( &self, painter: &Painter, x: f32, y: RangeInclusive<f32>, stroke: Stroke )
Paints a time cursor for indicating the time on a time axis along x.