pub struct IndicatorPaneConfig {
pub height: f32,
pub y_range: Option<(f64, f64)>,
pub show_zones: bool,
pub zones: Vec<(f64, Color32, &'static str)>,
pub fill_between_zones: bool,
pub show_legend: bool,
pub show_name: bool,
pub inputs: String,
pub show_values: bool,
pub show_grid: bool,
}Expand description
Configuration for an indicator panel’s visual appearance and behavior.
Controls the panel height, y-axis range, zone lines (overbought/oversold),
legend display, and grid visibility. Pre-built configurations are available
for common indicators via IndicatorPaneConfig::rsi,
IndicatorPaneConfig::macd, and IndicatorPaneConfig::stochastic.
Fields§
§height: f32Panel height in egui logical points.
y_range: Option<(f64, f64)>Fixed y-axis range (None = auto-scale)
show_zones: boolShow horizontal zone lines (e.g., RSI 70/30)
zones: Vec<(f64, Color32, &'static str)>Zone levels, colours and captions. A zone in Color32::TRANSPARENT draws no line and
still bounds the fill.
fill_between_zones: boolFill between the lowest and highest zone in the study’s
Indicator::level_fill_color.
show_legend: boolShow legend
show_name: boolShow the study name in its legend.
inputs: StringHost-supplied input caption; empty omits it.
show_values: boolShow the study output values in its legend.
show_grid: boolShow grid
Implementations§
Source§impl IndicatorPaneConfig
impl IndicatorPaneConfig
Sourcepub fn from_study(study: &dyn Indicator) -> Self
pub fn from_study(study: &dyn Indicator) -> Self
Builds the initial appearance from a study’s pane metadata.
Sourcepub fn stochastic() -> Self
pub fn stochastic() -> Self
Create config for Stochastic indicator
Trait Implementations§
Source§impl Clone for IndicatorPaneConfig
impl Clone for IndicatorPaneConfig
Source§fn clone(&self) -> IndicatorPaneConfig
fn clone(&self) -> IndicatorPaneConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IndicatorPaneConfig
impl Debug for IndicatorPaneConfig
Auto Trait Implementations§
impl Freeze for IndicatorPaneConfig
impl RefUnwindSafe for IndicatorPaneConfig
impl Send for IndicatorPaneConfig
impl Sync for IndicatorPaneConfig
impl Unpin for IndicatorPaneConfig
impl UnsafeUnpin for IndicatorPaneConfig
impl UnwindSafe for IndicatorPaneConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more