# TextBlockProps

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-view/generated/builders/trait-textblockprops/

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

```rust
trait TextBlockProps: ElementBuilder
```

The properties and routed events of `TextBlock`.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8340)

## Members

- [`background`](#function-background)
- [`padding`](#function-padding)
- [`font_family`](#function-font_family)
- [`font_size`](#function-font_size)
- [`font_style`](#function-font_style)
- [`font_weight`](#function-font_weight)
- [`font_stretch`](#function-font_stretch)
- [`foreground`](#function-foreground)
- [`baseline_offset`](#function-baseline_offset)
- [`text_line_bounds`](#function-text_line_bounds)
- [`layout_rounding_placement`](#function-layout_rounding_placement)
- [`line_height`](#function-line_height)
- [`line_spacing`](#function-line_spacing)
- [`letter_spacing`](#function-letter_spacing)
- [`max_lines`](#function-max_lines)
- [`text`](#function-text)
- [`text_alignment`](#function-text_alignment)
- [`text_wrapping`](#function-text_wrapping)
- [`text_trimming`](#function-text_trimming)
- [`text_decorations`](#function-text_decorations)
- [`font_features`](#function-font_features)
- [`inlines`](#function-inlines)

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

### background

```rust
fn background<M>(self: Self, value: impl IntoProp<Option<std::rc::Rc<dyn ferroui_base::media::IBrush>>, M>) -> Self
```

Sets `TextBlock::background_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8342)

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

### padding

```rust
fn padding<M>(self: Self, value: impl IntoProp<ferroui_base::Thickness, M>) -> Self
```

Sets `TextBlock::padding_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8347)

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

### font_family

```rust
fn font_family<M>(self: Self, value: impl IntoProp<ferroui_base::media::FontFamily, M>) -> Self
```

Sets `TextBlock::font_family_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8352)

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

### font_size

```rust
fn font_size<M>(self: Self, value: impl IntoProp<f64, M>) -> Self
```

Sets `TextBlock::font_size_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8357)

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

### font_style

```rust
fn font_style<M>(self: Self, value: impl IntoProp<ferroui_base::media::FontStyle, M>) -> Self
```

Sets `TextBlock::font_style_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8362)

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

### font_weight

```rust
fn font_weight<M>(self: Self, value: impl IntoProp<ferroui_base::media::FontWeight, M>) -> Self
```

Sets `TextBlock::font_weight_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8367)

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

### font_stretch

```rust
fn font_stretch<M>(self: Self, value: impl IntoProp<ferroui_base::media::FontStretch, M>) -> Self
```

Sets `TextBlock::font_stretch_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8372)

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

### foreground

```rust
fn foreground<M>(self: Self, value: impl IntoProp<Option<std::rc::Rc<dyn ferroui_base::media::IBrush>>, M>) -> Self
```

Sets `TextBlock::foreground_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8377)

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

### baseline_offset

```rust
fn baseline_offset<M>(self: Self, value: impl IntoProp<f64, M>) -> Self
```

Sets `TextBlock::baseline_offset_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8382)

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

### text_line_bounds

```rust
fn text_line_bounds<M>(self: Self, value: impl IntoProp<ferroui_base::media::TextLineBounds, M>) -> Self
```

Sets `TextBlock::text_line_bounds_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8387)

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

### layout_rounding_placement

```rust
fn layout_rounding_placement<M>(self: Self, value: impl IntoProp<ferroui_controls::TextLayoutRoundingPlacement, M>) -> Self
```

Sets `TextBlock::layout_rounding_placement_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8392)

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

### line_height

```rust
fn line_height<M>(self: Self, value: impl IntoProp<f64, M>) -> Self
```

Sets `TextBlock::line_height_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8397)

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

### line_spacing

```rust
fn line_spacing<M>(self: Self, value: impl IntoProp<f64, M>) -> Self
```

Sets `TextBlock::line_spacing_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8402)

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

### letter_spacing

```rust
fn letter_spacing<M>(self: Self, value: impl IntoProp<f64, M>) -> Self
```

Sets `TextBlock::letter_spacing_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8407)

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

### max_lines

```rust
fn max_lines<M>(self: Self, value: impl IntoProp<i32, M>) -> Self
```

Sets `TextBlock::max_lines_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8412)

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

### text

```rust
fn text<M>(self: Self, value: impl IntoProp<Option<String>, M>) -> Self
```

Sets `TextBlock::text_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8417)

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

### text_alignment

```rust
fn text_alignment<M>(self: Self, value: impl IntoProp<ferroui_base::media::TextAlignment, M>) -> Self
```

Sets `TextBlock::text_alignment_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8422)

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

### text_wrapping

```rust
fn text_wrapping<M>(self: Self, value: impl IntoProp<ferroui_base::media::TextWrapping, M>) -> Self
```

Sets `TextBlock::text_wrapping_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8427)

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

### text_trimming

```rust
fn text_trimming<M>(self: Self, value: impl IntoProp<std::rc::Rc<dyn ferroui_base::media::TextTrimming>, M>) -> Self
```

Sets `TextBlock::text_trimming_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8432)

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

### text_decorations

```rust
fn text_decorations<M>(self: Self, value: impl IntoProp<Option<ferroui_base::media::TextDecorationCollection>, M>) -> Self
```

Sets `TextBlock::text_decorations_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8437)

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

### font_features

```rust
fn font_features<M>(self: Self, value: impl IntoProp<Option<ferroui_base::media::FontFeatureCollection>, M>) -> Self
```

Sets `TextBlock::font_features_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8442)

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

### inlines

```rust
fn inlines<M>(self: Self, value: impl IntoProp<Option<ferroui_controls::documents::InlineCollection>, M>) -> Self
```

Sets `TextBlock::inlines_property`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/generated/builders.rs#L8447)

## Trait implementations

- [`TextBlockProps`](/docs/0.5.0/api/ferroui-view/generated/builders/trait-textblockprops/)

## Availability

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