Skip to content

feat(example): add full-screen windows to the example and document them - #129

Open
oglassdev wants to merge 3 commits into
feat/fullscreen-elementsfrom
feat/fullscreen-example
Open

oglassdev wants to merge 3 commits into
feat/fullscreen-elementsfrom
feat/fullscreen-example

Conversation

@oglassdev

Copy link
Copy Markdown
Contributor

Closes #122
Part of #115

Example

  • /lobby opens an unlocked full-screen main menu (lobby.tsx, MyLobby.kt). It has bound text, a ready switch, the shared tone tint, and a <Repeater fixed> of worlds with a tooltip. FullscreenView.list pages the worlds (step 1) from the arrows or the scroll wheel. Right clicking anywhere toggles ready.
  • Clicking the foundry name opens a native promptText dialog. Confirm or Cancel returns to the lobby, and Confirm renames the foundry (fit keeps long names inside the plate).
  • /lookout opens a horse-mode window (lookout.tsx, MyLookout.kt) with a bound bar and a button.
  • The index adds a preview of the lobby.

Size budget

The pack's compiler output goes from 811 KB to 1,093,587 bytes, so the budget rises from 1,000,000 to 1,150,000. The shipped zip goes from 76 KB to 107 KB.

Part Added
Text-row fonts (12 new rows at ~15.2 KB each) ~182 KB
Generated Kotlin (WindowFullscreenEntries and the two views) ~39 KB
Debug descriptor (~37 new resource entries, mostly the per-PNG alpha masks of the full-screen art) ~35 KB
Full-screen shaders and include ~12 KB
Canvas contract, hover outlines, main font, window art ~14 KB

The generator change here would have been one cheap win, and none was found. The fonts follow the documented one-font-per-row model, and full-screen rows can't share container rows without a per-window shader shift. The descriptor masks are a general cost of every generated PNG, outside this PR's scope.

Docs

  • AUTHORING: fullscreens, mode, backdrop, pack format, text-row cost, and a Roots table row.
  • README: a Full-screen windows section with the Kotlin API, the Minestom host's runtime contract, and limitations.
  • example README: the new files and commands.
  • VALIDATION: a short note on checking full-screen windows in a real client.

Checks

just check-ts, just golden, just gradle :example:compileKotlin, and just fmt-check pass. There are no Rust changes.

The lobby pages a world list with arrows, the scroll wheel, and a fixed
repeater with tooltips, renames the foundry through a native text prompt,
and toggles ready on right click. The lookout shows horse mode with a bar.
/lobby and /lookout open them.

The size budget rises to 1.15 MB: the two windows add 12 text-row fonts
(~182 KB), their generated Kotlin, descriptor entries, and the full-screen
shaders.
Cover authoring (fullscreens, modes, backdrop, costs), the Kotlin API
(FullscreenView, scroll, right click, promptText, list), the Minestom
host's runtime contract, and limitations. Note how to check them in a
real client.
@oglassdev
oglassdev marked this pull request as ready for review October 16, 2026 00:24
@oglassdev
oglassdev added this pull request to stack #130 October 16, 2026 00:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant