Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpelder2008-04-04 11:43:21 -0400
committerpelder2008-04-04 11:43:21 -0400
commit9d67d93fdb4ff179a560b13caa8b8ca06e27c4a7 (patch)
tree346b91143ef88a4c180f76050115e278e494cfd1 /examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control
parent085f82498792c69132e00c5d677b0569096866fc (diff)
downloadorg.eclipse.jet-9d67d93fdb4ff179a560b13caa8b8ca06e27c4a7.tar.gz
org.eclipse.jet-9d67d93fdb4ff179a560b13caa8b8ca06e27c4a7.tar.xz
org.eclipse.jet-9d67d93fdb4ff179a560b13caa8b8ca06e27c4a7.zip
[225768] Add releng examples created at EclipseCon to JET Examples
Diffstat (limited to 'examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control')
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/initControl.jet16
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/swtStyles.jet17
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/initControl.jet19
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/swtStyles.jet11
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/initControl.jet10
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/swtStyles.jet5
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/controlData.xml.jet42
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/initControl.jet12
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/swtStyles.jet8
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/initControl.jet10
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/swtStyles.jet23
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/initControl.jet10
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/swtStyles.jet8
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/initControl.jet10
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/swtStyles.jet11
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridData.jet30
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridLayout.jet27
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/initControl.jet13
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/swtStyles.jet20
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/initControl.jet19
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/swtStyles.jet8
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/initControl.jet16
-rw-r--r--examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/swtStyles.jet32
23 files changed, 377 insertions, 0 deletions
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/initControl.jet
new file mode 100644
index 0000000..f096295
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/initControl.jet
@@ -0,0 +1,16 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- button --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
+<c:if test="$control/@grayed">
+ <c:get select="$control/@name"/>.setGreyed(<c:get select="$control/@grayed"/>);
+</c:if>
+<c:if test="$control/@selection">
+ <c:get select="$control/@name"/>.setSelection(<c:get select="$control/@selection"/>);
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/swtStyles.jet
new file mode 100644
index 0000000..6eef889
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/button/swtStyles.jet
@@ -0,0 +1,17 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- button --%>
+ SWT.<c:get select="$control/@style"/>
+<c:if test="$control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
+<c:if test="$control/@flat = 'true'">
+ |SWT.FLAT
+</c:if>
+<c:if test="$control/@alignment">
+ |SWT.<c:get select="$control/@alignment"/>
+</c:if>
+<c:if test="$control/@arrowStyle">
+ |SWT.<c:get select="$control/@arrowStyle"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/initControl.jet
new file mode 100644
index 0000000..3299830
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/initControl.jet
@@ -0,0 +1,19 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- combo --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@visibleItemCount">
+ <c:get select="$control/@message"/>.setVisibleItemCount(<c:get select="$control/@visibleItemCount"/>);
+</c:if>
+<c:if test="$control/@textLimit">
+ <c:get select="$control/@name"/>.setTextLimit(<c:get select="$control/@textLimit"/>);
+</c:if>
+<c:iterate select="$control/item" var="item">
+ <c:get select="$control/@name"/>.add("<c:get select="$item"/>");
+</c:iterate>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/swtStyles.jet
new file mode 100644
index 0000000..bdc3f34
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/combo/swtStyles.jet
@@ -0,0 +1,11 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- combo --%>
+ SWT.NONE
+<c:if test="$control/@readOnly = 'true'">
+ |SWT.READ_ONLY
+</c:if>
+<c:if test="$control/@style">
+ |SWT.<c:get select="$control/@style"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/initControl.jet
new file mode 100644
index 0000000..0a01fcd
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/initControl.jet
@@ -0,0 +1,10 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- composite --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+
+ <c:include template="templates/control/setGridLayout.jet"/>
+
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/swtStyles.jet
new file mode 100644
index 0000000..524b58b
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/composite/swtStyles.jet
@@ -0,0 +1,5 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- composite --%>
+ SWT.NONE
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/controlData.xml.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/controlData.xml.jet
new file mode 100644
index 0000000..3d3d46f
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/controlData.xml.jet
@@ -0,0 +1,42 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+ <button javaType="org.eclipse.swt.widgets.Button"
+ swtStylesTemplate="templates/control/button/swtStyles.jet"
+ initControlTemplate="templates/control/button/initControl.jet"/>
+
+ <combo javaType="org.eclipse.swt.widgets.Combo"
+ swtStylesTemplate="templates/control/combo/swtStyles.jet"
+ initControlTemplate="templates/control/combo/initControl.jet"/>
+
+ <composite javaType="org.eclipse.swt.widgets.Composite"
+ swtStylesTemplate="templates/control/composite/swtStyles.jet"
+ initControlTemplate="templates/control/composite/initControl.jet"/>
+
+ <group javaType="org.eclipse.swt.widgets.Group"
+ swtStylesTemplate="templates/control/group/swtStyles.jet"
+ initControlTemplate="templates/control/group/initControl.jet"/>
+
+ <label javaType="org.eclipse.swt.widgets.Label"
+ swtStylesTemplate="templates/control/label/swtStyles.jet"
+ initControlTemplate="templates/control/label/initControl.jet"/>
+
+ <link javaType="org.eclipse.swt.widgets.Link"
+ swtStylesTemplate="templates/control/link/swtStyles.jet"
+ initControlTemplate="templates/control/link/initControl.jet"/>
+
+ <list javaType="org.eclipse.swt.widgets.List"
+ swtStylesTemplate="templates/control/list/swtStyles.jet"
+ initControlTemplate="templates/control/list/initControl.jet"/>
+
+ <table javaType="org.eclipse.swt.widgets.Table"
+ swtStylesTemplate="templates/control/table/swtStyles.jet"
+ initControlTemplate="templates/control/table/initControl.jet"/>
+
+ <tableColumn javaType="org.eclipse.swt.widgets.TableColumn"
+ swtStylesTemplate="templates/control/tableColumn/swtStyles.jet"
+ initControlTemplate="templates/control/tableColumn/initControl.jet"/>
+
+ <text javaType="org.eclipse.swt.widgets.Text"
+ swtStylesTemplate="templates/control/text/swtStyles.jet"
+ initControlTemplate="templates/control/text/initControl.jet"/>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/initControl.jet
new file mode 100644
index 0000000..bfd3a1d
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/initControl.jet
@@ -0,0 +1,12 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- group --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
+
+ <c:include template="templates/control/setGridLayout.jet"/>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/swtStyles.jet
new file mode 100644
index 0000000..578fcfe
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/group/swtStyles.jet
@@ -0,0 +1,8 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- group --%>
+ SWT.NONE
+<c:if test="$control/@shadow">
+ |SWT.SHADOW_<c:get select="$control/@orientation"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/initControl.jet
new file mode 100644
index 0000000..133e87a
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/initControl.jet
@@ -0,0 +1,10 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- label --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/swtStyles.jet
new file mode 100644
index 0000000..726804e
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/label/swtStyles.jet
@@ -0,0 +1,23 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- label --%>
+ SWT.NONE
+<c:if test="$control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
+<c:if test="$control/@separator = 'true'">
+ |SWT.SEPARATOR
+</c:if>
+<c:if test="$control/@wrap = 'true'">
+ |SWT.WRAP
+</c:if>
+<c:if test="$control/@alignment">
+ |SWT.<c:get select="$control/@alignment"/>
+</c:if>
+<c:if test="$control/@orientation">
+ |SWT.<c:get select="$control/@orientation"/>
+</c:if>
+<c:if test="$control/@shadow">
+ |SWT.SHADOW_<c:get select="$control/@orientation"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/initControl.jet
new file mode 100644
index 0000000..224b6f4
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/initControl.jet
@@ -0,0 +1,10 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- link --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/swtStyles.jet
new file mode 100644
index 0000000..eb395e8
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/link/swtStyles.jet
@@ -0,0 +1,8 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- link --%>
+ SWT.NONE
+<c:if test="$control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/initControl.jet
new file mode 100644
index 0000000..8fa81a9
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/initControl.jet
@@ -0,0 +1,10 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- list --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:iterate select="$control/item" var="item">
+ <c:get select="$control/@name"/>.add("<c:get select="$item"/>");
+</c:iterate> \ No newline at end of file
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/swtStyles.jet
new file mode 100644
index 0000000..2e82e15
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/list/swtStyles.jet
@@ -0,0 +1,11 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- list --%>
+ SWT.NONE
+<c:if test="not($control/@border) or $control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
+<c:if test="$control/@style">
+ |SWT.<c:get select="$control/@style"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridData.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridData.jet
new file mode 100644
index 0000000..c7ee4c0
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridData.jet
@@ -0,0 +1,30 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+ <java:import>org.eclipse.jface.layout.GridDataFactory</java:import>.defaultsFor(<c:get select="$control/@name"/>)
+<c:iterate select="$control/gridData/*" var="data">
+<c:choose>
+<c:when test="$data/self::align">
+ .align(SWT.<c:get select="$data/@hAlign"/>, SWT.<c:get select="$data/@vAlign"/>)
+</c:when>
+<c:when test="$data/self::exclude">
+ .exclude(true)
+</c:when>
+<c:when test="$data/self::grab">
+ .grab(<c:get select="$data/@horizontal"/>, <c:get select="$data/@vertical"/>)
+</c:when>
+<c:when test="$data/self::hint">
+ .hint(<c:get select="$data/@xHint"/>, <c:get select="$data/@yHint"/>)
+</c:when>
+<c:when test="$data/self::indent">
+ .indent(<c:get select="$data/@hIndent"/>, <c:get select="$data/@vIndent"/>)
+</c:when>
+<c:when test="$data/self::minSize">
+ .minSize(<c:get select="$data/@minX"/>, <c:get select="$data/@minY"/>)
+</c:when>
+<c:when test="$data/self::span">
+ .span(<c:get select="$data/@hSpan"/>, <c:get select="$data/@vSpan"/>)
+</c:when>
+</c:choose>
+</c:iterate>
+ .applyTo(<c:get select="$control/@name"/>);
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridLayout.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridLayout.jet
new file mode 100644
index 0000000..a1f6b8a
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/setGridLayout.jet
@@ -0,0 +1,27 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<c:if test="$control/gridLayout">
+ <java:import>org.eclipse.jface.layout.GridLayoutFactory</java:import>.swtDefaults()
+<c:iterate select="$control/gridLayout/*" var="layout">
+<c:choose>
+<c:when test="$layout/self::equalWidth">
+ .equalWidth(true)
+</c:when>
+<c:when test="$layout/self::extendedMargins">
+ .extendedMargins(<c:get select="$layout/@left"/>, <c:get select="$layout/@right"/>,
+ <c:get select="$layout/@top"/>, <c:get select="$layout/@bottom"/>)
+</c:when>
+<c:when test="$layout/self::margins">
+ .margins(<c:get select="$layout/@width"/>, <c:get select="$layout/@height"/>)
+</c:when>
+<c:when test="$layout/self::numColumns">
+ .numColumns(<c:get select="$layout/@numColumns"/>)
+</c:when>
+<c:when test="$layout/self::spacing">
+ .spacing(<c:get select="$layout/@hSpacing"/>, <c:get select="$layout/@vSpacing"/>)
+</c:when>
+</c:choose>
+</c:iterate>
+ .applyTo(<c:get select="$control/@name"/>);
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/initControl.jet
new file mode 100644
index 0000000..2b0064c
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/initControl.jet
@@ -0,0 +1,13 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- table --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@headerVisible">
+ <c:get select="$control/@name"/>.setHeaderVisible(<c:get select="$control/@headerVisible"/>);
+</c:if>
+<c:if test="$control/@linesVisible = 'true'">
+ <c:get select="$control/@name"/>.setLinesVisible(<c:get select="$control/@linesVisible"/>);
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/swtStyles.jet
new file mode 100644
index 0000000..94d4d2e
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/table/swtStyles.jet
@@ -0,0 +1,20 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- table --%>
+ SWT.NONE
+<c:if test="not($control/@border) or $control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
+<c:if test="$control/@style">
+ |SWT.<c:get select="$control/@style"/>
+</c:if>
+<c:if test="$control/@fullSelection = 'true'">
+ |SWT.FULL_SELECTION
+</c:if>
+<c:if test="$control/@hideSelection = 'true'">
+ |SWT.HIDE_SELECTION
+</c:if>
+<c:if test="$control/@virtual = 'true'">
+ |SWT.VIRTUAL
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/initControl.jet
new file mode 100644
index 0000000..4e56208
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/initControl.jet
@@ -0,0 +1,19 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- tableColumn --%>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
+<c:if test="$control/@toolTipText">
+ <c:get select="$control/@name"/>.setToolTipText("<c:get select="$control/@toolTipText"/>");
+</c:if>
+<c:if test="$control/@width">
+ <c:get select="$control/@name"/>.setWidth(<c:get select="$control/@width"/>);
+</c:if>
+<c:if test="$control/@moveable">
+ <c:get select="$control/@name"/>.setMoveable(<c:get select="$control/@moveable"/>);
+</c:if>
+<c:if test="$control/@resizeable">
+ <c:get select="$control/@name"/>.setResizeable(<c:get select="$control/@resizeable"/>);
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/swtStyles.jet
new file mode 100644
index 0000000..eeda8f4
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/tableColumn/swtStyles.jet
@@ -0,0 +1,8 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- tableColumn --%>
+ SWT.NONE
+<c:if test="$control/@alignment">
+ |SWT.<c:get select="$control/@alignment"/>
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/initControl.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/initControl.jet
new file mode 100644
index 0000000..8ebf24a
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/initControl.jet
@@ -0,0 +1,16 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- text --%>
+<c:if test="$control/@enabled">
+ <c:get select="$control/@name"/>.setEnabled(<c:get select="$control/@enabled"/>);
+</c:if>
+<c:if test="$control/@text">
+ <c:get select="$control/@name"/>.setText("<c:get select="$control/@text"/>");
+</c:if>
+<c:if test="$control/@message">
+ <c:get select="$control/@message"/>.setMessage("<c:get select="$control/@message"/>");
+</c:if>
+<c:if test="$control/@textLimit">
+ <c:get select="$control/@name"/>.setTextLimit(<c:get select="$control/@textLimit"/>);
+</c:if>
diff --git a/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/swtStyles.jet b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/swtStyles.jet
new file mode 100644
index 0000000..8ac2906
--- /dev/null
+++ b/examples/org.eclipse.jet.ec2008.swtgen.codebehind/templates/control/text/swtStyles.jet
@@ -0,0 +1,32 @@
+<%!
+/* Copyright 2008 IBM Corp. All rights reserved. This source code is made available under the terms of the Eclipse Public License, v1.0. */
+%>
+<%-- text --%>
+ SWT.NONE
+<c:if test="$control/@style">
+ |SWT.<c:get select="$control/@style"/>
+</c:if>
+<c:if test="not($control/@border) or $control/@border = 'true'">
+ |SWT.BORDER
+</c:if>
+<c:if test="$control/@readOnly = 'true'">
+ |SWT.READ_ONLY
+</c:if>
+<c:if test="$control/@wrap = 'true'">
+ |SWT.WRAP
+</c:if>
+<c:if test="$control/@search = 'true'">
+ |SWT.SEARCH
+</c:if>
+<c:if test="$control/@cancel = 'true'">
+ |SWT.CANCEL
+</c:if>
+<c:if test="$control/@password = 'true'">
+ |SWT.PASSWORD
+</c:if>
+<c:if test="$control/@alignment">
+ |SWT.<c:get select="$control/@alignment"/>
+</c:if>
+<c:if test="$control/@scroll">
+ |SWT.<c:get select="$control/@scroll"/>
+</c:if>

Back to the top