Package com.intellij.ui.table

Examples of com.intellij.ui.table.JBTable


    return new StripeTable(dataModel);
  }


  public static JTable createTable(final TableModel dataModel) {
    return new JBTable(dataModel);
  }
View Full Code Here


    return new JBTable(dataModel);
  }


  public static JTable createTable() {
    return new JBTable();
  }
View Full Code Here

        init();
    }

    public void init() {
        setLayout(new BorderLayout());
        myTable = new JBTable();
        myTextArea = new JTextArea(0, 0);
        myTextArea.setEditable(false);
        JScrollPane scrollPane = ScrollPaneFactory.createScrollPane(myTable);
        mySplitPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT, true, scrollPane,
                ScrollPaneFactory.createScrollPane(myTextArea));
View Full Code Here

  private final ExcludedTableModel myExcludedTableModel;
  private final JComponent myComponent;

  public JstdCoverageSection(@NotNull final Project project) {
    myExcludedTableModel = new ExcludedTableModel();
    final JBTable table = new JBTable(myExcludedTableModel);
    table.getEmptyText().setText("No files excluded from coverage");
    table.setRowHeight((int)(table.getRowHeight() * 1.2));
    Dimension preferredScrollableViewportSize = new Dimension(
      table.getPreferredScrollableViewportSize().width,
      table.getRowHeight() * 6
    );
    table.setPreferredScrollableViewportSize(preferredScrollableViewportSize);
    table.getSelectionModel().setSelectionMode(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION);
    table.setMinimumSize(preferredScrollableViewportSize);

    JTableHeader tableHeader = table.getTableHeader();
    tableHeader.setResizingAllowed(false);
    tableHeader.setReorderingAllowed(false);
    tableHeader.setPreferredSize(new Dimension(
      tableHeader.getPreferredSize().width,
      (int) (tableHeader.getPreferredSize().height * 1.2)
 
View Full Code Here

    myPlaceInProjectWideRadioButton.addChangeListener(listener);
    myPlaceInThisPathRadioButton.addChangeListener(listener);
    myPlaceInCompilerOutputPathRadioButton.addChangeListener(listener);

    myAdditionalJARContentsTableModel = new AdditionalJARContentsTableModel();
    myAdditionalJARContentsTable = new JBTable(myAdditionalJARContentsTableModel);
    TableColumn col = myAdditionalJARContentsTable.getColumnModel().getColumn(0);
    FileSelectorTableCellEditor selectorTableCellEditor = new FileSelectorTableCellEditor(project, myEditorContext.getModule());
    col.setCellEditor(selectorTableCellEditor);
    selectorTableCellEditor.addCellEditorListener(new CellEditorListener() {
      @Override
View Full Code Here

    public static JScrollPane table(TableModel model) {
        return table(model, null);
    }

    public static JScrollPane table(TableModel model, final AtomicInteger selectedRow) {
        final JBTable table = createTable(model);
        table.setAutoCreateRowSorter(true);
        return ScrollPaneFactory.createScrollPane(withSelectionCallback(table, selectedRow));
    }
View Full Code Here

        table.setAutoCreateRowSorter(true);
        return ScrollPaneFactory.createScrollPane(withSelectionCallback(table, selectedRow));
    }

    private static JBTable createTable(TableModel model) {
        final JBTable table = new JBTable(model);
        table.setDefaultRenderer(Boolean.class, new BooleanCellRenderer());
        return table;
    }
View Full Code Here

            cssDirectories.add(new CssDirectory(cssDirectory));
        }

        final ColumnInfo[] columns = { new CssDirectoryColumn() };
        profileMappingModel = new ListTableModel<CssDirectory>(columns, cssDirectories, 0);
        profileMappingTable = new JBTable(profileMappingModel);
    }
View Full Code Here

                return new JButton[]{};
            }

            @Override
            protected JComponent createMainComponent() {
                table = new JBTable(tableModel);
                table.getEmptyText().setText("No server configuration set");
                table.getSelectionModel().setSelectionMode(ListSelectionModel.SINGLE_SELECTION);

                TableColumn autoConnectColumn = table.getColumnModel().getColumn(2);
                int width = table.getFontMetrics(table.getFont()).stringWidth(table.getColumnName(2)) + 10;
View Full Code Here

        prepareTableData(usageMappings, dataRows, names);

        if (names.size() > 0)
        {
            AbstractTableModel tableModel = new MappingsTableModel(names);
            final JBTable table = new JBTable(tableModel);
            table.setCellSelectionEnabled(true);
            table.setAutoCreateRowSorter(true);

            JPanel jPanel = new JPanel();
            jPanel.setLayout(new BorderLayout());
            JButton button = new JButton(REFRESH_ALL, IconLoader.getIcon("/vcs/refresh.png"));
            button.addMouseListener(new MouseAdapter()
            {
                @Override public void mouseClicked(MouseEvent e)
                {
                    refreshValues();
                }
            });
            jPanel.add(button, BorderLayout.NORTH);

            JBScrollPane jbScrollPane = new JBScrollPane(table);
            jbScrollPane.getVerticalScrollBar().setUnitIncrement(16);

            jPanel.add(jbScrollPane, BorderLayout.CENTER);

            Content content = ContentFactory.SERVICE.getInstance().createContent(jPanel, tableName, false);
            contentManager.addContent(content);

            table.addMouseListener(new MyMouseAdapter(table, dataRows, project));
            table.setEnableAntialiasing(true);

            return content;
        }

        return null;
View Full Code Here

TOP

Related Classes of com.intellij.ui.table.JBTable

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.