# IScrollSnapPointsInfo

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls/primitives/trait-iscrollsnappointsinfo/

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

```rust
trait IScrollSnapPointsInfo
```

Describes snap point behaviour for objects that contain and present items.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L13)

## Members

- [`are_horizontal_snap_points_regular`](#function-are_horizontal_snap_points_regular)
- [`set_are_horizontal_snap_points_regular`](#function-set_are_horizontal_snap_points_regular)
- [`are_vertical_snap_points_regular`](#function-are_vertical_snap_points_regular)
- [`set_are_vertical_snap_points_regular`](#function-set_are_vertical_snap_points_regular)
- [`get_irregular_snap_points`](#function-get_irregular_snap_points)
- [`get_regular_snap_points`](#function-get_regular_snap_points)
- [`horizontal_snap_points_changed`](#function-horizontal_snap_points_changed)
- [`vertical_snap_points_changed`](#function-vertical_snap_points_changed)

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

### are_horizontal_snap_points_regular

```rust
fn are_horizontal_snap_points_regular(self: &Self) -> bool
```

Whether the horizontal snap points for the container are equidistant
from each other.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L16)

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

### set_are_horizontal_snap_points_regular

```rust
fn set_are_horizontal_snap_points_regular(self: &Self, value: bool)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L18)

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

### are_vertical_snap_points_regular

```rust
fn are_vertical_snap_points_regular(self: &Self) -> bool
```

Whether the vertical snap points for the container are equidistant
from each other.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L22)

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

### set_are_vertical_snap_points_regular

```rust
fn set_are_vertical_snap_points_regular(self: &Self, value: bool)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L24)

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

### get_irregular_snap_points

```rust
fn get_irregular_snap_points(self: &Self, orientation: Orientation, snap_points_alignment: SnapPointsAlignment) -> Vec<f64>
```

Returns the set of distances between irregular snap points for a
specified orientation and alignment.

Returns the collection of snap point distances for the provided
orientation and alignment; an empty collection when no snap points are
present.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L32)

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

### get_regular_snap_points

```rust
fn get_regular_snap_points(self: &Self, orientation: Orientation, snap_points_alignment: SnapPointsAlignment) -> (f64, f64)
```

Gets the distance between regular snap points for a specified
orientation and alignment.

Returns the distance between the equidistant snap points (0 when no
snap points are present) and the offset of the first snap point.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L43)

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

### horizontal_snap_points_changed

```rust
fn horizontal_snap_points_changed(self: &Self, handler: SnapPointsChangedHandler) -> Rc<dyn IDisposable>
```

Occurs when the measurements for horizontal snap points change.

Disposing the returned handle removes the handler.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L52)

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

### vertical_snap_points_changed

```rust
fn vertical_snap_points_changed(self: &Self, handler: SnapPointsChangedHandler) -> Rc<dyn IDisposable>
```

Occurs when the measurements for vertical snap points change.

Disposing the returned handle removes the handler.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/primitives/i_scroll_snap_points_info.rs#L57)

## Trait implementations

- [`IScrollSnapPointsInfo`](/docs/0.5.0/api/ferroui-controls/primitives/trait-iscrollsnappointsinfo/)

## Availability

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