pub struct Plot3DUi<'ui> { /* private fields */ }Expand description
Frame access to an ImPlot3D context. Begin a plot to configure axes and submit items.
use dear_implot3d::Plot3DUi;
fn query_outside_plot(ui: &Plot3DUi<'_>) { ui.get_frame_size(); }Implementations§
Source§impl Plot3DUi<'_>
impl Plot3DUi<'_>
Sourcepub fn show_all_demos(&self)
pub fn show_all_demos(&self)
Show upstream ImPlot3D demos (from C++ demo).
This displays all available ImPlot3D demos in a single window. Useful for learning and testing the library.
Sourcepub fn show_demo_window(&self)
pub fn show_demo_window(&self)
Show the ImPlot3D demo. Its ImGui tools use the core font-atlas filter.
This displays the main demo window with tabs for different plot types.
Sourcepub fn show_demo_window_with_flag(&self, p_open: &mut bool)
pub fn show_demo_window_with_flag(&self, p_open: &mut bool)
Show the main ImPlot3D demo window with a visibility flag.
Sourcepub fn show_style_editor(&self)
pub fn show_style_editor(&self)
Show the style editor with this plot context’s saved reference and color preview.
This displays a window for editing ImPlot3D style settings in real time.
Sourcepub fn show_metrics_window(&self)
pub fn show_metrics_window(&self)
Show the ImPlot3D metrics/debugger window.
This displays performance metrics and debugging information.
Sourcepub fn show_metrics_window_with_flag(&self, p_open: &mut bool)
pub fn show_metrics_window_with_flag(&self, p_open: &mut bool)
Show the ImPlot3D metrics/debugger window with a visibility flag.
Source§impl Plot3DUi<'_>
impl Plot3DUi<'_>
Sourcepub fn with_colormap<R>(
&self,
cmap: impl Into<ColormapIndex>,
f: impl FnOnce() -> R,
) -> R
pub fn with_colormap<R>( &self, cmap: impl Into<ColormapIndex>, f: impl FnOnce() -> R, ) -> R
Uses a registered colormap for f. An invalid index panics before the native push.
Sourcepub fn with_colormap_name<R>(
&self,
name: &str,
f: impl FnOnce() -> R,
) -> Option<R>
pub fn with_colormap_name<R>( &self, name: &str, f: impl FnOnce() -> R, ) -> Option<R>
Uses a registered colormap by name for f. Returns None for an unknown name.
Source§impl Plot3DUi<'_>
impl Plot3DUi<'_>
Sourcepub fn colormap_color(&self, index: ColormapColorIndex) -> [f32; 4]
pub fn colormap_color(&self, index: ColormapColorIndex) -> [f32; 4]
Return a color from this UI’s active ImPlot3D colormap.
Source§impl Plot3DUi<'_>
impl Plot3DUi<'_>
Sourcepub fn with_style_colors<R>(
&self,
colors: &[(Plot3DColorElement, [f32; 4])],
f: impl FnOnce() -> R,
) -> R
pub fn with_style_colors<R>( &self, colors: &[(Plot3DColorElement, [f32; 4])], f: impl FnOnce() -> R, ) -> R
Applies these colors to this context for the duration of f.
Sourcepub fn with_style_vars<R>(
&self,
vars: &[Plot3DStyleVar],
f: impl FnOnce() -> R,
) -> R
pub fn with_style_vars<R>( &self, vars: &[Plot3DStyleVar], f: impl FnOnce() -> R, ) -> R
Applies the typed style variables in order and restores them when f returns or unwinds.
Source§impl<'ui> Plot3DUi<'ui>
impl<'ui> Plot3DUi<'ui>
Sourcepub fn begin_plot(&self, title: impl AsRef<str>) -> Plot3DBuilder<'ui>
pub fn begin_plot(&self, title: impl AsRef<str>) -> Plot3DBuilder<'ui>
Configure a plot for the current window and table cell.