3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4 <title>qooxdoo » Demo</title>
5 <link type="text/css" rel="stylesheet" href="../../resource/css/layout.css"/>
7 <link type="text/css" rel="stylesheet" href="../../resource/css/layout_ie.css"/>
9 <script type="text/javascript" src="../../script/qx.js"></script>
12 <script type="text/javascript" src="../../script/layout.js"></script>
14 <div id="demoDescription">
15 <p>Test for qx.ui.layout.GridLayout. Now with cells which are merged with others.</p>
18 <script type="text/javascript">
19 qx.core.Init.getInstance().defineMain(function()
21 var gl = new qx.ui.layout.GridLayout;
23 gl.setLocation(20, 48);
24 gl.setDimension(462, 128);
25 gl.setBorder(qx.renderer.border.BorderPresets.getInstance().outset);
30 gl.setColumnWidth(0, 100);
31 gl.setColumnWidth(1, 200);
32 gl.setColumnWidth(2, 50);
33 gl.setColumnWidth(3, 100);
35 gl.setRowHeight(0, 40);
36 gl.setRowHeight(1, 80);
38 qx.ui.core.ClientDocument.getInstance().add(gl);
40 // start-col, start-row, col-length, row-length
41 gl.debug("Merge: 1, 1, 2, 1");
42 gl.mergeCells(1, 1, 2, 1);
44 gl.debug("Span-Start (0, 1): " + gl.isSpanStart(0, 1));
45 gl.debug("Span-Start (0, 2): " + gl.isSpanStart(0, 2));
46 gl.debug("Span-Start (1, 1): " + gl.isSpanStart(1, 1));
47 gl.debug("Span-Start (1, 2): " + gl.isSpanStart(1, 2));
48 gl.debug("Span-Start (2, 1): " + gl.isSpanStart(2, 1));
49 gl.debug("Span-Start (2, 2): " + gl.isSpanStart(2, 2));
50 gl.debug("Span-Start (3, 1): " + gl.isSpanStart(3, 1));
51 gl.debug("Span-Start (3, 2): " + gl.isSpanStart(3, 2));
53 gl.debug("Span-Cell (0, 1): " + gl.isSpanCell(0, 1));
54 gl.debug("Span-Cell (0, 2): " + gl.isSpanCell(0, 2));
55 gl.debug("Span-Cell (1, 1): " + gl.isSpanCell(1, 1));
56 gl.debug("Span-Cell (1, 2): " + gl.isSpanCell(1, 2));
57 gl.debug("Span-Cell (2, 1): " + gl.isSpanCell(2, 1));
58 gl.debug("Span-Cell (2, 2): " + gl.isSpanCell(2, 2));
59 gl.debug("Span-Cell (3, 1): " + gl.isSpanCell(3, 1));
60 gl.debug("Span-Cell (3, 2): " + gl.isSpanCell(3, 2));
62 gl.debug("Fill-Cell (0, 1): " + gl.isFillCell(0, 1));
63 gl.debug("Fill-Cell (0, 2): " + gl.isFillCell(0, 2));
64 gl.debug("Fill-Cell (1, 1): " + gl.isFillCell(1, 1));
65 gl.debug("Fill-Cell (1, 2): " + gl.isFillCell(1, 2));
66 gl.debug("Fill-Cell (2, 1): " + gl.isFillCell(2, 1));
67 gl.debug("Fill-Cell (2, 2): " + gl.isFillCell(2, 2));
68 gl.debug("Fill-Cell (3, 1): " + gl.isFillCell(3, 1));
69 gl.debug("Fill-Cell (3, 2): " + gl.isFillCell(3, 2));
72 // both should be impossible
73 gl.debug("Merge 1, 1, 2, 1");
74 gl.mergeCells(1, 1, 2, 1);
76 gl.debug("Merge 0, 0, 3, 4");
77 gl.mergeCells(0, 0, 3, 4);
80 gl.debug("Merge 0, 0, 1, 2");
81 gl.mergeCells(0, 0, 1, 2);
83 gl.debug("Merge 2, 0, 2, 1");
84 gl.mergeCells(2, 0, 2, 1);
89 var term1 = new qx.ui.basic.Terminator;
90 term1.setBackgroundColor("yellow");
93 var term2 = new qx.ui.basic.Terminator;
94 term2.setBackgroundColor("red");
97 var term3 = new qx.ui.basic.Terminator;
98 term3.setBackgroundColor("green");
101 var term6 = new qx.ui.basic.Terminator;
102 term6.setBackgroundColor("olive");
105 var term8 = new qx.ui.basic.Terminator;
106 term8.setBackgroundColor("navy");