Package org.eclipse.swt.layout

Examples of org.eclipse.swt.layout.RowLayout


        Label spacer;

        // campaign name and guid (0, 0 -> 4, 1)
        Composite nameComp = new Composite(container, SWT.NONE);
        nameComp.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 4, 1));
        nameComp.setLayout(new RowLayout(SWT.VERTICAL));
        {
            campaignName = new Text(nameComp, SWT.LEFT);
            campaignName.setText(campaign.getName());
            campaignName.setToolTipText(campaign.getDescription());
            campaignName.setEditable(false);
View Full Code Here


        GridData timelineData = new GridData(GridData.FILL_HORIZONTAL);
        timelineData.horizontalSpan = 3;
        timelineGroup.setLayoutData(timelineData);
        timelineGroup.setText("Timeline"); // TODO: localize
       
        RowLayout timelineLayout = new RowLayout();
        timelineLayout.wrap = false;
        timelineLayout.fill = true;
        timelineLayout.pack = false;
        timelineGroup.setLayout(timelineLayout);
       
View Full Code Here

   
    private void addTimelineBox(Composite group)
    {
        Composite comp = new Composite(group, SWT.NONE);
       
        RowLayout layout = new RowLayout();
        layout.type = SWT.VERTICAL;
        layout.wrap = false;
        layout.fill = true;
        layout.pack = false;
        comp.setLayout(layout);
View Full Code Here

       

        // boolean field
        if (type.equals("bool")) {
          Composite comp = new Composite(composite, SWT.NONE);
          comp.setLayout(new RowLayout());
          Button yesButton = new Button(comp, SWT.RADIO);
          yesButton.setText("Yes");
          yesButton.setData("ID_" + i + "_True");
         
          yesButton.addSelectionListener(this);
         
          Button noButton = new Button(comp, SWT.RADIO);
          noButton.setText("No");
          noButton.setData("ID_" + i + "_False");
          noButton.addSelectionListener(this);
          comp.setLayoutData(tgd);
        }
        // text field
        else if (type.equals("text")) {
          Text nameText = new Text(composite, SWT.BORDER);
          nameText.setData("ID_" + i);
          nameText.addModifyListener(this);
          GridData gridData = new GridData();
          gridData.horizontalAlignment = SWT.FILL;
          gridData.grabExcessHorizontalSpace = true;
          nameText.setLayoutData(gridData);
          // nameText.setText("");
        }
        // multi text field
        else if (type.equals("multiline")) {
          Text nameText = new Text(composite, SWT.BORDER | SWT.WRAP
              | SWT.MULTI);
          nameText.setData("ID_" + i);
          nameText.addModifyListener(this);
         
          GridData gridData = new GridData();
          gridData.horizontalAlignment = SWT.FILL;
          gridData.grabExcessHorizontalSpace = true;
          gridData.verticalAlignment = SWT.FILL;
          gridData.grabExcessVerticalSpace = true;
          gridData.minimumHeight = 60;
          nameText.setLayoutData(gridData);
          // addressText.setText("This text field and the List\nbelow share any excess space.");
        }
        // 5 option field
        else if (type.equals("5options")) {
          Composite comp = new Composite(composite, SWT.NONE);
          comp.setLayout(new RowLayout());
          for (int j = 0; j < 5; j++) {
            Button optionButton = new Button(comp, SWT.RADIO);
            optionButton.setText(Integer.toString(j + 1));
            optionButton.setData("ID_" + i + "_" + j);
            optionButton.addSelectionListener(this);
View Full Code Here

    final ScrolledComposite scrollComposite = new ScrolledComposite(parent,
        SWT.V_SCROLL | SWT.BORDER);

    cmp = new Composite(scrollComposite, SWT.NONE);

    RowLayout layout = new RowLayout(SWT.HORIZONTAL);
    layout.wrap = true;
    cmp.setLayout(layout);

    scrollComposite.setContent(cmp);
    scrollComposite.setExpandVertical(true);
View Full Code Here

    final ScrolledComposite scrollComposite = new ScrolledComposite(parent,
        SWT.V_SCROLL | SWT.BORDER);

    cmp = new Composite(scrollComposite, SWT.NONE);
   
    RowLayout layout = new RowLayout(SWT.HORIZONTAL);
    layout.wrap = true;
    cmp.setLayout(layout);

    scrollComposite.setContent(cmp);
    scrollComposite.setExpandVertical(true);
View Full Code Here

        String type = el.getAttribute("type");
       
        // boolean field
        if (type.equals("bool")) {
          Composite comp = new Composite(composite, SWT.NONE);
          comp.setLayout(new RowLayout());
          Button yesButton = new Button(comp, SWT.RADIO);
          yesButton.setText("Yes");           
            Button noButton = new Button(comp, SWT.RADIO);
            noButton.setText("No");
        }
        // text field
        else if (type.equals("text")) {
          Text nameText = new Text(composite, SWT.BORDER);
          GridData gridData = new GridData();
          gridData.horizontalAlignment = SWT.FILL;
          gridData.grabExcessHorizontalSpace = true;
          nameText.setLayoutData(gridData);
          //nameText.setText("");
        }
        // multi text field
        else if (type.equals("multiline")) {
          Text addressText = new Text(composite, SWT.BORDER | SWT.WRAP | SWT.MULTI);
          GridData gridData = new GridData();
          gridData.horizontalAlignment = SWT.FILL;
          gridData.grabExcessHorizontalSpace = true;
          gridData.verticalAlignment = SWT.FILL;
          gridData.grabExcessVerticalSpace = true;
          addressText.setLayoutData(gridData);
          //addressText.setText("This text field and the List\nbelow share any excess space.");
        }
        // 5 option field
        else if (type.equals("5options")) {
          Composite comp = new Composite(composite, SWT.NONE);
          comp.setLayout(new RowLayout());
        }
        // explication field
        else if (type.equals("label")) {
         
        }
View Full Code Here

        stackComposite.layout();

        // Create a composite with a RowLayout to contain the
        // "Select All" and "Deselect All" buttons.
        Composite buttonComposite = new Composite(topLevel, SWT.NONE);
        RowLayout rowLayout = new RowLayout();
        rowLayout.spacing = HORIZONTAL_BUTTON_GAP;
        buttonComposite.setLayout(rowLayout);

        // Create the "Select All" button.
        selectAllButton = new Button(buttonComposite, SWT.PUSH);
View Full Code Here

        descriptionLabel.setLayoutData(data);

        Composite buttons = new Composite(descriptionBar, SWT.NONE);
        data = new GridData(GridData.HORIZONTAL_ALIGN_END);
        buttons.setLayoutData(data);
        buttons.setLayout(new RowLayout(SWT.HORIZONTAL));

        createButtons(buttons);

        setDefaultColour(descriptionBar);
        setDefaultColour(descriptionLabel);
View Full Code Here

      setPageComplete(false);
  }
 
  public void createControl(Composite parent) {
    Composite portComposite = new Composite(parent, SWT.NONE);
    portComposite.setLayout(new RowLayout(SWT.HORIZONTAL));
   
    Label portLabel = new Label(portComposite, SWT.NONE);
    portLabel.setText("Port:");
   
    portText = new Text(portComposite, SWT.BORDER);
View Full Code Here

TOP

Related Classes of org.eclipse.swt.layout.RowLayout

Copyright © 2018 www.massapicom. 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.