/** * Sets the <code>ColumnFactory</code> to use for column creation and * configuration. The default value is the shared application ColumnFactory. * <p> * * Note: this method has no side-effect, that is existing columns are * <b>not</b> re-created automatically, client code must trigger it * manually. * * @param columnFactory the factory to use, <code>null</code> indicates to * use the shared application factory. * * @see #getColumnFactory() * @see org.jdesktop.swingx.table.ColumnFactory */ public void setColumnFactory(ColumnFactory columnFactory) { /* * * TODO auto-configure columns on set? or add public table api to do so? * Mostly, this is meant to be done once in the lifetime of the table, * preferably before a model is set ... overshoot? */ ColumnFactory old = getColumnFactory(); this.columnFactory = columnFactory; firePropertyChange("columnFactory", old, getColumnFactory()); }
/** * Sets the <code>ColumnFactory</code> to use for column creation and * configuration. The default value is the shared application ColumnFactory. * <p> * * Note: this method has no side-effect, that is existing columns are * <b>not</b> re-created automatically, client code must trigger it * manually. * * @param columnFactory the factory to use, <code>null</code> indicates to * use the shared application factory. * * @see #getColumnFactory() * @see org.jdesktop.swingx.table.ColumnFactory */ public void setColumnFactory(ColumnFactory columnFactory) { /* * * TODO auto-configure columns on set? or add public table api to do so? * Mostly, this is meant to be done once in the lifetime of the table, * preferably before a model is set ... overshoot? */ ColumnFactory old = getColumnFactory(); this.columnFactory = columnFactory; firePropertyChange("columnFactory", old, getColumnFactory()); }
/** * Sets the <code>ColumnFactory</code> to use for column creation and * configuration. The default value is the shared application ColumnFactory. * <p> * * Note: this method has no side-effect, that is existing columns are * <b>not</b> re-created automatically, client code must trigger it * manually. * * @param columnFactory the factory to use, <code>null</code> indicates to * use the shared application factory. * * @see #getColumnFactory() * @see org.jdesktop.swingx.table.ColumnFactory */ public void setColumnFactory(ColumnFactory columnFactory) { /* * * TODO auto-configure columns on set? or add public table api to do so? * Mostly, this is meant to be done once in the lifetime of the table, * preferably before a model is set ... overshoot? */ ColumnFactory old = getColumnFactory(); this.columnFactory = columnFactory; firePropertyChange("columnFactory", old, getColumnFactory()); }
/** * Sets the <code>ColumnFactory</code> to use for column creation and * configuration. The default value is the shared application ColumnFactory. * <p> * * Note: this method has no side-effect, that is existing columns are * <b>not</b> re-created automatically, client code must trigger it * manually. * * @param columnFactory the factory to use, <code>null</code> indicates to * use the shared application factory. * * @see #getColumnFactory() * @see org.jdesktop.swingx.table.ColumnFactory */ public void setColumnFactory(ColumnFactory columnFactory) { /* * * TODO auto-configure columns on set? or add public table api to do so? * Mostly, this is meant to be done once in the lifetime of the table, * preferably before a model is set ... overshoot? */ ColumnFactory old = getColumnFactory(); this.columnFactory = columnFactory; firePropertyChange("columnFactory", old, getColumnFactory()); }
/** * Sets the <code>ColumnFactory</code> to use for column creation and * configuration. The default value is the shared application ColumnFactory. * <p> * * Note: this method has no side-effect, that is existing columns are * <b>not</b> re-created automatically, client code must trigger it * manually. * * @param columnFactory the factory to use, <code>null</code> indicates to * use the shared application factory. * * @see #getColumnFactory() * @see org.jdesktop.swingx.table.ColumnFactory */ public void setColumnFactory(ColumnFactory columnFactory) { /* * * TODO auto-configure columns on set? or add public table api to do so? * Mostly, this is meant to be done once in the lifetime of the table, * preferably before a model is set ... overshoot? */ ColumnFactory old = getColumnFactory(); this.columnFactory = columnFactory; firePropertyChange("columnFactory", old, getColumnFactory()); }
/** * Initialize the width related properties of the specified column. The * details are specified by the current <code>ColumnFactory</code> if the * column is of type <code>TableColumnExt</code>. Otherwise nothing is * changed. * <p> * * TODO JW - need to cleanup getScrollablePreferred (refactor and inline) * * @param column TableColumn object representing view column * @see org.jdesktop.swingx.table.ColumnFactory#configureColumnWidths */ protected void initializeColumnPreferredWidth(TableColumn column) { if (column instanceof TableColumnExt) { getColumnFactory().configureColumnWidths(this, (TableColumnExt) column); } }
/** * Initialize the width related properties of the specified column. The * details are specified by the current <code>ColumnFactory</code> if the * column is of type <code>TableColumnExt</code>. Otherwise nothing is * changed. * <p> * * TODO JW - need to cleanup getScrollablePreferred (refactor and inline) * * @param column TableColumn object representing view column * @see org.jdesktop.swingx.table.ColumnFactory#configureColumnWidths */ protected void initializeColumnPreferredWidth(TableColumn column) { if (column instanceof TableColumnExt) { getColumnFactory().configureColumnWidths(this, (TableColumnExt) column); } }
/** * Initialize the width related properties of the specified column. The * details are specified by the current <code>ColumnFactory</code> if the * column is of type <code>TableColumnExt</code>. Otherwise nothing is * changed. * <p> * * TODO JW - need to cleanup getScrollablePreferred (refactor and inline) * * @param column TableColumn object representing view column * @see org.jdesktop.swingx.table.ColumnFactory#configureColumnWidths */ protected void initializeColumnPreferredWidth(TableColumn column) { if (column instanceof TableColumnExt) { getColumnFactory().configureColumnWidths(this, (TableColumnExt) column); } }
/** * Initialize the width related properties of the specified column. The * details are specified by the current <code>ColumnFactory</code> if the * column is of type <code>TableColumnExt</code>. Otherwise nothing is * changed. * <p> * * TODO JW - need to cleanup getScrollablePreferred (refactor and inline) * * @param column TableColumn object representing view column * @see org.jdesktop.swingx.table.ColumnFactory#configureColumnWidths */ protected void initializeColumnPreferredWidth(TableColumn column) { if (column instanceof TableColumnExt) { getColumnFactory().configureColumnWidths(this, (TableColumnExt) column); } }
/** * Initialize the width related properties of the specified column. The * details are specified by the current <code>ColumnFactory</code> if the * column is of type <code>TableColumnExt</code>. Otherwise nothing is * changed. * <p> * * TODO JW - need to cleanup getScrollablePreferred (refactor and inline) * * @param column TableColumn object representing view column * @see org.jdesktop.swingx.table.ColumnFactory#configureColumnWidths */ protected void initializeColumnPreferredWidth(TableColumn column) { if (column instanceof TableColumnExt) { getColumnFactory().configureColumnWidths(this, (TableColumnExt) column); } }
/** * Packs an indivual column in the table to less than or equal to the * maximum witdth. If maximum is -1 then the column is made as wide as it * needs. * * @param column the column index to pack in view coordinates * @param margin the margin to apply to the column * @param max the maximum width the column can be resized to, -1 means no * limit * * @see #packColumn(int, int) * @see #packTable(int) * @see ColumnFactory#packColumn(JXTable, TableColumnExt, int, int) */ public void packColumn(int column, int margin, int max) { getColumnFactory().packColumn(this, getColumnExt(column), margin, max); }
/** * Packs an indivual column in the table to less than or equal to the * maximum witdth. If maximum is -1 then the column is made as wide as it * needs. * * @param column the column index to pack in view coordinates * @param margin the margin to apply to the column * @param max the maximum width the column can be resized to, -1 means no * limit * * @see #packColumn(int, int) * @see #packTable(int) * @see ColumnFactory#packColumn(JXTable, TableColumnExt, int, int) */ public void packColumn(int column, int margin, int max) { getColumnFactory().packColumn(this, getColumnExt(column), margin, max); }
/** * Packs an indivual column in the table to less than or equal to the * maximum witdth. If maximum is -1 then the column is made as wide as it * needs. * * @param column the column index to pack in view coordinates * @param margin the margin to apply to the column * @param max the maximum width the column can be resized to, -1 means no * limit * * @see #packColumn(int, int) * @see #packTable(int) * @see ColumnFactory#packColumn(JXTable, TableColumnExt, int, int) */ public void packColumn(int column, int margin, int max) { getColumnFactory().packColumn(this, getColumnExt(column), margin, max); }
/** * Packs an indivual column in the table to less than or equal to the * maximum witdth. If maximum is -1 then the column is made as wide as it * needs. * * @param column the column index to pack in view coordinates * @param margin the margin to apply to the column * @param max the maximum width the column can be resized to, -1 means no * limit * * @see #packColumn(int, int) * @see #packTable(int) * @see ColumnFactory#packColumn(JXTable, TableColumnExt, int, int) */ public void packColumn(int column, int margin, int max) { getColumnFactory().packColumn(this, getColumnExt(column), margin, max); }
/** * Packs an indivual column in the table to less than or equal to the * maximum witdth. If maximum is -1 then the column is made as wide as it * needs. * * @param column the column index to pack in view coordinates * @param margin the margin to apply to the column * @param max the maximum width the column can be resized to, -1 means no * limit * * @see #packColumn(int, int) * @see #packTable(int) * @see ColumnFactory#packColumn(JXTable, TableColumnExt, int, int) */ public void packColumn(int column, int margin, int max) { getColumnFactory().packColumn(this, getColumnExt(column), margin, max); }
/** * Creates and adds <code>TableColumn</code>s for each column of the table * model. * <p> * * */ private void createAndAddColumns() { /* * PENDING: go the whole distance and let the factory decide which model * columns to map to view columns? That would introduce an collection * managing operation into the factory, sprawling? Can't (and probably * don't want to) move all collection related operations over - the * ColumnFactory relies on TableColumnExt type columns, while the * JXTable has to cope with all the base types. */ for (int i = 0; i < getModel().getColumnCount(); i++) { // add directly to columnModel - don't go through this.addColumn // to guarantee full control of ColumnFactory // addColumn has the side-effect to set the header! TableColumnExt tableColumn = getColumnFactory() .createAndConfigureTableColumn(getModel(), i); if (tableColumn != null) { getColumnModel().addColumn(tableColumn); } } }
/** * Creates and adds <code>TableColumn</code>s for each column of the table * model. * <p> * * */ private void createAndAddColumns() { /* * PENDING: go the whole distance and let the factory decide which model * columns to map to view columns? That would introduce an collection * managing operation into the factory, sprawling? Can't (and probably * don't want to) move all collection related operations over - the * ColumnFactory relies on TableColumnExt type columns, while the * JXTable has to cope with all the base types. */ for (int i = 0; i < getModel().getColumnCount(); i++) { // add directly to columnModel - don't go through this.addColumn // to guarantee full control of ColumnFactory // addColumn has the side-effect to set the header! TableColumnExt tableColumn = getColumnFactory() .createAndConfigureTableColumn(getModel(), i); if (tableColumn != null) { getColumnModel().addColumn(tableColumn); } } }
/** * Creates and adds <code>TableColumn</code>s for each column of the table * model. * <p> * * */ private void createAndAddColumns() { /* * PENDING: go the whole distance and let the factory decide which model * columns to map to view columns? That would introduce an collection * managing operation into the factory, sprawling? Can't (and probably * don't want to) move all collection related operations over - the * ColumnFactory relies on TableColumnExt type columns, while the * JXTable has to cope with all the base types. */ for (int i = 0; i < getModel().getColumnCount(); i++) { // add directly to columnModel - don't go through this.addColumn // to guarantee full control of ColumnFactory // addColumn has the side-effect to set the header! TableColumnExt tableColumn = getColumnFactory() .createAndConfigureTableColumn(getModel(), i); if (tableColumn != null) { getColumnModel().addColumn(tableColumn); } } }
/** * Creates and adds <code>TableColumn</code>s for each column of the table * model. * <p> * * */ private void createAndAddColumns() { /* * PENDING: go the whole distance and let the factory decide which model * columns to map to view columns? That would introduce an collection * managing operation into the factory, sprawling? Can't (and probably * don't want to) move all collection related operations over - the * ColumnFactory relies on TableColumnExt type columns, while the * JXTable has to cope with all the base types. */ for (int i = 0; i < getModel().getColumnCount(); i++) { // add directly to columnModel - don't go through this.addColumn // to guarantee full control of ColumnFactory // addColumn has the side-effect to set the header! TableColumnExt tableColumn = getColumnFactory() .createAndConfigureTableColumn(getModel(), i); if (tableColumn != null) { getColumnModel().addColumn(tableColumn); } } }
/** * Creates and adds <code>TableColumn</code>s for each column of the table * model. * <p> * * */ private void createAndAddColumns() { /* * PENDING: go the whole distance and let the factory decide which model * columns to map to view columns? That would introduce an collection * managing operation into the factory, sprawling? Can't (and probably * don't want to) move all collection related operations over - the * ColumnFactory relies on TableColumnExt type columns, while the * JXTable has to cope with all the base types. */ for (int i = 0; i < getModel().getColumnCount(); i++) { // add directly to columnModel - don't go through this.addColumn // to guarantee full control of ColumnFactory // addColumn has the side-effect to set the header! TableColumnExt tableColumn = getColumnFactory() .createAndConfigureTableColumn(getModel(), i); if (tableColumn != null) { getColumnModel().addColumn(tableColumn); } } }