Skip to main content
`Ctrl`+`K`

# ColorButton

class pyqtgraph.ColorButton(

  parent=None,
  color=(128, 128, 128),
  padding=6,

)

  Bases: QtWidgets.QPushButton

  Button displaying a color and allowing the user to select a new color.

  Signals: |
  sigColorChanging(self) | emitted whenever a new color is picked in the color dialog
  sigColorChanged(self) | emitted when the selected color is accepted (user clicks OK)

  __init__(
    parent=None,
    color=(128, 128, 128),
    padding=6,
  )
  setColor(
    color,
    finished=True,
  )

    Sets the button’s color and emits both sigColorChanged and sigColorChanging.