diff options
author | Ian C <ianc@noddybox.co.uk> | 2005-09-19 23:25:32 +0000 |
---|---|---|
committer | Ian C <ianc@noddybox.co.uk> | 2005-09-19 23:25:32 +0000 |
commit | d2d6b14d7a69baffb448f9c06b392011eda37410 (patch) | |
tree | c7898f6ee06ac866ffcd12b667653c8cb6905cfd /simplegui | |
parent | dc296ce6322ec28ca30bddc1b881b09c2998aa61 (diff) |
*** empty log message ***
Diffstat (limited to 'simplegui')
-rw-r--r-- | simplegui/test.bmx | 32 |
1 files changed, 28 insertions, 4 deletions
diff --git a/simplegui/test.bmx b/simplegui/test.bmx index f0ecc48..9b916fd 100644 --- a/simplegui/test.bmx +++ b/simplegui/test.bmx @@ -17,14 +17,21 @@ TGUIFont.font=font Global gui:TGUIHandler=TGUIHandler.Create() -Global label1:TLabel=TLabel.Create(gui,0,0,"Text 1: ") -Global label2:TLabel=TLabel.Create(gui,0,20,"Text 2: ") +Global label1:TLabel=TLabel.Create(gui,0,0,"Text 1:") +Global label2:TLabel=TLabel.Create(gui,0,20,"Text 2:") Global text1:TText=TText.Create(gui,label1.w,0,"Text entry 1",20,TextCallback) Global text2:TText=TText.Create(gui,label2.w,20,"Text entry 2",30) Global check1:TCheckbox=TCheckbox.Create(gui,400,0,"Check 1",CheckCallback) Global check2:TCheckbox=TCheckbox.Create(gui,400,20,"Check 2") -Global button1:TButton=TButton.Create(gui,0,360,100,30,"Button 1",ButtonCallback) +Global button1:TButton=TButton.Create(gui,0,360,100,30,"Test Alerts",ButtonCallback) Global button2:TButton=TButton.Create(gui,110,360,100,30,"Quit",ButtonCallback) +Global buttonlist:TButtonList=TButtonList.Create(gui,500,0,["Hidden","Globally","Widgets"],0,Null) + +TLabel.Create(gui,0,60,"Float:") +Global numberf:TNumberFloat=TNumberFloat.Create(gui,80,60) + +TLabel.Create(gui,0,80,"Int:") +Global numberi:TNumberInt=TNumberInt.Create(gui,80,80) SetBlend(ALPHABLEND) @@ -39,6 +46,11 @@ While Not KeyHit(KEY_ESCAPE) And Not quit Menu() EndIf + SetColor(255,0,0) + DrawRect(390,300,10,numberf.value) + SetColor(0,255,0) + DrawRect(400,300,10,numberi.value) + Flip FlushMem Wend @@ -62,7 +74,19 @@ Function ButtonCallback(w:TWidget) If w.text="Quit" quit=GUIYesNo("Really quit this really rather impressive (cough) demo?") Else + GUINotify(w.text + " pressed") + GUINotify("Hello|World") + If GUIYesNo("Test yes/no?") + GUINotify("yes") + Else + GUINotify("no") + EndIf + If GUIYesNo("Test yes/no|with some very very very long|multiple lines?") + GUINotify("yes") + Else + GUINotify("no") + EndIf EndIf End Function @@ -73,4 +97,4 @@ Function Menu() If opt>-1 GUINotify("Selected " + opt) EndIf -End Function
\ No newline at end of file +End Function |