Package org.eclipse.swt.layout

Examples of org.eclipse.swt.layout.FillLayout


  }

  public Composite configSectionCreate(final Composite parent) {
    if (!AzureusCoreFactory.isCoreRunning()) {
      Composite cSection = new Composite(parent, SWT.NULL);
      cSection.setLayout(new FillLayout());
      Label lblNotAvail = new Label(cSection, SWT.WRAP);
      Messages.setLanguageText(lblNotAvail, "core.not.available");
      return cSection;
    }
View Full Code Here


  }

  public static void main(String[] args) {
    Display display = new Display();
    Shell shell = new Shell(display, SWT.SHELL_TRIM);
    shell.setLayout(new FillLayout(SWT.VERTICAL));

    final Label label = new Label(shell, SWT.BORDER);

    final Text text = new Text(shell, SWT.BORDER);
    text.addModifyListener(new ModifyListener() {
View Full Code Here

        GridData gridData;

        Composite cSection = new Composite(parent, SWT.NULL);
       
        if (!AzureusCoreFactory.isCoreRunning()) {
          cSection.setLayout(new FillLayout());
          Label lblNotAvail = new Label(cSection, SWT.WRAP);
          Messages.setLanguageText(lblNotAvail, "core.not.available");
          return cSection;
        }
       
View Full Code Here

    initialized = true;
    refresh();
  }

  private void createPieceDistPanel() {
    comp.setLayout(new FillLayout());
    //pieceDistComposite = new Composite(parent, SWT.NONE);
    pieceDistCanvas = new Canvas(comp,SWT.NONE);
    pieceDistCanvas.addListener(SWT.Paint, new Listener() {
      public void handleEvent(Event event) {
        if (imgToPaint != null && !imgToPaint.isDisposed()) {
View Full Code Here

    splash = new Shell(display, SWT.NO_TRIM);
    splash.setText(Constants.APP_NAME);
    Utils.setShellIcon(splash);

    splash.setLayout(new FillLayout());
    canvas = new Canvas(splash, SWT.DOUBLE_BUFFERED);

    ImageLoader imageLoader = ImageLoader.getInstance();
    background = imageLoader.getImage(IMG_SPLASH);
    if (ImageLoader.isRealImage(background)) {
View Full Code Here

      final Shell parentShell = Utils.findAnyShell();
     
      final Shell shell = current_shell =
        ShellFactory.createShell(parentShell, SWT.BORDER | SWT.APPLICATION_MODAL | SWT.TITLE | SWT.DIALOG_TRIM );
     
      shell.setLayout(new FillLayout());
     
      if (parentShell != null) {
        parentShell.setCursor(shell.getDisplay().getSystemCursor(SWT.CURSOR_WAIT));
      }
     
View Full Code Here

        if (d == null)
          return;

        // We don't get mouse down notifications on trim or borders..
        toolTipShell = new Shell(table.getShell(), SWT.ON_TOP);
        FillLayout f = new FillLayout();
        try {
          f.marginWidth = 3;
          f.marginHeight = 1;
        } catch (NoSuchFieldError e) {
          /* Ignore for Pre 3.0 SWT.. */
 
View Full Code Here

        _toolbarComposite.setVisible(false);
  

        _editorComposite= new Composite(composite, SWT.NONE);
        _editorComposite.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
        FillLayout fillLayout= new FillLayout(SWT.VERTICAL);
        fillLayout.marginHeight= 0;
        fillLayout.marginWidth= 0;
        fillLayout.spacing= 0;
        _editorComposite.setLayout(fillLayout);
       
View Full Code Here

            Composite composite = new Composite(parent, SWT.NONE);
            GridData data = new GridData(GridData.FILL, GridData.FILL, true, true);
            data.minimumWidth = 500;
            data.minimumHeight = 200;
            composite.setLayoutData(data);
            composite.setLayout(new FillLayout());
            _text = new Text(composite, SWT.MULTI|SWT.V_SCROLL);
            _text.setText(_initialValue);
            return composite;
        }
View Full Code Here

        GridData initialValuesSectionLayoutData = new GridData(GridData.FILL_BOTH);
        _initialValuesSection.setLayoutData(initialValuesSectionLayoutData);

        // item subform - text values
        _initialTextValuesSectionClient = toolkit.createComposite(_initialValuesSection);
        _initialTextValuesSectionClient.setLayout(new FillLayout());
        _tblItemTextValues = new EditableTableControl<PrimitiveTypeBean<String>>(_initialTextValuesSectionClient, SWT.NONE);
        _itemTextValuesModel = new PrimitiveTypeBeanListTableModel<String>(true);
        _itemTextValuesModel.addListener(new BeanListTableModelListener() {
           
            public void update(Object bean) {
                _model.fireModelChanged();               
            }
           
            public void remove(Object bean) {
                _model.fireModelChanged();
            }
           
            public void refresh(List beans) {
            }
           
            public void add(Object bean) {
                _model.fireModelChanged();               
            }
        });
        _tblItemTextValues.init(new String[] {"#", "Value"}, _itemTextValuesModel);
        CellEditor[] cellEditors = new CellEditor[2];
        cellEditors[0] = null;
        cellEditors[1] = new TextCellEditor(_tblItemTextValues.getTable());
        _tblItemTextValues.getTableViewer().setCellEditors(cellEditors);
       
        _tblItemTextValues.getButton(EditableTableControl.BUTTON_ADD).addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {
            public void widgetSelected(org.eclipse.swt.events.SelectionEvent e) {
                WGContentItemDefinitionModel model = (WGContentItemDefinitionModel)_subformModels.get(SUBFORM_CONTENT_ITEM_DEFINITION);
                if (_itemTextValuesModel.getBeans().size() > 0) {                   
                    _chkItemList.setSelection(true);
                    model.setList(true);
                }
                handleAdd(_tblItemTextValues, "");
            }
        });

        _tblItemTextValues.getButton(EditableTableControl.BUTTON_REMOVE).addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {
            public void widgetSelected(org.eclipse.swt.events.SelectionEvent e) {
                handleRemove(_tblItemTextValues);
            }
        });
       
       
        // item subform - boolean values
        _initialBooleanValuesSectionClient = toolkit.createComposite(_initialValuesSection);
        _initialBooleanValuesSectionClient.setLayout(new FillLayout());
        _tblItemBooleanValues = new EditableTableControl<PrimitiveTypeBean<Boolean>>(_initialBooleanValuesSectionClient, SWT.NONE);
        _itemBooleanValuesModel = new PrimitiveTypeBeanListTableModel<Boolean>(true);
        _itemBooleanValuesModel.addListener(new BeanListTableModelListener() {
           
            public void update(Object bean) {
                _model.fireModelChanged();               
            }
           
            public void remove(Object bean) {
                _model.fireModelChanged();
            }
           
            public void refresh(List beans) {
            }
           
            public void add(Object bean) {
                _model.fireModelChanged();               
            }
        });
        _tblItemBooleanValues.init(new String[] {"#", "Value"}, _itemBooleanValuesModel);
        cellEditors = new CellEditor[2];
        cellEditors[0] = null;
        cellEditors[1] = new CheckboxCellEditor(_tblItemBooleanValues.getTable());
        _tblItemBooleanValues.getTableViewer().setCellEditors(cellEditors);       
       
        _tblItemBooleanValues.getButton(EditableTableControl.BUTTON_ADD).addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {
            public void widgetSelected(org.eclipse.swt.events.SelectionEvent e) {
                WGContentItemDefinitionModel model = (WGContentItemDefinitionModel)_subformModels.get(SUBFORM_CONTENT_ITEM_DEFINITION);
                if (_itemBooleanValuesModel.getBeans().size() > 0) {                   
                    _chkItemList.setSelection(true);
                    model.setList(true);
                }
                handleAdd(_tblItemBooleanValues, false);               
            }
        });

        _tblItemBooleanValues.getButton(EditableTableControl.BUTTON_REMOVE).addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {
            public void widgetSelected(org.eclipse.swt.events.SelectionEvent e) {
                handleRemove(_tblItemBooleanValues);
            }
        });
       
       
        // item subform - number values
        _initialNumberValuesSectionClient = toolkit.createComposite(_initialValuesSection);
        _initialNumberValuesSectionClient.setLayout(new FillLayout());
        _tblItemNumberValues = new EditableTableControl<PrimitiveTypeBean<Number>>(_initialNumberValuesSectionClient, SWT.NONE);        
        _itemNumberValuesModel = new PrimitiveTypeBeanListTableModel<Number>(true);
        _itemNumberValuesModel.addListener(new BeanListTableModelListener() {
           
            public void update(Object bean) {
View Full Code Here

TOP

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

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.