KDE 4.9 PyKDE API Reference

- KDE's Python API

# KHueSaturationSelector Class Reference

`from PyKDE4.kdeui import *`

Inherits: KXYSelector → QWidget → QObject

## Detailed Description

## Methods
| __init__ (self, QWidget parent=0)
| __init__ (self, KHueSaturationSelector a0)
KColorChooserMode | chooserMode (self)
int | colorValue (self)
| drawContents (self, QPainter painter)
| drawPalette (self, QPixmap pixmap)
int | hue (self)
| resizeEvent (self, QResizeEvent a0)
int | saturation (self)
| setChooserMode (self, KColorChooserMode chooserMode)
| setColorValue (self, int colorValue)
| setHue (self, int hue)
| setSaturation (self, int saturation)
| updateContents (self)

## Method Documentation

__init__ | ( | self, |
|  | QWidget | parent=0
| ) |  |  |

Constructs a hue/saturation selection widget.

__init__ | ( | self, |
|  | KHueSaturationSelector | a0
| ) |  |  |

KColorChooserMode chooserMode | ( |  | self ) |

Returns the chooser mode.

Returns:
  The chooser mode (defined in KColorChooserMode)

int colorValue | ( |  | self ) |

Returns the color value (also known as lumniousity, 0-255)

Returns:
  The color value (0-255)

drawContents | ( | self, |
|  | QPainter | painter
| ) |  |  |

Reimplemented from KXYSelector. This drawing is buffered in a pixmap here. As real drawing routine, drawPalette() is used.

drawPalette | ( | self, |
|  | QPixmap | pixmap
| ) |  |  |

Draws the contents of the widget on a pixmap, which is used for buffering.

int hue | ( |  | self ) |

Returns the hue value

Returns:
  The hue value (0-360)

resizeEvent | ( | self, |
|  | QResizeEvent | a0
| ) |  |  |

int saturation | ( |  | self ) |

Returns the saturation (0-255)

Returns:
  The saturation (0-255)

setChooserMode | ( | self, |
|  | KColorChooserMode | chooserMode
| ) |  |  |

Sets the chooser mode. The allowed modes are defined in KColorChooserMode.

Parameters:

  |  | The chooser mode as defined in KColorChooserMode

setColorValue | ( | self, |
|  | int | colorValue
| ) |  |  |

Sets the color value (0-255)

Parameters:

  |  | colorValue The color value (0-255)

setHue | ( | self, |
|  | int | hue
| ) |  |  |

Sets the hue value (0-360)

Parameters:

  |  | hue The hue value (0-360)

setSaturation | ( | self, |
|  | int | saturation
| ) |  |  |

Sets the saturation (0-255)

Parameters:

  |  | saturation The saturation (0-255)

updateContents | ( |  | self ) |

Updates the contents