Class ColumnResizeCommand
java.lang.Object
org.eclipse.nebula.widgets.nattable.command.AbstractColumnCommand
org.eclipse.nebula.widgets.nattable.resize.command.ColumnResizeCommand
- All Implemented Interfaces:
ILayerCommand
Command to trigger column resizing.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionColumnResizeCommand(ILayer layer, int columnPosition, int newWidth) Create aColumnResizeCommandto resize the column at the given position to the given width.ColumnResizeCommand(ILayer layer, int columnPosition, int newWidth, boolean downScale) Create aColumnResizeCommandto resize the column at the given position to the given width.protectedColumnResizeCommand(ColumnResizeCommand command) Constructor used to clone the given command. -
Method Summary
Modifier and TypeMethodDescriptionSame semantics asObject.clone()Used to make a copies of the command if has to passed to different layer stacks.booleanintMethods inherited from class org.eclipse.nebula.widgets.nattable.command.AbstractColumnCommand
convertToTargetLayer, getColumnPosition, getLayer, toString
-
Constructor Details
-
ColumnResizeCommand
Create aColumnResizeCommandto resize the column at the given position to the given width. The given column width will be taken as is without scaling.- Parameters:
layer- TheILayerto which the column position correlates.columnPosition- The position of the column that should be resized.newWidth- The new width that should be applied to the given column.
-
ColumnResizeCommand
Create aColumnResizeCommandto resize the column at the given position to the given width.- Parameters:
layer- TheILayerto which the column position correlates.columnPosition- The position of the column that should be resized.newWidth- The new width that should be applied to the given column.downScale-trueif the newWidth value should be down scaled according to the scaling level,falseif the value should be taken as is.- Since:
- 1.6
-
ColumnResizeCommand
Constructor used to clone the given command.- Parameters:
command- The command to clone.
-
-
Method Details
-
getNewColumnWidth
public int getNewColumnWidth()- Returns:
- The new width value that should be applied.
-
downScaleValue
public boolean downScaleValue()- Returns:
trueif the newWidth value should be down scaled according to the scaling level,falseif the value should be taken as is.- Since:
- 1.6
-
cloneCommand
Description copied from interface:ILayerCommandSame semantics asObject.clone()Used to make a copies of the command if has to passed to different layer stacks.- Returns:
- a cloned instance of the command
- See Also:
-