Correlation 4.10.0
An Analysis Tool for Liquids and for Amorphous Solids
Loading...
Searching...
No Matches
correlation::plotters::PlotConfig Struct Reference

Theme and layout configuration for the plot. More...

#include <PlotTypes.hpp>

Public Types

enum class  Theme : std::uint8_t { Light , Dark }
 Visualization themes for the generated SVG. More...
enum class  Palette : std::uint8_t {
  OkabeIto , Grayscale , Viridis , Magma ,
  Heatmap , Rainbow , Turbo , Plasma ,
  Inferno , Cividis
}
 Color palette selections. More...
enum class  PresetSize : std::uint8_t { Default , SingleColumn , DoubleColumn , Presentation }
 Standard publication sizes. More...

Public Member Functions

real_t effectiveWidth () const
real_t effectiveHeight () const
std::string_view bgColor () const
std::string_view axisColor () const
std::string_view gridColor () const
std::string_view textColor () const

Public Attributes

Theme theme = Theme::Light
 Current theme selection.
real_t width = static_cast<real_t>(1200.0)
 SVG canvas width (px).
real_t height = static_cast<real_t>(900.0)
 SVG canvas height (px).
bool show_grid = true
 Whether to render background grid lines.
bool show_minor_grid = false
 Whether to render minor subdivision grid lines.
bool show_markers = false
 Whether to render data point markers (dots).
bool fill_area = false
 Whether to render matching gradient fills under the curves.
bool show_difference_curve
 Toggle overlaid absolute difference curve Y_diff = Y_ref - Y_target.
bool y_log_scale = false
 Whether Y-axis uses logarithmic (log10) scale.
real_t font_scale = static_cast<real_t>(1.0)
 Multiplier for all font sizes.
real_t line_width = static_cast<real_t>(3.0)
 Data line stroke width.
real_t marker_size = static_cast<real_t>(3.5)
 Data point marker radius (px).
bool show_legend = true
 Toggle legend visibility.
bool use_native_text = false
 Use standard SVG <text> elements instead of Hershey paths.
Palette palette = Palette::OkabeIto
PresetSize preset_size = PresetSize::Default
std::optional< real_t > manual_x_min
std::optional< real_t > manual_x_max
std::optional< real_t > manual_y_min
std::optional< real_t > manual_y_max
bool manual_ticks = false
real_t x_major_step = static_cast<real_t>(0.0)
real_t y_major_step = static_cast<real_t>(0.0)
int minor_subdivisions = 0
bool show_peak_callouts = true
std::vector< ReferenceLine > reference_lines

Detailed Description

Theme and layout configuration for the plot.

Member Enumeration Documentation

◆ Palette

enum class correlation::plotters::PlotConfig::Palette : std::uint8_t
strong

Color palette selections.

Enumerator
OkabeIto 

Colorblind-safe palette.

Grayscale 

B&W printing friendly.

Viridis 

Perceptually uniform.

Magma 

Sequential dark to bright purple/yellow.

Heatmap 

Hot thermal gradient (Black-Red-Yellow-White).

Rainbow 

Standard Jet/HSV rainbow gradient.

Turbo 

Google Turbo perceptually smooth rainbow.

Plasma 

Sequential purple to yellow/orange.

Inferno 

Sequential dark to bright yellow.

Cividis 

Colorblind-optimized perceptually uniform.

◆ PresetSize

enum class correlation::plotters::PlotConfig::PresetSize : std::uint8_t
strong

Standard publication sizes.

Enumerator
Default 
SingleColumn 
DoubleColumn 
Presentation 

◆ Theme

enum class correlation::plotters::PlotConfig::Theme : std::uint8_t
strong

Visualization themes for the generated SVG.

Enumerator
Light 

Standard light theme for publications.

Dark 

Modern dark theme for UI integration (e.g., Catppuccin-esque).

Member Function Documentation

◆ axisColor()

std::string_view correlation::plotters::PlotConfig::axisColor ( ) const
inlinenodiscard
Returns
Hex color string for axes and ticks.

◆ bgColor()

std::string_view correlation::plotters::PlotConfig::bgColor ( ) const
inlinenodiscard
Returns
Hex color string for the plot background.
Here is the caller graph for this function:

◆ effectiveHeight()

real_t correlation::plotters::PlotConfig::effectiveHeight ( ) const
inlinenodiscard
Here is the caller graph for this function:

◆ effectiveWidth()

real_t correlation::plotters::PlotConfig::effectiveWidth ( ) const
inlinenodiscard
Here is the caller graph for this function:

◆ gridColor()

std::string_view correlation::plotters::PlotConfig::gridColor ( ) const
inlinenodiscard
Returns
Hex color string for grid lines.

◆ textColor()

std::string_view correlation::plotters::PlotConfig::textColor ( ) const
inlinenodiscard
Returns
Hex color string for labels and titles.
Here is the caller graph for this function:

Member Data Documentation

◆ fill_area

bool correlation::plotters::PlotConfig::fill_area = false

Whether to render matching gradient fills under the curves.

◆ font_scale

real_t correlation::plotters::PlotConfig::font_scale = static_cast<real_t>(1.0)

Multiplier for all font sizes.

◆ height

real_t correlation::plotters::PlotConfig::height = static_cast<real_t>(900.0)

SVG canvas height (px).

◆ line_width

real_t correlation::plotters::PlotConfig::line_width = static_cast<real_t>(3.0)

Data line stroke width.

◆ manual_ticks

bool correlation::plotters::PlotConfig::manual_ticks = false

◆ manual_x_max

std::optional<real_t> correlation::plotters::PlotConfig::manual_x_max

◆ manual_x_min

std::optional<real_t> correlation::plotters::PlotConfig::manual_x_min

◆ manual_y_max

std::optional<real_t> correlation::plotters::PlotConfig::manual_y_max

◆ manual_y_min

std::optional<real_t> correlation::plotters::PlotConfig::manual_y_min

◆ marker_size

real_t correlation::plotters::PlotConfig::marker_size = static_cast<real_t>(3.5)

Data point marker radius (px).

◆ minor_subdivisions

int correlation::plotters::PlotConfig::minor_subdivisions = 0

◆ palette

Palette correlation::plotters::PlotConfig::palette = Palette::OkabeIto

◆ preset_size

PresetSize correlation::plotters::PlotConfig::preset_size = PresetSize::Default

◆ reference_lines

std::vector<ReferenceLine> correlation::plotters::PlotConfig::reference_lines

◆ show_difference_curve

bool correlation::plotters::PlotConfig::show_difference_curve
Initial value:
=
false

Toggle overlaid absolute difference curve Y_diff = Y_ref - Y_target.

◆ show_grid

bool correlation::plotters::PlotConfig::show_grid = true

Whether to render background grid lines.

◆ show_legend

bool correlation::plotters::PlotConfig::show_legend = true

Toggle legend visibility.

◆ show_markers

bool correlation::plotters::PlotConfig::show_markers = false

Whether to render data point markers (dots).

◆ show_minor_grid

bool correlation::plotters::PlotConfig::show_minor_grid = false

Whether to render minor subdivision grid lines.

◆ show_peak_callouts

bool correlation::plotters::PlotConfig::show_peak_callouts = true

◆ theme

Theme correlation::plotters::PlotConfig::theme = Theme::Light

Current theme selection.

◆ use_native_text

bool correlation::plotters::PlotConfig::use_native_text = false

Use standard SVG <text> elements instead of Hershey paths.

◆ width

real_t correlation::plotters::PlotConfig::width = static_cast<real_t>(1200.0)

SVG canvas width (px).

◆ x_major_step

real_t correlation::plotters::PlotConfig::x_major_step = static_cast<real_t>(0.0)

◆ y_log_scale

bool correlation::plotters::PlotConfig::y_log_scale = false

Whether Y-axis uses logarithmic (log10) scale.

◆ y_major_step

real_t correlation::plotters::PlotConfig::y_major_step = static_cast<real_t>(0.0)

The documentation for this struct was generated from the following file: