Vixen
dd8b0a81
csharp
public sealed class ColorStrip

A strip that a drag moves along: the hue band, or the alpha band.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

⚠ The keyboard came before the role, and that order is the whole of #420. This was pointer-only and roleless, and the two facts belonged together: a screen reader told about a hue band that only a mouse can move announces a control the user cannot operate, which is strictly worse than announcing nothing — it converts "not available to me" into "available and does nothing", a state a screen-reader user has no way to diagnose. So the arrows landed first and NativeRole second, in one change, and neither is correct alone.

Fields and properties (9)

  • public const float KeyStep

    How far one arrow key moves the marker along the band.

  • protected override string TagName

    The element name this type answers to when a caller does not choose one.

  • protected override bool AcceptsFocus

    Whether the focus can rest on this kind of control at all.

  • protected override AccessibleRole NativeRole
  • protected override string? NativeAccessibleName
  • protected override string? NativeAccessibleValue
  • public ColorChannel Channel

    Which one it is.

  • public ColorPicker? Owner

    The picker it belongs to.

  • public float Fraction

    Where the marker is, from zero at the left to one at the right.

Events (1)

  • public Action<ColorStrip, float>? Moved

    Raised while it is being dragged.

Methods (2)

  • protected override void OnCreated()

    Builds whatever this element is made of, once, as it joins a document.

  • protected override void OnDraw(DrawContext context)

    Draws whatever this element is, beyond what a stylesheet can describe.

Used by (5)

  • ColorFieldVixen.Ui.Controls.Advanced
  • ColorPickerVixen.Ui.Controls.Advanced
  • ColorPickerKeyboardTestsVixen.Ui.Controls.Advanced.Tests
  • ColorSwatchVixen.Ui.Controls.Advanced
  • GradientBarVixen.Ui.Controls.Advanced