# PretextFontDescriptor

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-pretext-contracts/struct-pretextfontdescriptor/

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

```rust
struct PretextFontDescriptor
```

The CSS-like font subset accepted by text preparation backends.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L3)

## Members

- [`size`](#struct_field-size)
- [`primary_family`](#struct_field-primary_family)
- [`weight`](#struct_field-weight)
- [`italic`](#struct_field-italic)
- [`new`](#function-new)

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

### size

```rust
size: f64
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L4)

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

### primary_family

```rust
primary_family: String
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L5)

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

### weight

```rust
weight: i32
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L6)

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

### italic

```rust
italic: bool
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L7)

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

### new

```rust
fn new(size: f64, primary_family: impl Into<String>, weight: i32, italic: bool) -> Self
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Pretext/FerroUI.Pretext.Contracts/pretext_font_descriptor.rs#L17)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- `ToOwned`
- `Clone`
- `Debug`
- `StructuralPartialEq`
- `PartialEq`
- `Default`

## Availability

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