Class ScalingUiBindingConfiguration

java.lang.Object
org.eclipse.nebula.widgets.nattable.config.AbstractUiBindingConfiguration
org.eclipse.nebula.widgets.nattable.ui.scaling.ScalingUiBindingConfiguration
All Implemented Interfaces:
IConfiguration

public class ScalingUiBindingConfiguration extends AbstractUiBindingConfiguration
Default configuration to add bindings to change the scaling / zoom level of a NatTable.
Since:
2.0
  • Constructor Details

    • ScalingUiBindingConfiguration

      public ScalingUiBindingConfiguration(NatTable natTable)
      Creates a new ZoomOutScalingAction without an updater.

      Note:
      Without an updater manually registered painters will not be updated and therefore won't reflect the udpated scaling. This only works in combination with theme styling, as the painter update is implemented in the themes internally.

      Parameters:
      natTable - The NatTable instance to which the scaling bindings should be added. Needed to attach the mouse scroll listener.
    • ScalingUiBindingConfiguration

      public ScalingUiBindingConfiguration(NatTable natTable, Consumer<IConfigRegistry> updater)
      Creates a new ZoomOutScalingAction with the given updater.
      Parameters:
      updater - The updater that should be called on zoom operations. Needed to reflect the updated scaling. E.g. re-register ImagePainters like the CheckBoxPainter, otherwise the images will not be updated according to the scaling.
  • Method Details

    • configureUiBindings

      public void configureUiBindings(UiBindingRegistry uiBindingRegistry)
      Description copied from interface: IConfiguration
      Configure NatTable's UiBindingRegistry upon receiving this callback. A mechanism to customize key/mouse bindings.
      Parameters:
      uiBindingRegistry - The UiBindingRegistry instance to register ui bindings to.