From 0cd0a289427772cfd6d19efb2c873b721ee0e96a Mon Sep 17 00:00:00 2001 From: Sam Date: Sat, 29 Aug 2026 17:22:27 +0700 Subject: [PATCH] edit boxes take focus the way 1.12 does, and the stable shows its pets MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - the caret was a wedge in the line: it sat in flow, four units wide, so focusing a login box shoved its text right by one caret and a caret parked mid-word opened a gap; it is a zero-width seam now with the bar drawn as an overlay (a 0×26 seam and a 5×26 bar at the same x, off a node probe), the way the reference anchors its caret quad over the FontString; a blurred box collapses its selection so only the box holding the keyboard shows one; and a dialog answers only keys pressed while it was already on screen — ENTER on an empty form used to open the error dialog and close it in the same frame - `autoFocus` defaults ON in the reference (the ctor leaves flags = 1, and every one of the ten `autoFocus` attributes in the shipped chain is an opt-out), showing an autoFocus box focuses it after its `OnShow`, and hiding the focused box releases the keyboard — the "never focuses on show" note we had transcribed came from a `call`-only census that missed a tail `jmp`; the loader's flag loop could only ever turn a flag on, so `autoFocus="false"` was a no-op, fixed before the default flipped or it would have grabbed exactly the ten boxes the reference exempts; and the EditBox does fire generic `OnChar` with the spliced string, on every typed or pasted character and never on `SetText` - the stable master's portrait was a black disc (its session was missing from the `"npc"` token chain — the third window to ship that way, so the test is now exhaustive over every `impl NpcSession` and names the one you forgot) and its model pane draws the selected pet: a stabled pet is a database row with no world entity, so a `PortraitStandIn(display_id)` — an entity that exists only to be mirrored — feeds the existing booth code unchanged; plus the registrar's two service rows were hidden by an inherited attribute, a charter's tooltip carries the guild name and master on line 3, and the Help window drops three strings pointing at a company that stopped answering Co-Authored-By: Claude Fable 5 --- .../assets/ui/GuildRegistrarFrame.xml | 13 +- crates/benilla-app/assets/ui/HelpFrame.xml | 28 ++ crates/benilla-app/assets/ui/PetStable.xml | 30 +- crates/benilla-app/src/capture/fixtures.rs | 2 + .../benilla-app/src/capture/probe_charter.rs | 55 +++- .../src/capture/probes/world_census.rs | 21 +- crates/benilla-app/src/entities.rs | 151 ++++++++++ crates/benilla-app/src/glue/widgets.rs | 64 ++++- crates/benilla-app/src/login/mod.rs | 158 ++++++++-- crates/benilla-app/src/names.rs | 16 +- crates/benilla-app/src/portrait/mod.rs | 270 +++++++++++++++++- crates/benilla-app/src/ui_items/feed.rs | 43 ++- crates/benilla-app/src/ui_petition/feed.rs | 4 +- crates/benilla-app/src/ui_petition/mod.rs | 57 ++++ .../src/ui_script/action_bar_tests.rs | 1 + crates/benilla-app/src/ui_script/bag_tests.rs | 7 + .../src/ui_script/character_tests.rs | 1 + .../benilla-app/src/ui_script/chat_tests.rs | 1 + .../src/ui_script/delete_item_tests.rs | 1 + .../benilla-app/src/ui_script/escape_tests.rs | 2 + .../src/ui_script/game_menu_tests.rs | 1 + .../src/ui_script/help_frame_tests.rs | 53 ++++ .../src/ui_script/petition_tests.rs | 38 +++ .../src/ui_script/tooltip_compare_tests.rs | 1 + crates/benilla-app/src/ui_session.rs | 122 +++++++- crates/benilla-app/src/ui_stable.rs | 169 +++++++++++ crates/benilla-ui/src/framexml.rs | 10 + crates/benilla-ui/src/loader/tests.rs | 40 +++ crates/benilla-ui/src/loader/widgets.rs | 21 +- crates/benilla-ui/src/script/container.rs | 37 +++ crates/benilla-ui/src/script/cursor.rs | 1 + crates/benilla-ui/src/script/cursor/doll.rs | 2 + crates/benilla-ui/src/script/editbox.rs | 76 ++++- crates/benilla-ui/src/script/editbox/tests.rs | 172 +++++++++-- crates/benilla-ui/src/script/event.rs | 8 + crates/benilla-ui/src/script/mod.rs | 9 +- crates/benilla-ui/src/script/stable.rs | 33 +++ .../src/script/tests/tooltip_item/bindings.rs | 1 + .../src/script/tests/tooltip_item/law.rs | 144 ++++++++++ .../benilla-ui/src/script/tooltip_item/mod.rs | 8 + .../src/script/tooltip_item/render.rs | 25 ++ crates/benilla-ui/src/widget/kinds/editbox.rs | 34 ++- 42 files changed, 1799 insertions(+), 131 deletions(-) diff --git a/crates/benilla-app/assets/ui/GuildRegistrarFrame.xml b/crates/benilla-app/assets/ui/GuildRegistrarFrame.xml index 627dea98..42df2fbc 100644 --- a/crates/benilla-app/assets/ui/GuildRegistrarFrame.xml +++ b/crates/benilla-app/assets/ui/GuildRegistrarFrame.xml @@ -119,8 +119,17 @@ `BenillaQuestTitleButtonTemplate` because that one hardwires `QuestTitleButton_OnClick()` and would drag this window's load order behind the questgiver's for a fifteen-line shape. Same LEFT-anchored title as that template, and for the same reason: the round bullet is - cell-centred, so a TOPLEFT-anchored label rides above it (QuestFrame.xml's own note). --> -