Data update

This commit is contained in:
Ingy döt Net 2025-08-11 18:05:26 -07:00
parent 4d5544505c
commit 4924dd0264
3073 changed files with 55820 additions and 4408 deletions

View file

@ -0,0 +1,7 @@
var message := displayNewMessage('There have been no clicks yet')
var button := displayNewElementIn('click me', 'body', 'button', true)
var count := 0
while true:
awaitClickBeep(button)
count += 1
displayMessageIn(count, message)

View file

@ -0,0 +1,23 @@
\ the GTK objects can have fields, so no global is needed
click (btn) with (label):
btn.clicked =+ 1
label::label text "Clicked" __ btn.clicked __ "times."
setup main window:
win =: new GTK window
win::set title "Button Demo"
win::set size 150, 100
win::connect 'destroy' to `GTK main quit`
box =: new GTK container box 'vertical' spacing 2
win::add container box
msg =: new GTK widget label "Not yet any click, click the button..."
box::add widget msg
button =: new GTK widget button "Click here"
button.clicked =: 0
button::connect 'clicked' to `click () with ()` with msg
box::add widget button
win::show all
:>win
main (args):+
GTK init args
GTK main setup main window