Class ColorSwtParameter

java.lang.Object
com.biglybt.ui.swt.config.BaseSwtParameter<ColorSwtParameter,int[]>
com.biglybt.ui.swt.config.ColorSwtParameter
All Implemented Interfaces:
SwtParameter<int[]>

public class ColorSwtParameter extends BaseSwtParameter<ColorSwtParameter,int[]>
SWT Parameter representing a color (r, g, b) value. Button with color opting a color choosing dialog.

Will always use 2 horizontal spaces in GridLayout

  • Field Details

    • colorChooser

      private final org.eclipse.swt.widgets.Button colorChooser
    • resetButton

      private org.eclipse.swt.widgets.Button resetButton
    • lblSuffix

      private org.eclipse.swt.widgets.Label lblSuffix
    • img

      private org.eclipse.swt.graphics.Image img
  • Constructor Details

    • ColorSwtParameter

      public ColorSwtParameter(org.eclipse.swt.widgets.Composite composite, ColorParameter param)
    • ColorSwtParameter

      public ColorSwtParameter(org.eclipse.swt.widgets.Composite composite, String paramID, String labelKey, String suffixLabelKey, boolean showResetButton, SwtParameterValueProcessor<ColorSwtParameter,int[]> valueProcessor)
      Make a color selecting button.

      When parent is of GridLayout, resulting new widgets will take 2 columns

      Parameters:
      composite - Where widgets will be placed. Composite is not altered
      paramID - ID of the parameter (usually config id)
      labelKey - Messagebundle key for the text shown before the color button
      suffixLabelKey - Messagebundle key for text shown after the color button (same row)
      showResetButton - Whether to display a rest button next to the color button
      valueProcessor - null if you want to use COConfigurationManager
  • Method Details