Skip to main content

Crate ferroui_controls_inking

Crate ferroui_controls_inking 

Source
Expand description

ferroui-controls-inking

The inking controls and services of WinUI on FerroUI: InkCanvas with its InkPresenter, the stroke services (InkStroke, InkStrokeBuilder, InkStrokeContainer, erasing and selection), the ruler and protractor stencils, custom drying through InkSynchronizer, InkToolbar with its buttons and pen configuration, the portable FERROINK format and the clipboard. On Windows, WindowsInkServices connects a stroke container to the ink services of the system (ISF and GIF with ISF, the system ink clipboard, handwriting recognition).

The toolbar’s WinUI theme is part of this crate, not of the WinUI theme: an application that uses the toolbar with the WinUI theme includes its styles,

<StyleInclude Source="ferres://FerroUI.Controls.Inking/Themes/WinUI.xaml" />

The theme documents are compiled by the build of the crate (build.rs); register_types registers the types of the crate and the loader table of its compiled markup. See docs/porting/winui-inking.md for the source mappings and the limits of interoperability.

Structs§

CoreInputDeviceTypes
Devices admitted to the inking pipeline. Pen is the default.
InkCanvas
A pressure-sensitive ink surface that renders entirely through FerroUI.
InkCanvasAutomationPeer
Pane peer using FerroUI transforms and ancestor clips, independent of ink content.
InkClipboard
Shares portable ink between FerroUI applications on any clipboard backend. Use the clipboard of the owning TopLevel; no global clipboard is assumed. Native Windows Ink clipboard interoperability is supplied separately by IInkPlatformServices, because its representation and API are different.
InkDrawingAttributes
A value snapshot. Changing presenter defaults never mutates completed ink. size describes the nib at full pressure, in device-independent pixels.
InkInputConfiguration
InkInputProcessingConfiguration
InkPersistenceLimits
Codec resource limits apply before allocation and cumulatively across records. The defaults permit a 64 MiB payload, 100,000 strokes, 65,536 samples per stroke and 1,000,000 samples in total.
InkPoint
An immutable device sample. Positions are in device-independent pixels, pressure is normalized to 0..=1, angles are degrees and timestamps are monotonically increasing microseconds supplied by the input adapter.
InkPointerEventArgs
Device-independent input; coordinates are in the canvas’s local DIPs. handled is shared through synchronous callback delivery.
InkPresenter
UI-thread ink coordinator. Services and input callbacks are stable, synchronous FerroUI objects; geometry and persistence are portable Rust implementations.
InkPresenterProtractor
A movable circular guide with a measured arc readout. The transform uses the bounding circle’s top-left corner; its local center is (radius,radius).
InkPresenterRuler
A movable straightedge. Its transform uses the local top-left corner.
InkStroke
One editable stroke identity with immutable raw device samples. Attributes are copied on construction. Geometry is cached until attributes or the point transform change; selection does not invalidate tessellation.
InkStrokeBuilder
Stateful builder with separate Begin/Append/End and snapshot APIs. End consumes the pending input only after a stroke has been validated.
InkStrokeContainer
UI-thread-affine stroke collection with stable identities and notifying mutation. No collection borrow is held while user callbacks are invoked.
InkStrokeInput
Stable presenter-owned input event service, with a weak back-pointer.
InkStrokesCollectedEventArgs
InkStrokesErasedEventArgs
InkSynchronizer
Transactional handoff from presenter-owned wet ink to application-owned dry ink.
InkToolbar
A functional inking toolbar using FerroUI’s panel layout, control templates and input routing.
InkToolbarAutomationPeer
InkToolbarBallpointPenButton
InkToolbarCustomPen
Custom pen construction uses a real virtual dispatch, so subclasses can define the nib.
InkToolbarCustomPenButton
InkToolbarCustomPenVTable
The virtual table of the class.
InkToolbarCustomToggleButton
InkToolbarCustomToolButton
InkToolbarEraserButton
InkToolbarFlyoutItem
InkToolbarFlyoutItemAutomationPeer
InkToolbarHighlighterButton
InkToolbarIsStencilButtonCheckedChangedEventArgs
InkToolbarMenuButton
InkToolbarMenuButtonAutomationPeer
InkToolbarPenButton
Base pen tool. Palettes are observable handles owned independently by each pen.
InkToolbarPenButtonVTable
The virtual table of the class.
InkToolbarPenConfigurationControl
InkToolbarPencilButton
InkToolbarRulerButton
InkToolbarStencilButton
InkToolbarStrokeWidthSlider
InkToolbarStrokeWidthSliderAutomationPeer
InkToolbarToggleButton
InkToolbarToolButton
A mutually exclusive toolbar tool; inherits keyboard and selection automation from RadioButton.
InkToolbarToolButtonAutomationPeer
InkUnprocessedInput

Enums§

InkDrawingAttributesKind
InkError
Validation and persistence failures in the portable ink engine.
InkHighContrastAdjustment
InkInputProcessingMode
InkInputRightDragAction
InkPersistenceFormat
Persisted representation. The portable format preserves FerroUI telemetry; the other two formats use a platform service with genuine ISF support.
InkPointerPhase
InkPresenterPredefinedConfiguration
InkPresenterStencilKind
InkToolbarButtonFlyoutPlacement
InkToolbarFlyoutItemKind
InkToolbarInitialControls
InkToolbarMenuKind
InkToolbarStencilKind
InkToolbarToggle
InkToolbarTool
PenTipShape

Constants§

INK_MIME_TYPE

Statics§

ASSEMBLY
What this crate states about itself for markup: its assembly name and the namespace the XML namespace of the framework maps to.

Traits§

IInkPlatformServices
Optional OS interoperability. The native Windows implementation uses the Windows ink engine for ISF, embedded ISF/GIF and the system ink clipboard. Core drawing, collection editing and portable persistence require no service.
IInkPresenterStencil
Shared programmatic contract of the two canvas stencil services.
InkToolbarCustomPenImpl
The overridable members introduced by the class.
InkToolbarCustomPenImplExt
Access to the base implementations of the overridable members.
InkToolbarPenButtonImpl
The overridable members introduced by the class.
InkToolbarPenButtonImplExt
Access to the base implementations of the overridable members.

Functions§

register_types
Registers the namespaces, the types, the assembly, the markup metadata and the compiled markup of this crate (and of the crates it is built on), and with the feature document-assets the theme documents as assets. Cheap and idempotent.

Type Aliases§

InkServiceFuture