# FontCollectionKey

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-base/media/fonts/struct-fontcollectionkey/

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

```rust
struct FontCollectionKey
```

Represents a unique key for identifying a font within a font collection
based on style, weight and stretch.

Keys order by style, then weight, then stretch (numeric values).

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/fonts/font_collection_key.rs#L10)

## Members

- [`style`](#struct_field-style)
- [`weight`](#struct_field-weight)
- [`stretch`](#struct_field-stretch)
- [`new`](#function-new)

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

### style

```rust
style: crate::media::FontStyle
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/fonts/font_collection_key.rs#L11)

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

### weight

```rust
weight: crate::media::FontWeight
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/fonts/font_collection_key.rs#L12)

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

### stretch

```rust
stretch: crate::media::FontStretch
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/fonts/font_collection_key.rs#L13)

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

### new

```rust
const fn new(style: FontStyle, weight: FontWeight, stretch: FontStretch) -> Self
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/fonts/font_collection_key.rs#L17)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- [`ResourceKeyObject`](/docs/0.5.0/api/ferroui-base/controls/trait-resourcekeyobject/)
- [`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/)
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- `ToOwned`
- `ErasedDestructor`
- `IntoEither`
- `Clone`
- `Copy`
- `Debug`
- `StructuralPartialEq`
- `PartialEq`
- `Eq`
- `Hash`
- `Ord`
- `PartialOrd`
- `From<&Typeface>`
- `From<&GlyphTypeface>`
- `From<&dyn IPlatformTypeface>`

## Availability

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