# NumericRange

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls-charts/struct-numericrange/

**struct** · [`ferroui-controls-charts`](/docs/0.5.0/api/ferroui-controls-charts/) · v0.5.0

```rust
struct NumericRange
```

Resolved layout data of a numeric axis. This is a value snapshot, separate
from the notifying axis object and safe to use during scene construction.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L169)

## Members

- [`minimum`](#struct_field-minimum)
- [`maximum`](#struct_field-maximum)
- [`spacing`](#struct_field-spacing)
- [`MAX_TICKS`](#assoc_const-max_ticks)
- [`from_values`](#function-from_values)
- [`normalize`](#function-normalize)
- [`ticks`](#function-ticks)

<a id="struct_field-minimum"></a>

### minimum

```rust
minimum: f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L170)

<a id="struct_field-maximum"></a>

### maximum

```rust
maximum: f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L171)

<a id="struct_field-spacing"></a>

### spacing

```rust
spacing: f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L172)

<a id="assoc_const-max_ticks"></a>

### MAX_TICKS

```rust
const MAX_TICKS: usize
```

The maximum number of ticks emitted by `Self::ticks`. Explicit
subpixel spacing is sampled at an integer multiple of its interval.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L178)

<a id="function-from_values"></a>

### from_values

```rust
fn from_values(values: &[f64], minimum: Option<f64>, maximum: Option<f64>, spacing: Option<f64>, target_tick_count: usize) -> Self
```

Resolves bounds without requiring a property-system object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L181)

<a id="function-normalize"></a>

### normalize

```rust
fn normalize(self: &Self, value: f64) -> f64
```

Maps a value to axis coordinates without clipping to the axis domain.
Scaled subtraction avoids overflow at opposite floating-point extrema.
A finite value whose coordinate exceeds the representable range
saturates to `-f64::MAX` or `f64::MAX`, retaining its side of the domain
for line clipping. Non-finite sample values remain non-finite.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L266)

<a id="function-ticks"></a>

### ticks

```rust
fn ticks(self: &Self) -> Vec<f64>
```

Finite, strictly increasing major ticks, aligned to multiples of the
chosen spacing. Work and allocation remain bounded for tiny spacing.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.Charts/linear_axis.rs#L296)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- `ToOwned`
- [`PropertyValue`](/docs/0.5.0/api/ferroui-base/trait-propertyvalue/)
- [`AnyValue`](/docs/0.5.0/api/ferroui-base/trait-anyvalue/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- `Clone`
- `Copy`
- `Debug`
- `StructuralPartialEq`
- `PartialEq`

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
