Skip to main content

DiagramLabels

Struct DiagramLabels 

Source
pub struct DiagramLabels {
Show 18 fields pub intensity_unit: &'static str, pub intensity_unit_short: &'static str, pub gamma_axis: &'static str, pub intensity_axis: &'static str, pub c_plane_axis: &'static str, pub gamma_angle_axis: &'static str, pub plane_c0_c180: &'static str, pub plane_c90_c270: &'static str, pub beam: &'static str, pub field: &'static str, pub beam_50_percent: &'static str, pub field_10_percent: &'static str, pub cie_label: &'static str, pub efficacy_label: &'static str, pub max_label: &'static str, pub sh_ratio_label: &'static str, pub heatmap_title: &'static str, pub no_data: &'static str,
}
Expand description

Labels for photometric diagrams (polar, cartesian, heatmap)

Fields§

§intensity_unit: &'static str

Intensity unit label (default: “cd/1000lm”)

§intensity_unit_short: &'static str

Short intensity unit (default: “cd/klm”)

§gamma_axis: &'static str

Gamma angle axis label (default: “Gamma (γ)”)

§intensity_axis: &'static str

Intensity axis label (default: “Intensity (cd/klm)”)

§c_plane_axis: &'static str

C-plane angle axis label (default: “C-Plane Angle (°)”)

§gamma_angle_axis: &'static str

Gamma angle axis label for heatmap (default: “Gamma Angle (°)”)

§plane_c0_c180: &'static str

C0-C180 plane label

§plane_c90_c270: &'static str

C90-C270 plane label

§beam: &'static str

Beam angle label (default: “Beam”)

§field: &'static str

Field angle label (default: “Field”)

§beam_50_percent: &'static str

Beam percentage label (default: “Beam 50%”)

§field_10_percent: &'static str

Field percentage label (default: “Field 10%”)

§cie_label: &'static str

CIE classification label (default: “CIE:”)

§efficacy_label: &'static str

Efficacy label (default: “Eff:”)

§max_label: &'static str

Maximum label (default: “Max:”)

§sh_ratio_label: &'static str

Spacing/height ratio label (default: “S/H:”)

§heatmap_title: &'static str

Heatmap title (default: “Intensity Heatmap (Candela)”)

§no_data: &'static str

No data placeholder (default: “No data”)

Implementations§

Source§

impl DiagramLabels

Source

pub const fn english() -> Self

English labels (default)

Source

pub const fn german() -> Self

German labels

Source

pub const fn french() -> Self

French labels

Source

pub const fn chinese() -> Self

Chinese (Simplified) labels

Source

pub const fn japanese() -> Self

Japanese labels

Source

pub const fn spanish() -> Self

Spanish labels

Source

pub fn for_language(code: &str) -> Self

Get labels for a language code (ISO 639-1)

Trait Implementations§

Source§

impl Clone for DiagramLabels

Source§

fn clone(&self) -> DiagramLabels

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DiagramLabels

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for DiagramLabels

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.