# ScrollViewerOffsetBehavior

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-xaml-interactions-custom/struct-scrollvieweroffsetbehavior/

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

```rust
struct ScrollViewerOffsetBehavior
```

Sets the `offset` of the associated `ScrollViewer`.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L15)

## Members

- [`TYPE`](#assoc_const-type)
- [`to_ref`](#function-to_ref)
- [`horizontal_offset_property`](#function-horizontal_offset_property)
- [`vertical_offset_property`](#function-vertical_offset_property)
- [`construct`](#function-construct)
- [`new`](#function-new)
- [`horizontal_offset`](#function-horizontal_offset)
- [`set_horizontal_offset`](#function-set_horizontal_offset)
- [`vertical_offset`](#function-vertical_offset)
- [`set_vertical_offset`](#function-set_vertical_offset)

<a id="assoc_const-type"></a>

### TYPE

```rust
const TYPE: &'static $crate::TypeInfo
```

The runtime type of this class.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L19)

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

### to_ref

```rust
fn to_ref(self: &Self) -> $crate::Ref<ScrollViewerOffsetBehavior>
```

Returns a strong reference to this object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L19)

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

### horizontal_offset_property

```rust
fn horizontal_offset_property() -> &'static StyledProperty<Option<f64>>
```

Identifies the `HorizontalOffset` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L27)

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

### vertical_offset_property

```rust
fn vertical_offset_property() -> &'static StyledProperty<Option<f64>>
```

Identifies the `VerticalOffset` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L27)

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

### construct

```rust
fn construct() -> Self
```

Creates the class data; see `ferroui_base::FerroObject::construct`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L66)

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

### new

```rust
fn new() -> Ref<Self>
```

Creates a behavior.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L71)

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

### horizontal_offset

```rust
fn horizontal_offset(self: &Self) -> Option<f64>
```

Gets or sets the horizontal offset value. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L76)

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

### set_horizontal_offset

```rust
fn set_horizontal_offset(self: &Self, value: Option<f64>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L80)

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

### vertical_offset

```rust
fn vertical_offset(self: &Self) -> Option<f64>
```

Gets or sets the vertical offset value. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L85)

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

### set_vertical_offset

```rust
fn set_vertical_offset(self: &Self, value: Option<f64>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/scroll_viewer/scroll_viewer_offset_behavior.rs#L89)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- [`AttachedToVisualTreeBehaviorImplExt`](/docs/0.5.0/api/ferroui-xaml-interactions-custom/trait-attachedtovisualtreebehaviorimplext/)
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- [`Receiver`](/docs/0.5.0/api/ferroui-system/task/oneshot/struct-receiver/)
- `Any`
- [`FerroObjectImplExt`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimplext/)
- [`StyledElementImplExt`](/docs/0.5.0/api/ferroui-base/trait-styledelementimplext/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- [`DisposingBehaviorImplExt`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-disposingbehaviorimplext/)
- [`StyledElementBehaviorImplExt`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-styledelementbehaviorimplext/)
- `Deref`
- [`Upcast<T>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`Upcast<ScrollViewerOffsetBehavior>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`StaticType`](/docs/0.5.0/api/ferroui-base/trait-statictype/)
- [`ObjectType`](/docs/0.5.0/api/ferroui-base/trait-objecttype/)
- [`Subclassable<T>`](/docs/0.5.0/api/ferroui-base/trait-subclassable/)
- [`DefaultConstructible`](/docs/0.5.0/api/ferroui-base/trait-defaultconstructible/)
- [`StyledElementImpl`](/docs/0.5.0/api/ferroui-base/trait-styledelementimpl/)
- [`StyledElementBehaviorImpl`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-styledelementbehaviorimpl/)
- [`DisposingBehaviorImpl`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-disposingbehaviorimpl/)
- [`FerroObjectImpl`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimpl/)
- [`AttachedToVisualTreeBehaviorImpl`](/docs/0.5.0/api/ferroui-xaml-interactions-custom/trait-attachedtovisualtreebehaviorimpl/)

## Availability

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