r19141: add a reasonable subset of the qooxdoo runtime environment, and example appli...
[Samba/ekacnet.git] / swat / apps / qooxdoo-examples / test / GridLayout_4.html
blob230e00f404c308a3177c2c5983fe4b14f10915f8
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4 <title>qooxdoo &raquo; Demo</title>
5 <link type="text/css" rel="stylesheet" href="../../resource/css/layout.css"/>
6 <!--[if IE]>
7 <link type="text/css" rel="stylesheet" href="../../resource/css/layout_ie.css"/>
8 <![endif]-->
9 <script type="text/javascript" src="../../script/qx.js"></script>
10 </head>
11 <body>
12 <script type="text/javascript" src="../../script/layout.js"></script>
14 <div id="demoDescription">
15 <p>Test for qx.ui.layout.GridLayout.</p>
16 <p>Using percents for children.</p>
17 </div>
19 <script type="text/javascript">
20 qx.core.Init.getInstance().defineMain(function()
22 var gl = new qx.ui.layout.GridLayout;
24 gl.setLocation(20, 48);
25 gl.setRight(335);
26 gl.setBottom(48);
27 gl.setBorder(qx.renderer.border.BorderPresets.getInstance().outset);
28 gl.setPadding(2, 4);
29 gl.setColumnCount(4);
30 gl.setRowCount(2);
32 gl.setColumnWidth(0, "10%");
33 gl.setColumnWidth(1, "40%");
34 gl.setColumnWidth(2, "30%");
35 gl.setColumnWidth(3, "20%");
37 gl.setRowHeight(0, "70%");
38 gl.setRowHeight(1, "30%");
40 qx.ui.core.ClientDocument.getInstance().add(gl);
46 var term1 = new qx.ui.basic.Terminator;
47 term1.setBackgroundColor("yellow");
48 gl.add(term1, 0, 0);
50 var term2 = new qx.ui.basic.Terminator;
51 term2.setBackgroundColor("red");
52 gl.add(term2, 1, 0);
54 var term3 = new qx.ui.basic.Terminator;
55 term3.setBackgroundColor("green");
56 gl.add(term3, 2, 0);
58 var term4 = new qx.ui.basic.Terminator;
59 term4.setBackgroundColor("blue");
60 gl.add(term4, 3, 0);
62 var term5 = new qx.ui.basic.Terminator;
63 term5.setBackgroundColor("fuchsia");
64 gl.add(term5, 0, 1);
66 var term6 = new qx.ui.basic.Terminator;
67 term6.setBackgroundColor("olive");
68 gl.add(term6, 1, 1);
70 var term7 = new qx.ui.basic.Terminator;
71 term7.setBackgroundColor("maroon");
72 gl.add(term7, 2, 1);
74 var term8 = new qx.ui.basic.Terminator;
75 term8.setBackgroundColor("navy");
76 gl.add(term8, 3, 1);
77 });
78 </script>
80 </body>
81 </html>