# ColorViewImpl

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls-color-picker/trait-colorviewimpl/

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

```rust
trait ColorViewImpl: TemplatedControlImpl + $crate::Upcast<ColorView>
```

The overridable members introduced by the class.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.ColorPicker/color_view/color_view.rs#L36)

## Members

- [`validate_selection`](#function-validate_selection)
- [`on_color_changed`](#function-on_color_changed)
- [`on_coerce_color`](#function-on_coerce_color)
- [`on_coerce_hsv_color`](#function-on_coerce_hsv_color)

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

### validate_selection

```rust
fn validate_selection(this: &Self)
```

Obsolete. No-op. This method is no longer used and will be removed in a future
release (the necessary validation is now handled by the tab control).

This method does nothing and should not be overridden or relied upon.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.ColorPicker/color_view/color_view.rs#L36)

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

### on_color_changed

```rust
fn on_color_changed(this: &Self, e: &ColorChangedEventArgs)
```

Raises the color changed event.

`e` defines the old/new colors.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.ColorPicker/color_view/color_view.rs#L36)

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

### on_coerce_color

```rust
fn on_coerce_color(this: &Self, value: Color) -> Color
```

Called when the `Color` property has to be coerced; returns the
coerced value.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.ColorPicker/color_view/color_view.rs#L36)

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

### on_coerce_hsv_color

```rust
fn on_coerce_hsv_color(this: &Self, value: HsvColor) -> HsvColor
```

Called when the `HsvColor` property has to be coerced; returns the
coerced value.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls.ColorPicker/color_view/color_view.rs#L36)

## Trait implementations

- [`ColorViewImpl`](/docs/0.5.0/api/ferroui-controls-color-picker/trait-colorviewimpl/)

## Availability

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