javax.swing.JTable.getColumnClass()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(4.0k)|赞(0)|评价(0)|浏览(171)

本文整理了Java中javax.swing.JTable.getColumnClass()方法的一些代码示例,展示了JTable.getColumnClass()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JTable.getColumnClass()方法的具体详情如下:
包路径:javax.swing.JTable
类名称:JTable
方法名:getColumnClass

JTable.getColumnClass介绍

暂无

代码示例

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}
@Override

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}
@Override

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}
@Override

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}
@Override

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
    return column == 1 ? Boolean.class : super.getColumnClass(column);
  }
};

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
    return column == 1 ? Boolean.class : super.getColumnClass(column);
  }
};

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}

代码示例来源:origin: libgdx/libgdx

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}

代码示例来源:origin: groovy/groovy-core

tcr = table.getTableHeader().getDefaultRenderer();
} else {
  tcr = table.getDefaultRenderer(table.getColumnClass(column));

代码示例来源:origin: ron190/jsql-injection

});
this.tableValues.setDefaultRenderer(this.tableValues.getColumnClass(2),
  (JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) -> {

代码示例来源:origin: org.appdapter/org.appdapter.lib.gui

public Class getColumnClass() {
  if (columnClass != null)
    return columnClass;
  return myTable.getColumnClass(columnNumber);
}

代码示例来源:origin: com.badlogicgames.gdx/gdx-tools

public Class getColumnClass (int column) {
  return column == 1 ? Boolean.class : super.getColumnClass(column);
}
@Override

代码示例来源:origin: senbox-org/snap-desktop

@Override
  public Class getColumnClass(int column) {
    if (column == 2) {
      return Boolean.class;
    } else {
      return super.getColumnClass(column);
    }
  }
};

代码示例来源:origin: com.cedarsoft.commons.swing/common

@Nonnull
private TableCellRenderer findRendererToUse( @Nonnull JTable table, int column ) {
 if ( delegate != null ) {
  return delegate;
 } else {
  return table.getDefaultRenderer( table.getColumnClass( column ) );
 }
}

代码示例来源:origin: org.softsmithy.lib/lib-core

protected Class getClass(JTable table, int row, int column) {
  if (table instanceof JCellTable) { // should be raplaced with polymorphism
    return ((JCellTable) table).getCellClass(row, column);
  } else {
    return table.getColumnClass(column);
  }
}

代码示例来源:origin: stackoverflow.com

//creating a table
 MyTableModel mod = new MyTableModel(data, columnNames);
 JTable table = new JTable(mod);
 table.setVisible(true);
 table.getColumnClass(1); // will return the data type class of first column
 table.isCellEditable(1, 0);

代码示例来源:origin: apache/felix

private void buildTable(){
  dataModel = new DataModel();
  table = new JTable(dataModel);
  table.setDefaultRenderer(table.getColumnClass(1), new LinkCellRenderer());
}

代码示例来源:origin: stackoverflow.com

JTable table = new JTable(my_rows, my_header);

for (int c = 0; c < table.getColumnCount(); c++)
{
  Class<?> col_class = table.getColumnClass(c);
  table.setDefaultEditor(col_class, null);        // remove editor
}

代码示例来源:origin: de.sciss/jtreetable

public void loadEditor(Class<?> cls, int col) {
  treeTableEditor = this;
  if (col == treeTable.getHierarchicalColumn()) {
    if (defaultTreeEditor == null)
      defaultTreeEditor = new TreeEditor(table.getDefaultEditor(Object.class));
    defaultEditor = defaultTreeEditor;
  } else {
    defaultEditor = table.getDefaultEditor(table.getColumnClass(col));
  }
}

代码示例来源:origin: omegat-org/omegat

public CharTableAutoCompleterView() {
  super(OStrings.getString("AC_CHARTABLE_VIEW"));
  model = new CharTableModel(null);
  getTable().setModel(model);
  getTable().setShowGrid(true);
  getTable().setGridColor(Color.gray);
  renderer = (DefaultTableCellRenderer) getTable().getDefaultRenderer(getTable().getColumnClass(0));
  renderer.setHorizontalAlignment(SwingConstants.CENTER);
  setSelection(new Point(0, 0));
}

相关文章

JTable类方法