Revision: 4806
          http://sourceforge.net/p/vexi/code/4806
Author:   clrg
Date:     2015-07-11 00:16:52 +0000 (Sat, 11 Jul 2015)
Log Message:
-----------
Add simple counter tutorial

Added Paths:
-----------
    branches/vexi3/org.vexi-vapp.codetutor/src_tutor/tutorials/counter/
    branches/vexi3/org.vexi-vapp.codetutor/src_tutor/tutorials/counter/sample1.t

Added: 
branches/vexi3/org.vexi-vapp.codetutor/src_tutor/tutorials/counter/sample1.t
===================================================================
--- 
branches/vexi3/org.vexi-vapp.codetutor/src_tutor/tutorials/counter/sample1.t    
                            (rev 0)
+++ 
branches/vexi3/org.vexi-vapp.codetutor/src_tutor/tutorials/counter/sample1.t    
    2015-07-11 00:16:52 UTC (rev 4806)
@@ -0,0 +1,28 @@
+<vexi xmlns:ui="vexi://ui"
+      xmlns:lay="vexi.layout"
+      xmlns="vexi.widget">
+
+    <surface />
+    <ui:box frametitle="Simple Counter" shrink="true">
+        <lay:pad orient="vertical" padding="5" shrink="true">
+            <ui:box>
+                <ui:box width="5" /> // pad the 'Count'
+                <ui:box shrink="true" text="Count:" />
+                <textfield id="output" margin="5" />
+            </ui:box>
+            <ui:box vshrink="true">
+                <button id="dec" margin="5" text="Dec (-)" />
+                <button id="clear" margin="5" text="Clear" />
+                <button id="inc" margin="5" text="Inc (+)" />
+            </ui:box>
+        </lay:pad>
+        
+        vexi.ui.frame = thisbox;
+        
+        thisbox.value ++= function(v) { $output.text = v; cascade - v; }
+        $dec.action ++= function(v) { value--; }
+        $inc.action ++= function(v) { value++; }
+        $clear.action ++= function(v) { value = 0; }
+        value = 0; // initialise counter
+    </ui:box>
+</vexi>

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
Vexi-svn mailing list
Vexi-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vexi-svn

Reply via email to