acdream/tests/AcDream.App.Tests/UI
Erik 41430420b3 feat(ui): importer carries dat justification (0x14/0x15) onto text widgets; drop character footer-title height hack
LayoutImporter.ReadState now reads Properties[0x14] (HorizontalJustification,
EnumBaseProperty: 0=Left, 1=Center, 3/5=Right) and Properties[0x15]
(VerticalJustification: 2=Top, 4=Bottom; else Center) into two new ElementInfo
fields HJustify/VJustify. Merge propagates them with the same non-default-wins
rule used for FontDid.

DatWidgetFactory.BuildText applies the resolved justify at build time:
HJustify=Center sets Centered=true, HJustify=Right sets RightAligned=true,
VJustify=Top/Bottom sets VerticalJustify. Controllers that FindElement and set
those properties afterward continue to override - backward-compat preserved.

UiText gains VerticalJustify (Top/Center/Bottom, default Center). The Centered
and RightAligned single-line paths call UiText.VOffset() for the Y coordinate,
so VJustify.Top renders text at y=Padding rather than the fixed (H-lh)/2 center.

CharacterStatController: footer title (0x1000024E, H=55 dat box) previously
used Height=18 + Anchors=None to prevent center-vertical overlap with line-1/2.
Diagnostic confirmed dat says HJustify=Center, VJustify=Center. The hack is
replaced with one minimal explicit override: VerticalJustify=Top on the
already-Centered element. Text now renders at top of the 55px box natively.
Centered=false and RightAligned=false hand-sets removed where dat supplies them.

Dat justify values (studio diagnostic, 2026-06-26):
  0x1000024E footer title: HJustify=Center, VJustify=Center
  0x10000235/0x10000243/0x10000245 value fields: HJustify=Right
  header name/heritage/pk/level: HJustify=Center

+13 tests: ElementReader Merge propagation; DatWidgetFactory BuildText
justify application + controller-override backward-compat; UiText VOffset.
696 passed, 0 failed.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-26 10:05:36 +02:00
..
Layout feat(ui): importer carries dat justification (0x14/0x15) onto text widgets; drop character footer-title height hack 2026-06-26 10:05:36 +02:00
ControlsIniTests.cs feat(D.2b): controls.ini stylesheet loader + apply title color 2026-06-14 17:31:55 +02:00
DatWidgetFactoryZOrderTests.cs fix(ui): #145 — importer honors ZLevel so the backdrop sits behind panels 2026-06-21 07:22:26 +02:00
DragDropSpineTests.cs feat(ui): D.5.3/B.2 — spine: drag-lift hook + ghost snapshot (full opacity) + drop-on-hit-only 2026-06-20 15:22:27 +02:00
IconComposerTests.cs fix(D.5.2): effect tint = per-pixel tile copy (surface ReplaceColor overload) 2026-06-18 10:21:33 +02:00
LayoutImporterMountTests.cs feat(ui): D.2b-B — sub-window mount (inheritor attaches base subtree) 2026-06-20 22:36:20 +02:00
MarkupDocumentTests.cs feat(D.2b): retail 3-slice vital bars + headless mockup verifier 2026-06-14 21:40:11 +02:00
UiButtonTests.cs feat(D.2b): UiButton (Type 1) — Send + Max/Min as generic buttons (widget-generalization Task 3) 2026-06-16 17:07:58 +02:00
UiCollapsibleFrameTests.cs feat(ui): D.2b — toolbar collapse-to-one-row (bottom-edge snap resize hides/shows row 2) 2026-06-20 18:33:35 +02:00
UiDatFontTests.cs feat(D.2b): retail dat-font (Font 0x40000000) for vitals numbers 2026-06-14 23:02:35 +02:00
UiFieldTests.cs feat(D.2b): UiField (Type 3) — editable input as a generic field; remove the stray Type-12 input placeholder (widget-generalization Task 6) 2026-06-16 17:48:51 +02:00
UiItemListGridTests.cs feat(ui): D.2b-B — UiItemList N-cell grid mode 2026-06-20 22:34:30 +02:00
UiItemListScrollTests.cs fix(ui): D.2b inventory finish — grid cells exempt from the anchor pass 2026-06-21 20:51:08 +02:00
UiItemListTests.cs feat(ui): D.2b empty-slot art — UiItemList.CellEmptySprite stamps cells 2026-06-22 11:03:19 +02:00
UiItemSlotTests.cs feat(D.2b): per-container capacity bar on inventory cells 2026-06-22 15:54:54 +02:00
UiMenuTests.cs fix(D.2b): UiMenu — controller owns Selected (review fix for Task 4) 2026-06-16 17:27:30 +02:00
UiMeterTests.cs feat(D.2b): UiMeter vital bar + fill-geometry tests 2026-06-14 16:38:07 +02:00
UiMeterVerticalTests.cs feat(ui): D.2b-B — UiMeter vertical fill (burden bar, retail m_eDirection 2/4) 2026-06-21 08:58:37 +02:00
UiNineSlicePanelTests.cs feat(D.2b): UiNineSlicePanel — 8-piece retail window frame + geometry test 2026-06-14 16:36:11 +02:00
UiRootInputTests.cs fix(D.2b): Slice 2 — buttons inside a whole-window-Draggable frame get their Click 2026-06-23 10:08:59 +02:00
UiScrollableTests.cs feat(D.2b): UiScrollable — pixel scroll model (UIElement_Scrollable port) 2026-06-15 22:19:29 +02:00
UiScrollbarTests.cs feat(D.2b): UiScrollbar (Type 11) — promote the generic chat scrollbar (widget-generalization Task 2) 2026-06-16 17:02:49 +02:00
UiTextDatFontTests.cs feat(D.2b): UiText (Type 12) -- generic text + Type-12 flip; transcript factory-built (widget-generalization Task 5) 2026-06-16 17:39:02 +02:00
UiTextTests.cs feat(ui): importer carries dat justification (0x14/0x15) onto text widgets; drop character footer-title height hack 2026-06-26 10:05:36 +02:00