ControlPaneContent class Core

IOverlayContent implemented ONCE over a control tree. A pane derives, builds its tree in the constructor (ControlPaneContent.SetRoot), sets the start focus — and is done: pointer routing, focus-follows-click, hover, Tab traversal, key/typing routing, announcements, cursor shapes, ticking and the focus ring all come from the ControlHost. A pane that needs keys beyond its controls overrides ControlPaneContent.OnKeyFallback.

public abstract class ControlPaneContent : IOverlayContent
Namespace
ArionUI.Presentation.Controls
Package
ArionUI.Presentation · dotnet add package ArionUI.Presentation --prerelease
Implements
IOverlayContent

Constructors

ControlPaneContent

protected ControlPaneContent();

Properties

AccessibleDescription

public virtual string? AccessibleDescription { get; }

What a screen reader says when this pane OPENS ("Menü, 5 Einträge"). Null = the generic pane announcement. The self-drawn panes are invisible to assistive technology as pixels — this sentence is their whole existence there.

AccessibleParts

public IReadOnlyList<AccessiblePart>? AccessibleParts { get; }

The tree IS the structure assistive technology wants — the hosts' automation peers build the pane's child elements from this.

CaretRect

public virtual LogRect? CaretRect { get; }

The caret of the pane's focused text box as last drawn, in the coordinates the pane was placed in; null without one. The input method's candidate window hangs here.

ClosesOnOutsidePress

public virtual bool ClosesOnOutsidePress { get; }

Does a press OUTSIDE this pane dismiss it? False for a COMPANION pane that belongs to something still being edited: the date calendar must survive clicks in the grid, because those place the caret in the cell's text editor — it closes when the edit ends or a day is picked.

CornerRadius

public virtual double CornerRadius { get; }

Corner radius of this pane's card. The HOST needs it to shape the drop shadow around the pane (see PaneSurface.DrawElevation); the content uses the same value when it draws the card, so the two never mismatch.

FocusedControlId

public string? FocusedControlId { get; }

Id of the focused control — the observable focus seam for tests and, later, the automation peers.

Host

protected ControlHost Host { get; }

LastBounds

protected LogRect LastBounds { get; }

Placed bounds of the last render — controls live in absolute coordinates, local input converts through this (one place).

MinSize

public virtual LogSize MinSize { get; }

Smallest size a RESIZE (or a remembered size) may shrink this pane to. Contents with fixed right-aligned chrome (the column chooser's pin/aggregate/fx chips) override this so their icons can never be clipped off the right edge.

WantsFocus

public virtual bool WantsFocus { get; }

May this pane take the keyboard when it opens? False for a COMPANION pane that hangs off something still being typed in — the date calendar opens under a cell whose text editor stays live, so the date can be typed or picked; stealing focus there would kill the typing.

WantsTextInput

public virtual bool WantsTextInput { get; }

IME/text sink target — the host docks its text-input client here when true (same seam the grid's cell/filter editor uses).

WantsTick

public virtual bool WantsTick { get; }

True while the pane has a running animation (scroll glide, caret blink) — the floating surface keeps its frame tick alive while any pane wants it, then lets it idle.

Methods

AccessiblePartOf

public AccessiblePart? AccessiblePartOf(string id);

ONE part by id, read live. A peer is asked about ten properties per part, and answering each of them by building the whole list walked the control tree once per question. Default: pick it out of the list, which is right for a pane whose parts are a fixed handful.

AccessibleRangeOf

public virtual AccessibleRange? AccessibleRangeOf(string id);

The range of a range part (UIA RangeValue); null when the part has none.

AccessibleToggleStateOf

public virtual bool? AccessibleToggleStateOf(string id);

The checked state of a toggle part (UIA Toggle); null when it does not toggle.

AccessibleValueOf

public virtual string? AccessibleValueOf(string id);

The text of a text part (UIA Value); null when the part carries no value.

AttachAnnouncer

public void AttachAnnouncer(Action<string> announce);

The host hands the pane a voice: everything passed to announce is spoken through the grid's screen-reader channels (highlight moves, state changes). Default: mute, for panes that say nothing.

CursorAt

public GridCursor CursorAt(LogPoint local);

The pointer shape this content asks for at a LOCAL point — Hand over its buttons/chips/rows. Default: the plain arrow. Purely visual; hit-testing for input stays in the OnPointer* handlers.

DrawBackground

protected virtual void DrawBackground(IRenderSurface s, LogRect b);

The pane's card behind the tree. Override for a different radius.

InvokeAccessiblePart

public virtual bool InvokeAccessiblePart(string id);

Act on a part by id as a click would (UIA Invoke). False when the part is unknown, disabled or has no action.

Measure

public abstract LogSize Measure(double maxWidth, double maxHeight);

Desired size given the space available (for placement/clamping).

MoveFocus

public virtual bool MoveFocus(bool reverse);

Move keyboard focus to the next or previous control inside this pane. Return true when a focus target changed; false lets Tab fall through.

OnKey

public virtual bool OnKey(ArionKey key, ArionModifiers mods);

Key press. Esc/Enter/arrows etc. Return true if handled.

OnKeyFallback

protected virtual bool OnKeyFallback(ArionKey key, ArionModifiers mods);

Keys no focused control claimed (a pane-wide shortcut). Default: none.

OnOutsidePress

public virtual void OnOutsidePress();

A press landed OUTSIDE this pane while it stayed open (only reachable for a pane with IOverlayContent.ClosesOnOutsidePress false). A MODELESS pane uses it to hand the keyboard back — the search bar stays up but stops swallowing keystrokes once you click into the grid.

OnPointerMoved

public void OnPointerMoved(LogPoint local, bool buttonDown);

OnPointerPressed

public virtual bool OnPointerPressed(LogPoint local, ArionModifiers mods, int clickCount = 1);

Pointer press in LOCAL coords. clickCount is 2 for a double-click and 3 for a triple-click, so a text field in a pane selects a word or everything exactly like the grid's own fields do (the grid gets it from InteractionController.OnMultiClick). Return true if handled.

OnPointerReleased

public void OnPointerReleased(LogPoint local);

OnTextInput

public virtual void OnTextInput(string text);

OnWheel

public virtual bool OnWheel(LogPoint local, double delta);

Wheel in LOCAL coords (long lists). Return true if handled.

RaiseInvalidated

protected void RaiseInvalidated();

Render

public virtual void Render(IRenderSurface s, LogRect b, OverlayFrameState state);

Paint into bounds (already placed + clamped). Panes without text input ignore state.

RequestClose

protected void RequestClose();

SetAccessibleRangeValueOf

public virtual bool SetAccessibleRangeValueOf(string id, double value);

Set the value of a range part (UIA RangeValue.SetValue). False when the part has no range.

SetAccessibleValueOf

public virtual bool SetAccessibleValueOf(string id, string value);

Replace the text of a text part (UIA Value.SetValue). False when the part carries no value.

SetRoot

protected void SetRoot(Control root, string? initialFocusId = null);

Tick

public virtual void Tick(double dtMs);

Advance animations by dtMs milliseconds (called once per frame by the hosting surface while IOverlayContent.WantsTick).

UseClipboard

public virtual void UseClipboard(IClipboardText clipboard);

The host hands the pane the platform's clipboard for its text boxes. Default: the pane copies and pastes nothing.

Events

CloseRequested

public event Action? CloseRequested;

Raised when the pane wants to close itself (Enter/apply/pick).

Invalidated

public event Action? Invalidated;

Raised when the pane needs a repaint (hover, caret, content change).