Package org.eclipse.swt.widgets

Examples of org.eclipse.swt.widgets.Text.pack()


    greedy4d1l1Text.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 3, 1));
    greedy4d1l1Text.setData("l1");
    greedy4d1l1Text.setText("1");
    greedy4d1l1Text.setToolTipText("Dunno yet :)");
    greedy4d1l1Text.addModifyListener(textListener);
    greedy4d1l1Text.pack();
    greedy4d1l1Text.setEnabled(false);
   
    Label greedy4d1l2Label = new Label(optionsGroup, SWT.NONE);
    greedy4d1l2Label.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false, 1, 1));
    greedy4d1l2Label.setText("l2 = ");
View Full Code Here


    greedy4d1l2Text.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 3, 1));
    greedy4d1l2Text.setData("l2");
    greedy4d1l2Text.setText("1");
    greedy4d1l2Text.setToolTipText("Dunno yet :)");
    greedy4d1l2Text.addModifyListener(textListener);
    greedy4d1l2Text.pack();
    greedy4d1l2Text.setEnabled(false);
   
    Label greedy2modKLabel = new Label(optionsGroup, SWT.NONE);
    greedy2modKLabel.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false, 1, 1));
    greedy2modKLabel.setText("K = ");
View Full Code Here

    greedy2modKText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 3, 1));
    greedy2modKText.setData("K");
    greedy2modKText.setText("10");
    greedy2modKText.setToolTipText("Dunno yet :)");
    greedy2modKText.addModifyListener(textListener);
    greedy2modKText.pack();
    greedy2modKText.setEnabled(false);
   
    Label greedy2modLLabel = new Label(optionsGroup, SWT.NONE);
    greedy2modLLabel.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false, 1, 1));
    greedy2modLLabel.setText("r = ");
View Full Code Here

    greedy2modrText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 3, 1));
    greedy2modrText.setData("r");
    greedy2modrText.setText("1");
    greedy2modrText.setToolTipText("Dunno yet :)");
    greedy2modrText.addModifyListener(textListener);
    greedy2modrText.pack();
    greedy2modrText.setEnabled(false);

    Label reschedM = new Label(optionsGroup, SWT.NONE);
    reschedM.setLayoutData(new GridData(SWT.BEGINNING, SWT.CENTER, false, false, 1, 1));
    reschedM.setText("m = ");
View Full Code Here

    greedy4m.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 7, 1));
    greedy4m.setData("m");
    greedy4m.setText("1");
    greedy4m.setToolTipText("Number of scheduling periods. Suggested values are: 1, 2, 3, 5, 7, ...");
    greedy4m.addModifyListener(textListener);
    greedy4m.pack();
    greedy4m.setEnabled(false);

    return composite;
  }
View Full Code Here

    Text statsText = new Text(shell, SWT.MULTI | SWT.READ_ONLY);
    statsText.setBackground(shell.getBackground());
    statsText.setLayoutData(formData(new FormAttachment(iconLabel), new FormAttachment(100, -20), new FormAttachment(titleLabel), null));
    statsText.setText(message);
    statsText.pack();

    Point buttonSize = button.getSize();
    button.setLayoutData(formData(buttonSize.x, buttonSize.y, null, new FormAttachment(100), new FormAttachment(statsText), null));

    shell.pack();
View Full Code Here

    if (editable) {
        TableEditor regionEditor = new TableEditor(table);
       
      final Text regionText = new Text(table,SWT.SINGLE);
      regionText.setText(key);
      regionText.pack();
     
      regionEditor.minimumWidth = 90;
      regionEditor.horizontalAlignment = SWT.LEFT;
      regionEditor.setEditor(regionText, item, 2);
      fTextFields.put(regionText,key+".name");
View Full Code Here

    public int getIdealWidth() {
        Text text = (Text) getSWTControl();
        String old = text.getText();
        text.setText(_sizeText);
        text.pack();
        int width = text.getSize().x;
        text.setText(old);
        return width;
    }
View Full Code Here

    public int getIdealHeight() {
        Text text = (Text) getSWTControl();
        String old = text.getText();
        text.setText(_sizeText);
        text.pack();
        int height = text.getSize().y;
        text.setText(old);
        return height;
    }
View Full Code Here

            //Text Line 1
            Text text = new Text(errorShell, SWT.MULTI | SWT.BORDER);
            GridData gridData = new GridData(GridData.FILL_BOTH);
            text.setLayoutData( gridData );
            text.setText(message);
            text.pack();

            // OK Button
            Button ok = new Button(errorShell, SWT.PUSH);
            gridData = new GridData(GridData.HORIZONTAL_ALIGN_END);
            gridData.horizontalSpan = 2;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.