78
|
1 /*******************************************************************************
|
|
2 * Copyright (c) 2000, 2004 IBM Corporation and others.
|
|
3 * All rights reserved. This program and the accompanying materials
|
|
4 * are made available under the terms of the Eclipse Public License v1.0
|
|
5 * which accompanies this distribution, and is available at
|
|
6 * http://www.eclipse.org/legal/epl-v10.html
|
|
7 *
|
|
8 * Contributors:
|
|
9 * IBM Corporation - initial API and implementation
|
|
10 * D Port:
|
|
11 * Jesse Phillips <Jesse.K.Phillips+D> gmail.com
|
|
12 *******************************************************************************/
|
|
13 module examples.clipboard.ClipboardExample;
|
|
14
|
|
15 import dwt.DWT;
|
|
16 import dwt.custom.ScrolledComposite;
|
|
17 import dwt.custom.StyledText;
|
|
18 import dwt.dnd.Clipboard;
|
|
19 import dwt.dnd.FileTransfer;
|
|
20 import dwt.dnd.HTMLTransfer;
|
|
21 import dwt.dnd.RTFTransfer;
|
|
22 import dwt.dnd.TextTransfer;
|
|
23 import dwt.dnd.Transfer;
|
|
24 import dwt.events.SelectionAdapter;
|
|
25 import dwt.events.SelectionEvent;
|
|
26 import dwt.graphics.Point;
|
|
27 import dwt.graphics.Rectangle;
|
|
28 import dwt.layout.FillLayout;
|
|
29 import dwt.layout.GridData;
|
|
30 import dwt.layout.GridLayout;
|
|
31 import dwt.widgets.Button;
|
|
32 import dwt.widgets.Combo;
|
|
33 import dwt.widgets.Composite;
|
|
34 import dwt.widgets.DirectoryDialog;
|
|
35 import dwt.widgets.Display;
|
|
36 import dwt.widgets.FileDialog;
|
|
37 import dwt.widgets.Group;
|
|
38 import dwt.widgets.Label;
|
|
39 import dwt.widgets.List;
|
|
40 import dwt.widgets.Shell;
|
|
41 import dwt.widgets.Table;
|
|
42 import dwt.widgets.TableItem;
|
|
43 import dwt.widgets.Text;
|
|
44 import dwt.dwthelper.utils;
|
|
45
|
|
46 import tango.io.Stdout;
|
|
47
|
|
48 class ClipboardExample {
|
|
49 static const int SIZE = 60;
|
|
50 Clipboard clipboard;
|
|
51 Shell shell;
|
|
52 Text copyText;
|
|
53 Text pasteText;
|
|
54 Text copyRtfText;
|
|
55 Text pasteRtfText;
|
|
56 Text copyHtmlText;
|
|
57 Text pasteHtmlText;
|
|
58 Table copyFileTable;
|
|
59 Table pasteFileTable;
|
|
60 Text text;
|
|
61 Combo combo;
|
|
62 StyledText styledText;
|
|
63 Label status;
|
|
64
|
|
65 public void open(Display display) {
|
|
66 clipboard = new Clipboard(display);
|
|
67 shell = new Shell (display);
|
|
68 shell.setText("DWT Clipboard");
|
|
69 shell.setLayout(new FillLayout());
|
|
70
|
|
71 ScrolledComposite sc = new ScrolledComposite(shell, DWT.H_SCROLL | DWT.V_SCROLL);
|
|
72 Composite parent = new Composite(sc, DWT.NONE);
|
|
73 sc.setContent(parent);
|
|
74 parent.setLayout(new GridLayout(2, true));
|
|
75
|
|
76 Group copyGroup = new Group(parent, DWT.NONE);
|
|
77 copyGroup.setText("Copy From:");
|
|
78 GridData data = new GridData(GridData.FILL_BOTH);
|
|
79 copyGroup.setLayoutData(data);
|
|
80 copyGroup.setLayout(new GridLayout(3, false));
|
|
81
|
|
82 Group pasteGroup = new Group(parent, DWT.NONE);
|
|
83 pasteGroup.setText("Paste To:");
|
|
84 data = new GridData(GridData.FILL_BOTH);
|
|
85 pasteGroup.setLayoutData(data);
|
|
86 pasteGroup.setLayout(new GridLayout(3, false));
|
|
87
|
|
88 Group controlGroup = new Group(parent, DWT.NONE);
|
|
89 controlGroup.setText("Control API:");
|
|
90 data = new GridData(GridData.FILL_BOTH);
|
|
91 data.horizontalSpan = 2;
|
|
92 controlGroup.setLayoutData(data);
|
|
93 controlGroup.setLayout(new GridLayout(5, false));
|
|
94
|
|
95 /* Enable with Available Types *
|
|
96 Group typesGroup = new Group(parent, DWT.NONE);
|
|
97 typesGroup.setText("Available Types");
|
|
98 data = new GridData(GridData.FILL_BOTH);
|
|
99 data.horizontalSpan = 2;
|
|
100 typesGroup.setLayoutData(data);
|
|
101 typesGroup.setLayout(new GridLayout(2, false));
|
|
102 /**/
|
|
103
|
|
104 status = new Label(parent, DWT.BORDER);
|
|
105 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
106 data.horizontalSpan = 2;
|
|
107 data.heightHint = 60;
|
|
108 status.setLayoutData(data);
|
|
109
|
|
110 createTextTransfer(copyGroup, pasteGroup);
|
|
111 //TODO: Doesn't work
|
|
112 // createRTFTransfer(copyGroup, pasteGroup);
|
|
113 createHTMLTransfer(copyGroup, pasteGroup);
|
|
114 //TODO: Doesn't work
|
|
115 // createFileTransfer(copyGroup, pasteGroup);
|
|
116 createMyTransfer(copyGroup, pasteGroup);
|
|
117 createControlTransfer(controlGroup);
|
|
118 //TODO: Causes Segfault
|
|
119 // createAvailableTypes(typesGroup);
|
|
120
|
|
121 sc.setMinSize(parent.computeSize(DWT.DEFAULT, DWT.DEFAULT));
|
|
122 sc.setExpandHorizontal(true);
|
|
123 sc.setExpandVertical(true);
|
|
124
|
|
125 Point size = shell.computeSize(DWT.DEFAULT, DWT.DEFAULT);
|
|
126 Rectangle monitorArea = shell.getMonitor().getClientArea();
|
|
127 shell.setSize(Math.min(size.x, monitorArea.width - 20), Math.min(size.y, monitorArea.height - 20));
|
|
128 shell.open();
|
|
129 while (!shell.isDisposed ()) {
|
|
130 if (!display.readAndDispatch ()) display.sleep ();
|
|
131 }
|
|
132 clipboard.dispose();
|
|
133 }
|
|
134 void createTextTransfer(Composite copyParent, Composite pasteParent) {
|
|
135
|
|
136 // TextTransfer
|
|
137 Label l = new Label(copyParent, DWT.NONE);
|
|
138 l.setText("TextTransfer:"); //$NON-NLS-1$
|
|
139 copyText = new Text(copyParent, DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
140 copyText.setText("some\nplain\ntext");
|
|
141 GridData data = new GridData(GridData.FILL_HORIZONTAL);
|
|
142 data.heightHint = data.widthHint = SIZE;
|
|
143 copyText.setLayoutData(data);
|
|
144 Button b = new Button(copyParent, DWT.PUSH);
|
|
145 b.setText("Copy");
|
|
146 b.addSelectionListener(new class SelectionAdapter {
|
|
147 public void widgetSelected(SelectionEvent e) {
|
|
148 auto data = copyText.getText();
|
|
149 if (data.length > 0) {
|
|
150 status.setText("");
|
|
151 auto obj = new Object[1];
|
|
152 auto trans = new TextTransfer[1];
|
|
153 obj[0] = cast(Object) new ArrayWrapperString(data);
|
|
154 trans[0] = TextTransfer.getInstance();
|
|
155 clipboard.setContents(obj, trans);
|
|
156 } else {
|
|
157 status.setText("nothing to copy");
|
|
158 }
|
|
159 }
|
|
160 });
|
|
161
|
|
162 l = new Label(pasteParent, DWT.NONE);
|
|
163 l.setText("TextTransfer:"); //$NON-NLS-1$
|
|
164 pasteText = new Text(pasteParent, DWT.READ_ONLY | DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
165 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
166 data.heightHint = data.widthHint = SIZE;
|
|
167 pasteText.setLayoutData(data);
|
|
168 b = new Button(pasteParent, DWT.PUSH);
|
|
169 b.setText("Paste");
|
|
170 b.addSelectionListener(new class SelectionAdapter {
|
|
171 public void widgetSelected(SelectionEvent e) {
|
|
172 auto data = cast(ArrayWrapperString) clipboard.getContents(TextTransfer.getInstance());
|
|
173 if (data !is null) {
|
|
174 status.setText("");
|
|
175 pasteText.setText("begin paste>"~data.array~"<end paste");
|
|
176 } else {
|
|
177 status.setText("nothing to paste");
|
|
178 }
|
|
179 }
|
|
180 });
|
|
181 }
|
|
182 void createRTFTransfer(Composite copyParent, Composite pasteParent){
|
|
183 // RTF Transfer
|
|
184 Label l = new Label(copyParent, DWT.NONE);
|
|
185 l.setText("RTFTransfer:"); //$NON-NLS-1$
|
|
186 copyRtfText = new Text(copyParent, DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
187 copyRtfText.setText("some\nrtf\ntext");
|
|
188 GridData data = new GridData(GridData.FILL_HORIZONTAL);
|
|
189 data.heightHint = data.widthHint = SIZE;
|
|
190 copyRtfText.setLayoutData(data);
|
|
191 Button b = new Button(copyParent, DWT.PUSH);
|
|
192 b.setText("Copy");
|
|
193 b.addSelectionListener(new class SelectionAdapter {
|
|
194 public void widgetSelected(SelectionEvent e) {
|
|
195 auto data = copyRtfText.getText();
|
|
196 if (data.length > 0) {
|
|
197 status.setText("");
|
|
198 data = "{\\rtf1{\\colortbl;\\red255\\green0\\blue0;}\\uc1\\b\\i " ~ data ~ "}";
|
|
199 auto obj = new Object[1];
|
|
200 auto trans = new Transfer[1];
|
|
201 obj[0] = cast(Object) new ArrayWrapperString(data);
|
|
202 trans[0] = RTFTransfer.getInstance();
|
|
203 clipboard.setContents(obj, trans);
|
|
204 } else {
|
|
205 status.setText("nothing to copy");
|
|
206 }
|
|
207 }
|
|
208 });
|
|
209
|
|
210 l = new Label(pasteParent, DWT.NONE);
|
|
211 l.setText("RTFTransfer:"); //$NON-NLS-1$
|
|
212 pasteRtfText = new Text(pasteParent, DWT.READ_ONLY | DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
213 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
214 data.heightHint = data.widthHint = SIZE;
|
|
215 pasteRtfText.setLayoutData(data);
|
|
216 b = new Button(pasteParent, DWT.PUSH);
|
|
217 b.setText("Paste");
|
|
218 b.addSelectionListener(new class SelectionAdapter {
|
|
219 public void widgetSelected(SelectionEvent e) {
|
|
220 auto data = cast(ArrayWrapperString) clipboard.getContents(RTFTransfer.getInstance());
|
|
221 if (data !is null) {
|
|
222 status.setText("");
|
|
223 pasteRtfText.setText("begin paste>"~data.array~"<end paste");
|
|
224 } else {
|
|
225 status.setText("nothing to paste");
|
|
226 }
|
|
227 }
|
|
228 });
|
|
229 }
|
|
230 void createHTMLTransfer(Composite copyParent, Composite pasteParent){
|
|
231 // HTML Transfer
|
|
232 Label l = new Label(copyParent, DWT.NONE);
|
|
233 l.setText("HTMLTransfer:"); //$NON-NLS-1$
|
|
234 copyHtmlText = new Text(copyParent, DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
235 copyHtmlText.setText("<b>Hello World</b>");
|
|
236 GridData data = new GridData(GridData.FILL_HORIZONTAL);
|
|
237 data.heightHint = data.widthHint = SIZE;
|
|
238 copyHtmlText.setLayoutData(data);
|
|
239 Button b = new Button(copyParent, DWT.PUSH);
|
|
240 b.setText("Copy");
|
|
241 b.addSelectionListener(new class SelectionAdapter {
|
|
242 public void widgetSelected(SelectionEvent e) {
|
|
243 auto data = copyHtmlText.getText();
|
|
244 if (data.length > 0) {
|
|
245 status.setText("");
|
|
246 auto obj = new Object[1];
|
|
247 auto trans = new Transfer[1];
|
|
248 obj[0] = cast(Object) new ArrayWrapperString(data);
|
|
249 trans[0] = HTMLTransfer.getInstance();
|
|
250 clipboard.setContents(obj, trans);
|
|
251 } else {
|
|
252 status.setText("nothing to copy");
|
|
253 }
|
|
254 }
|
|
255 });
|
|
256
|
|
257 l = new Label(pasteParent, DWT.NONE);
|
|
258 l.setText("HTMLTransfer:"); //$NON-NLS-1$
|
|
259 pasteHtmlText = new Text(pasteParent, DWT.READ_ONLY | DWT.MULTI | DWT.BORDER | DWT.V_SCROLL | DWT.H_SCROLL);
|
|
260 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
261 data.heightHint = data.widthHint = SIZE;
|
|
262 pasteHtmlText.setLayoutData(data);
|
|
263 b = new Button(pasteParent, DWT.PUSH);
|
|
264 b.setText("Paste");
|
|
265 b.addSelectionListener(new class SelectionAdapter {
|
|
266 public void widgetSelected(SelectionEvent e) {
|
|
267 auto data = cast(ArrayWrapperString) clipboard.getContents(HTMLTransfer.getInstance());
|
|
268 if (data !is null) {
|
|
269 status.setText("");
|
|
270 pasteHtmlText.setText("begin paste>"~data.array~"<end paste");
|
|
271 } else {
|
|
272 status.setText("nothing to paste");
|
|
273 }
|
|
274 }
|
|
275 });
|
|
276 }
|
|
277 void createFileTransfer(Composite copyParent, Composite pasteParent){
|
|
278 //File Transfer
|
|
279 Label l = new Label(copyParent, DWT.NONE);
|
|
280 l.setText("FileTransfer:"); //$NON-NLS-1$
|
|
281
|
|
282 Composite c = new Composite(copyParent, DWT.NONE);
|
|
283 c.setLayout(new GridLayout(2, false));
|
|
284 GridData data = new GridData(GridData.FILL_HORIZONTAL);
|
|
285 c.setLayoutData(data);
|
|
286
|
|
287 copyFileTable = new Table(c, DWT.MULTI | DWT.BORDER);
|
|
288 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
289 data.heightHint = data.widthHint = SIZE;
|
|
290 data.horizontalSpan = 2;
|
|
291 copyFileTable.setLayoutData(data);
|
|
292
|
|
293 Button b = new Button(c, DWT.PUSH);
|
|
294 b.setText("Select file(s)");
|
|
295 b.addSelectionListener(new class SelectionAdapter {
|
|
296 public void widgetSelected(SelectionEvent e) {
|
|
297 FileDialog dialog = new FileDialog(shell, DWT.OPEN | DWT.MULTI);
|
|
298 auto result = dialog.open();
|
|
299 if (result !is null && result.length > 0){
|
|
300 //copyFileTable.removeAll();
|
|
301 //This cannot be used
|
|
302 //auto separator = System.getProperty("file.separator");
|
|
303 version(linux) {
|
|
304 auto separator = "/";
|
|
305 }
|
|
306 version(Windows) {
|
|
307 auto separator = "\\";
|
|
308 }
|
|
309 auto path = dialog.getFilterPath();
|
|
310 auto names = dialog.getFileNames();
|
|
311 for (int i = 0; i < names.length; i++) {
|
|
312 TableItem item = new TableItem(copyFileTable, DWT.NONE);
|
|
313 item.setText(path~separator~names[i]);
|
|
314 }
|
|
315 }
|
|
316 }
|
|
317 });
|
|
318 b = new Button(c, DWT.PUSH);
|
|
319 b.setText("Select directory");
|
|
320 b.addSelectionListener(new class SelectionAdapter {
|
|
321 public void widgetSelected(SelectionEvent e) {
|
|
322 DirectoryDialog dialog = new DirectoryDialog(shell, DWT.OPEN);
|
|
323 auto result = dialog.open();
|
|
324 if (result !is null && result.length > 0){
|
|
325 //copyFileTable.removeAll();
|
|
326 TableItem item = new TableItem(copyFileTable, DWT.NONE);
|
|
327 item.setText(result);
|
|
328 }
|
|
329 }
|
|
330 });
|
|
331
|
|
332 b = new Button(copyParent, DWT.PUSH);
|
|
333 b.setText("Copy");
|
|
334 b.addSelectionListener(new class SelectionAdapter {
|
|
335 public void widgetSelected(SelectionEvent e) {
|
|
336 TableItem[] items = copyFileTable.getItems();
|
|
337 if (items.length > 0){
|
|
338 status.setText("");
|
|
339 auto data = new char[][items.length];
|
|
340 for (int i = 0; i < data.length; i++) {
|
|
341 data[i] = items[i].getText();
|
|
342 }
|
|
343 auto obj = new Object[1];
|
|
344 auto trans = new Transfer[1];
|
|
345 obj[0] = cast(Object) new ArrayWrapperString2(data);
|
|
346 trans[0] = FileTransfer.getInstance();
|
|
347 clipboard.setContents(obj, trans);
|
|
348 } else {
|
|
349 status.setText("nothing to copy");
|
|
350 }
|
|
351 }
|
|
352 });
|
|
353
|
|
354 l = new Label(pasteParent, DWT.NONE);
|
|
355 l.setText("FileTransfer:"); //$NON-NLS-1$
|
|
356 pasteFileTable = new Table(pasteParent, DWT.MULTI | DWT.BORDER);
|
|
357 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
358 data.heightHint = data.widthHint = SIZE;
|
|
359 pasteFileTable.setLayoutData(data);
|
|
360 b = new Button(pasteParent, DWT.PUSH);
|
|
361 b.setText("Paste");
|
|
362 b.addSelectionListener(new class SelectionAdapter {
|
|
363 public void widgetSelected(SelectionEvent e) {
|
|
364 auto data = cast(ArrayWrapperString2) clipboard.getContents(FileTransfer.getInstance());
|
|
365 if (data !is null && data.array.length > 0) {
|
|
366 status.setText("");
|
|
367 pasteFileTable.removeAll();
|
|
368 foreach (s; data.array) {
|
|
369 TableItem item = new TableItem(pasteFileTable, DWT.NONE);
|
|
370 item.setText(s);
|
|
371 }
|
|
372 } else {
|
|
373 status.setText("nothing to paste");
|
|
374 }
|
|
375 }
|
|
376 });
|
|
377 }
|
|
378 void createMyTransfer(Composite copyParent, Composite pasteParent){
|
|
379 // MyType Transfer
|
|
380 // TODO
|
|
381 }
|
|
382 void createControlTransfer(Composite parent){
|
|
383 Label l = new Label(parent, DWT.NONE);
|
|
384 l.setText("Text:");
|
|
385 Button b = new Button(parent, DWT.PUSH);
|
|
386 b.setText("Cut");
|
|
387 b.addSelectionListener(new class SelectionAdapter {
|
|
388 public void widgetSelected(SelectionEvent e) {
|
|
389 text.cut();
|
|
390 }
|
|
391 });
|
|
392 b = new Button(parent, DWT.PUSH);
|
|
393 b.setText("Copy");
|
|
394 b.addSelectionListener(new class SelectionAdapter {
|
|
395 public void widgetSelected(SelectionEvent e) {
|
|
396 text.copy();
|
|
397 }
|
|
398 });
|
|
399 b = new Button(parent, DWT.PUSH);
|
|
400 b.setText("Paste");
|
|
401 b.addSelectionListener(new class SelectionAdapter {
|
|
402 public void widgetSelected(SelectionEvent e) {
|
|
403 text.paste();
|
|
404 }
|
|
405 });
|
|
406 text = new Text(parent, DWT.BORDER | DWT.MULTI | DWT.H_SCROLL | DWT.V_SCROLL);
|
|
407 GridData data = new GridData(GridData.FILL_HORIZONTAL);
|
|
408 data.heightHint = data.widthHint = SIZE;
|
|
409 text.setLayoutData(data);
|
|
410
|
|
411 l = new Label(parent, DWT.NONE);
|
|
412 l.setText("Combo:");
|
|
413 b = new Button(parent, DWT.PUSH);
|
|
414 b.setText("Cut");
|
|
415 b.addSelectionListener(new class SelectionAdapter {
|
|
416 public void widgetSelected(SelectionEvent e) {
|
|
417 combo.cut();
|
|
418 }
|
|
419 });
|
|
420 b = new Button(parent, DWT.PUSH);
|
|
421 b.setText("Copy");
|
|
422 b.addSelectionListener(new class SelectionAdapter {
|
|
423 public void widgetSelected(SelectionEvent e) {
|
|
424 combo.copy();
|
|
425 }
|
|
426 });
|
|
427 b = new Button(parent, DWT.PUSH);
|
|
428 b.setText("Paste");
|
|
429 b.addSelectionListener(new class SelectionAdapter {
|
|
430 public void widgetSelected(SelectionEvent e) {
|
|
431 combo.paste();
|
|
432 }
|
|
433 });
|
|
434 combo = new Combo(parent, DWT.NONE);
|
|
435 char[][] str = new char[][4];
|
|
436 str[0] = "Item 1";
|
|
437 str[1] = "Item 2";
|
|
438 str[2] = "Item 3";
|
|
439 str[3] = "A longer Item";
|
|
440 combo.setItems(str);
|
|
441
|
|
442 l = new Label(parent, DWT.NONE);
|
|
443 l.setText("StyledText:");
|
|
444 l = new Label(parent, DWT.NONE);
|
|
445 l.setVisible(false);
|
|
446 b = new Button(parent, DWT.PUSH);
|
|
447 b.setText("Copy");
|
|
448 b.addSelectionListener(new class SelectionAdapter {
|
|
449 public void widgetSelected(SelectionEvent e) {
|
|
450 styledText.copy();
|
|
451 }
|
|
452 });
|
|
453 b = new Button(parent, DWT.PUSH);
|
|
454 b.setText("Paste");
|
|
455 b.addSelectionListener(new class SelectionAdapter {
|
|
456 public void widgetSelected(SelectionEvent e) {
|
|
457 styledText.paste();
|
|
458 }
|
|
459 });
|
|
460 styledText = new StyledText(parent, DWT.BORDER | DWT.MULTI | DWT.H_SCROLL | DWT.V_SCROLL);
|
|
461 data = new GridData(GridData.FILL_HORIZONTAL);
|
|
462 data.heightHint = data.widthHint = SIZE;
|
|
463 styledText.setLayoutData(data);
|
|
464 }
|
|
465 void createAvailableTypes(Composite parent){
|
|
466 final List list = new List(parent, DWT.BORDER | DWT.H_SCROLL | DWT.V_SCROLL);
|
|
467 GridData data = new GridData(GridData.FILL_BOTH);
|
|
468 data.heightHint = 100;
|
|
469 list.setLayoutData(data);
|
|
470 Button b = new Button(parent, DWT.PUSH);
|
|
471 b.setText("Get Available Types");
|
|
472 b.addSelectionListener(new class SelectionAdapter {
|
|
473 public void widgetSelected(SelectionEvent e) {
|
|
474 list.removeAll();
|
|
475 auto names = clipboard.getAvailableTypeNames();
|
|
476 for (int i = 0; i < names.length; i++) {
|
|
477 list.add(names[i]);
|
|
478 }
|
|
479 }
|
|
480 });
|
|
481 }
|
|
482 }
|
|
483 void main() {
|
|
484 Stdout.formatln( "The ClipboardExample: still work left" );
|
|
485 Stdout.formatln( "todo: RTF, File Transfer, Available types");
|
|
486 Stdout.formatln( "line 300, there might be a better way to do" );
|
|
487 Stdout.formatln( "system independent path seperators in tango" );
|
|
488 Stdout.formatln( "" );
|
|
489
|
|
490
|
|
491 Display display = new Display();
|
|
492 (new ClipboardExample()).open(display);
|
|
493 display.dispose();
|
|
494 }
|
|
495
|