Crate zng_unit

source ·
Expand description

Base unit types.

§Crate

This crate is part of the zng project.

Re-exports§

  • pub use euclid;

Structs§

  • Angle in degrees.
  • Angle in gradians.
  • Angle in radians.
  • Angle in turns (complete rotations).
  • A length in bytes.
  • Ellipses that define the radius of the four corners of a 2D box.
  • Device independent pixel.
  • Comparable key that represents the absolute distance between two pixel points.
  • Normalized multiplication factor.
  • Multiplication factor in percentage (0%-100%).
  • Device pixel.
  • RGB + alpha.
  • Color functions argument conversion helper.
  • A group of 2D side offsets, which correspond to top/right/bottom/left for borders, padding, and margins in CSS, optionally tagged with a unit.

Enums§

Constants§

  • Minimal difference between values in around the 0.0..=1.0 scale.
  • Minimal difference between values in around the 1.0..=100.0 scale.

Traits§

Functions§

Type Aliases§