Expand description
ferroui-xaml-interactions-draggable
Behaviors that drag elements in place, ported from the Xaml.Behaviors.Interactions.Draggable
project of Xaml.Behaviors (see NOTICE.md):
CanvasDragBehavior: moves a child of a canvas with the pointer;GridDragBehavior: swaps the cells of a child of a grid with the child under the pointer;ItemDragBehaviorandListReorderDragBehavior: reorder the items of an items control, the second with a placeholder at the insertion point;MouseDragElementBehaviorandMultiMouseDragElementBehavior: move one or several controls by a translation;AutoScrollDuringDragBehavior: scrolls a scroll viewer while the pointer is dragged near its edges;SelectionAdorner: the corner handles shown over a dragged element.
The styles of the reference (Styles.xaml) make tab controls, list boxes, canvases and grids
with the class draggable draggable; the build of the crate compiles them, and an application
includes them with
<StyleInclude Source="ferres://FerroUI.Xaml.Interactions.Draggable/Styles.xaml" />.
The namespace of the crate is FerroUI.Xaml.Interactions.Draggable, mapped into the default
XML namespace of the framework: documents name its types without a prefix once
register_types ran.
Structs§
- Auto
Scroll During Drag Behavior - Automatically scrolls the associated
ScrollViewerwhen the pointer is dragged near its edges. - Canvas
Drag Behavior - Enables dragging of child controls within a
Canvas: the associated control follows the pointer by itsCanvas.LeftandCanvas.Top. - Grid
Drag Behavior - Allows dragging of grid child controls with optional layout copying: the associated control
swaps its column, row and spans (as the
copy_*properties select) with the child of theGrid(or the container of theItemsControl) the pointer is over. - Item
Drag Behavior - Allows dragging items within an
ItemsControl. - List
Reorder Drag Behavior - Allows reordering of items inside an
ItemsControlwhile displaying a placeholder at the insertion point. - Mouse
Drag Element Behavior - Enables dragging of a control with the mouse using a
TranslateTransform. - Multi
Mouse Drag Element Behavior - Enables dragging of multiple controls with the mouse using
TranslateTransforms: the associated control and thetarget_controlsmove together. - Selection
Adorner - Simple adorner used to show selection rectangles while dragging: four handles at the corners of the adorned element.
Statics§
- ASSEMBLY
- What this crate states about itself for markup: its assembly name and the namespace the XML namespace of the framework maps to.
Functions§
- register_
types - Registers the namespace, the types, the assembly and the compiled markup of this crate (and of
the crates it is built on), and with the feature
document-assetsthe styles document as an asset. Cheap and idempotent.