wip(0.S3): packages and examples migrated again from their pre-0.S sources in one run

ludic migrate state packages <every example program> packages/ludic.lab/example/plate.ludic
  1804 vars into 126 states, 64 into lets; 23498 edits in 460 files

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Orkun ÇAKILKAYA 2026-09-25 15:31:34 +03:00
parent 5ffe50ed02
commit 19fcf60599
459 changed files with 17862 additions and 17603 deletions

View file

@ -11,18 +11,18 @@ program UiComponent {
if n.text != "" { push(out, n.text) }
for i in 0 .. len(n.children) { texts(n.children[i], out) }
}
function frame() -> UiNode {
let root: UiNode = ui_nodes("App", null)
ui_place(root, 0.0, 0.0, 400.0, 400.0)
function frame(ui_st: mut UiState) -> UiNode {
let root: UiNode = ui_nodes(ui_st, "App", null)
ui_place(ui_st, root, 0.0, 0.0, 400.0, 400.0)
return root
}
entry {
var root = frame()
entry (ui_st: mut UiState) {
var root = frame(ui_st)
let b = root.children[0].children[2]
ui_press(b.children[1])
ui_press(b.children[1])
ui_press(root.children[0].children[1].children[1])
root = frame()
ui_press(ui_st, b.children[1])
ui_press(ui_st, b.children[1])
ui_press(ui_st, root.children[0].children[1].children[1])
root = frame(ui_st)
let out = new []string
texts(root, out)
var joined = ""
@ -30,8 +30,8 @@ program UiComponent {
print(joined)
let b2 = root.children[0].children[2]
print(`b margin {int(b2.mt)}; b text {b2.children[0].fg}; outside {root.children[0].children[3].fg}; button {int(b2.children[1].ch)}`)
ui_press(b2.children[2])
root = frame()
ui_press(ui_st, b2.children[2])
root = frame(ui_st)
print(root.children[0].children[2].children[0].text)
}
}