DatePickerNode
Namespace: Hex1b.Nodes
Assembly: Hex1b.dll
Render node for . Wraps a trigger and manages the multi-step picker state (year → month → calendar). Delegates layout, rendering, and focus traversal to the child button.
public sealed class DatePickerNode : Hex1bNodeInheritance
Object → Hex1bNode → DatePickerNode
Properties
Child
The child button node (trigger field).
Returns: Hex1bNode
public Hex1bNode? Child { get; set; }DateFormat
Format string for displaying the selected date.
Returns: String
public string? DateFormat { get; set; }DisplayMonth
The month (1-12) being viewed in the calendar step.
Returns: Int32
public int DisplayMonth { get; set; }DisplayYear
The year being viewed in the month/calendar steps.
Returns: Int32
public int DisplayYear { get; set; }HasAppliedInitialDate
Whether the initial date has been applied from the widget.
Returns: Boolean
public bool HasAppliedInitialDate { get; set; }IsFocusable
Returns true if this node can receive focus.
Returns: Boolean
public override bool IsFocusable { get; }SelectedDate
The currently selected date, or null if no date is selected.
Returns: Nullable<DateOnly>
public DateOnly? SelectedDate { get; set; }SourceWidget
The source widget that was reconciled into this node.
Returns: DatePickerWidget
public DatePickerWidget? SourceWidget { get; set; }Step
The current step in the picker flow.
Returns: PickerStep
public PickerStep Step { get; set; }YearFocusCellIndex
Cell index (0–11) to focus after a year page change, or null for default targeting. Cleared after each rebuild so it only applies once.
Returns: Nullable<Int32>
public int? YearFocusCellIndex { get; set; }YearPageStart
The first year shown on the current year grid page.
Returns: Int32
public int YearPageStart { get; set; }Methods
ArrangeCore(Rect)
Override this method to implement arranging logic for this node. The base implementation saves previous bounds, marks dirty on change, and sets bounds.
Parameters:
bounds(Rect):
protected override void ArrangeCore(Rect bounds)GetChildren()
Gets the direct children of this node for structural tree traversal. Container nodes should override this to return their children.
Returns: IEnumerable<Hex1bNode>
public override IEnumerable<Hex1bNode> GetChildren()GetDisplayText(string?)
Gets the display text for the trigger field.
Parameters:
placeholder(String):
Returns: String
public string GetDisplayText(string? placeholder)GetFocusableNodes()
Gets all focusable nodes in this subtree (including this node if focusable).
Returns: IEnumerable<Hex1bNode>
public override IEnumerable<Hex1bNode> GetFocusableNodes()GoBack()
Goes back one step. Returns false if already at the year step (caller should dismiss the popup).
Returns: Boolean
public bool GoBack()MeasureCore(Constraints)
Override this method to implement measuring logic for this node.
Parameters:
constraints(Constraints):
Returns: Size
protected override Size MeasureCore(Constraints constraints)PageYearsBackward()
Moves the year page backward by 12 years.
public void PageYearsBackward()PageYearsForward()
Moves the year page forward by 12 years.
public void PageYearsForward()Render(Hex1bRenderContext)
Renders the node to the given context.
Parameters:
context(Hex1bRenderContext):
public override void Render(Hex1bRenderContext context)ResetStep()
Resets the picker to the year step for the next popup open.
public void ResetStep()SelectMonth(int)
Advances from the month step to the calendar step.
Parameters:
month(Int32):
public void SelectMonth(int month)SelectYear(int)
Advances from the year step to the month step.
Parameters:
year(Int32):
public void SelectYear(int year)