Struct designspace::Designspace[][src]

pub struct Designspace {
    pub format: f32,
    pub axes: Axes,
    pub sources: Sources,
    pub instances: Option<Instances>,
}
Expand description

A designspace object

Fields

format: f32

The format of this designspace file (we support 2 and 3)

axes: Axes

An axes element (contains individual axes)

sources: Sources

An sources element (contains individual sources)

instances: Option<Instances>

An instance element (optional, contains individual instances)

Implementations

Add information to a fonttools Font object (fvar and avar tables) expressed by this design space.

Returns a mapping between axis tags and their names

Returns the axis order. Requires the tags to be validated; will panic if they are not four-byte tags.

Returns the default master location in userspace coordinates

Returns the default master location in designspace coordinates

Returns the location of a given source object in design space coordinates

Converts a location to a tuple

Returns the Source object for the master at default axis coordinates, if one can be found

Normalizes a location between -1.0 and 1.0

Constructs a fonttools variation model for this designspace

Trait Implementations

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Casts the value.

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Casts the value.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Casts the value.

Should always be Self

Casts the value.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Casts the value.

Casts the value.