Created
March 9, 2018 07:23
-
-
Save greggirwin/e40459503f75a748b056d08b3f8289ea to your computer and use it in GitHub Desktop.
Show how to drop loose faces and generate a layout from them.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Red [ | |
Purpose: "Show how to drop faces to make a GUI and save it." | |
] | |
spec: copy [] | |
btn-pos: 700x10 | |
n: 0 | |
view/options [ | |
size 800x600 | |
at btn-pos | |
btn: button "Button" loose on-drop [ | |
n: n + 1 | |
name: append copy "Button " n | |
p: face/offset | |
repend spec ['at p 'button name []] | |
repend face/parent/draw ['box p p + face/size 'text p + 4x5 name] | |
new-line find/last spec 'at on | |
print mold spec | |
btn/offset: btn-pos | |
] | |
][draw: []] | |
view spec |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment