Package org.eclipse.swt.widgets

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


    Table table = viewer.getTable();
    int columnCount = table.getColumnCount();
    for (int columnNum = 0; columnNum < columnCount; columnNum++) {
      TableColumn column = table.getColumn(columnNum);
      int originalWidth = column.getWidth();
      column.pack();
      int newWidth = column.getWidth();
      if (newWidth < originalWidth) {
        column.setWidth(originalWidth);
      }
    }
View Full Code Here


            table.setSelection(0);
            break;
        default:
            table.setSelection(forward ? 0 : table.getItemCount() - 1);
        }
        tc.pack();
        table.pack();
        Rectangle tableBounds = table.getBounds();
        tableBounds.height = Math.min(tableBounds.height, table.getItemHeight() * MAX_ITEMS);
        table.setBounds(tableBounds);
        dialog.pack();
View Full Code Here

            table.setSelection(0);
            break;
        default:
            table.setSelection(forward ? 0 : table.getItemCount() - 1);
        }
        tc.pack();
        table.pack();
        Rectangle tableBounds = table.getBounds();
        tableBounds.height = Math.min(tableBounds.height, table.getItemHeight() * MAX_ITEMS);
        table.setBounds(tableBounds);
        dialog.pack();
View Full Code Here

            final TableColumn column = viewerColumn.getColumn();

            String attrName = _selectedAttributes.get(i);
            column.setMoveable(true);
            column.setText(attrName);
            column.pack();
            if(DEFAULT_COLUMN_WIDTHS.containsKey(attrName))
            {
                //retrieve the desired default width
                column.setWidth(DEFAULT_COLUMN_WIDTHS.get(attrName));
            }
View Full Code Here

    GridData gd2 = gd3;
    gd2.heightHint = 230;
    filesTable.setLayoutData(gd2);
    TableColumn column = new TableColumn(filesTable,SWT.NONE);
    column.setText("files");
    column.pack();
   
    initialize();
    dialogChanged();
    setControl(container);
  }
View Full Code Here

    GridData gd2 = gd3;
    gd2.heightHint = 230;
    filesTable.setLayoutData(gd2);
    TableColumn column = new TableColumn(filesTable,SWT.NONE);
    column.setText("files");
    column.pack();
   
    initialize();
    dialogChanged();
    setControl(container);
  }
View Full Code Here

    GridData gd = gd3;
    gd.heightHint = 230;
    filesTable.setLayoutData(gd);
    TableColumn column = new TableColumn(filesTable,SWT.NONE);
    column.setText("files");
    column.pack();
   
    initialize();
    dialogChanged();
    setControl(container);
  }
View Full Code Here

    TableColumn column3 = new TableColumn(table, SWT.CENTER, 2);
    column3.setText(FoldingPlugin.getMessage("userdefined.region.name"));
   
    column.pack();
    column2.pack();
    column3.pack();
   
    viewer = new TableViewer(table);
   
    CellEditor[] editors = new CellEditor[3];
    editors[0] = new CheckboxCellEditor(table);
View Full Code Here

      item.setText(3, commandConfig.getResourceType().getLabel());
    }
    for (int i = 0; i < this.tableCommands.getColumnCount(); i++)
    {
      TableColumn column = this.tableCommands.getColumn(i);
      column.pack();
      if (column.getWidth() > MAX_COLUMN_WIDTH)
      {
        column.setWidth(MAX_COLUMN_WIDTH);
      }
    }
View Full Code Here

    int columnWidth = 0;
    for (int i = 0; i < columns.length; i++) {
      TableColumn column = columns[i];
      int minWidth = column.getWidth();

      column.pack();
      if ((column.getWidth() < minWidth) && (i < columns.length - 1)) {
        column.setWidth(minWidth);
      }
      if (i < columns.length - 1) {
        columnWidth += column.getWidth();
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.