# InlineEditBehavior

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

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

```rust
struct InlineEditBehavior
```

Edits in place: a display control is swapped for an edit control when the display control is
double tapped (or the associated control, with
`edit_on_associated_object_double_tapped`) or
the edit key is pressed on it, and swapped back when the accept or the cancel key is pressed in
the edit control or it loses the focus.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L20)

## Members

- [`TYPE`](#assoc_const-type)
- [`to_ref`](#function-to_ref)
- [`edit_control_property`](#function-edit_control_property)
- [`display_control_property`](#function-display_control_property)
- [`edit_key_property`](#function-edit_key_property)
- [`accept_key_property`](#function-accept_key_property)
- [`cancel_key_property`](#function-cancel_key_property)
- [`edit_on_associated_object_double_tapped_property`](#function-edit_on_associated_object_double_tapped_property)
- [`construct`](#function-construct)
- [`new`](#function-new)
- [`edit_control`](#function-edit_control)
- [`set_edit_control`](#function-set_edit_control)
- [`display_control`](#function-display_control)
- [`set_display_control`](#function-set_display_control)
- [`edit_key`](#function-edit_key)
- [`set_edit_key`](#function-set_edit_key)
- [`accept_key`](#function-accept_key)
- [`set_accept_key`](#function-set_accept_key)
- [`cancel_key`](#function-cancel_key)
- [`set_cancel_key`](#function-set_cancel_key)
- [`edit_on_associated_object_double_tapped`](#function-edit_on_associated_object_double_tapped)
- [`set_edit_on_associated_object_double_tapped`](#function-set_edit_on_associated_object_double_tapped)

<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/control/inline_edit_behavior.rs#L35)

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

### to_ref

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

Returns a strong reference to this object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L35)

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

### edit_control_property

```rust
fn edit_control_property() -> &'static StyledProperty<Option<ElementRef<Control>>>
```

Identifies the `EditControl` property.

Deviation (DEVIATIONS.md, Behaviors): the behavior does not own the control, so the
value is an element reference.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

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

### display_control_property

```rust
fn display_control_property() -> &'static StyledProperty<Option<ElementRef<Control>>>
```

Identifies the `DisplayControl` property.

Deviation (DEVIATIONS.md, Behaviors): the behavior does not own the control, so the
value is an element reference.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

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

### edit_key_property

```rust
fn edit_key_property() -> &'static StyledProperty<Key>
```

Identifies the `EditKey` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

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

### accept_key_property

```rust
fn accept_key_property() -> &'static StyledProperty<Key>
```

Identifies the `AcceptKey` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

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

### cancel_key_property

```rust
fn cancel_key_property() -> &'static StyledProperty<Key>
```

Identifies the `CancelKey` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

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

### edit_on_associated_object_double_tapped_property

```rust
fn edit_on_associated_object_double_tapped_property() -> &'static StyledProperty<bool>
```

Identifies the `EditOnAssociatedObjectDoubleTapped` property.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L47)

<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/control/inline_edit_behavior.rs#L192)

<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/control/inline_edit_behavior.rs#L200)

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

### edit_control

```rust
fn edit_control(self: &Self) -> Option<Ref<Control>>
```

Gets or sets the control used for editing. Markup resolves a name given for it to the
named element. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L206)

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

### set_edit_control

```rust
fn set_edit_control(self: &Self, value: impl Into<Nullable<Control>>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L210)

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

### display_control

```rust
fn display_control(self: &Self) -> Option<Ref<Control>>
```

Gets or sets the control that displays the value. Markup resolves a name given for it to
the named element. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L216)

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

### set_display_control

```rust
fn set_display_control(self: &Self, value: impl Into<Nullable<Control>>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L220)

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

### edit_key

```rust
fn edit_key(self: &Self) -> Key
```

Gets or sets the key that begins the edit in the display control. This is a property of
the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L226)

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

### set_edit_key

```rust
fn set_edit_key(self: &Self, value: Key)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L230)

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

### accept_key

```rust
fn accept_key(self: &Self) -> Key
```

Gets or sets the key that accepts the edit. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L235)

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

### set_accept_key

```rust
fn set_accept_key(self: &Self, value: Key)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L239)

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

### cancel_key

```rust
fn cancel_key(self: &Self) -> Key
```

Gets or sets the key that cancels the edit. This is a property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L244)

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

### set_cancel_key

```rust
fn set_cancel_key(self: &Self, value: Key)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L248)

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

### edit_on_associated_object_double_tapped

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

Gets or sets whether a double tap on the associated control begins the edit. This is a
property of the object model.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L254)

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

### set_edit_on_associated_object_double_tapped

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



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Behaviors/FerroUI.Xaml.Interactions.Custom/control/inline_edit_behavior.rs#L258)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `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`
- [`StyledElementBehaviorImplExt`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-styledelementbehaviorimplext/)
- `Deref`
- [`Upcast<T>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`Upcast<InlineEditBehavior>`](/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/)
- [`FerroObjectImpl`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimpl/)
- [`StyledElementImpl`](/docs/0.5.0/api/ferroui-base/trait-styledelementimpl/)
- [`StyledElementBehaviorImpl`](/docs/0.5.0/api/ferroui-xaml-interactivity/trait-styledelementbehaviorimpl/)

## Availability

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