Changeset 167 for trunk/tests


Ignore:
Timestamp:
Jul 10, 2009, 11:37:50 PM (16 years ago)
Author:
lpino
Message:
  • A better testcase
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/SWT/java/SWT009_06.java

    r21 r167  
    3131
    3232        void initComponents() {
    33             shell.setText("Hello World TabFolder");
    34             shell.setSize(300, 300);
    35             shell.setLayout(new FillLayout());
    36             shell.setText("Simple Tabs");
    37             TabFolder tabFolder = new TabFolder(shell, SWT.NONE);
    38             TabItem tabItem = new TabItem(tabFolder, SWT.NONE);
     33            shell.setText("Tab Folder Example");
     34            shell.setSize(450, 250);
     35            final TabFolder tabFolder = new TabFolder(shell, SWT.BORDER);
     36            for (int loopIndex = 0; loopIndex < 10; loopIndex++) {
     37                TabItem tabItem = new TabItem(tabFolder, SWT.NULL);
     38                tabItem.setText("Tab " + loopIndex);
     39                Text text = new Text(tabFolder, SWT.BORDER);
     40                text.setText("This is page " + loopIndex);
     41                tabItem.setControl(text);
     42            }
     43            tabFolder.setSize(400, 200);
    3944            shell.open();
    4045               
Note: See TracChangeset for help on using the changeset viewer.