gtk-0.11.0: Binding to the Gtk+ graphical user interface library.Source codeContentsIndex
Graphics.UI.Gtk.Selectors.ColorSelection
Portabilityportable (depends on GHC)
Stabilityprovisional
Maintainergtk2hs-users@lists.sourceforge.net
Contents
Detail
Class Hierarchy
Types
Constructors
Methods
Attributes
Description
A widget used to select a color
Synopsis
data ColorSelection
class VBoxClass o => ColorSelectionClass o
castToColorSelection :: GObjectClass obj => obj -> ColorSelection
gTypeColorSelection :: GType
toColorSelection :: ColorSelectionClass o => o -> ColorSelection
colorSelectionNew :: IO ColorSelection
colorSelectionGetCurrentAlpha :: ColorSelectionClass self => self -> IO Int
colorSelectionSetCurrentAlpha :: ColorSelectionClass self => self -> Int -> IO ()
colorSelectionGetCurrentColor :: ColorSelectionClass self => self -> IO Color
colorSelectionSetCurrentColor :: ColorSelectionClass self => self -> Color -> IO ()
colorSelectionGetHasOpacityControl :: ColorSelectionClass self => self -> IO Bool
colorSelectionSetHasOpacityControl :: ColorSelectionClass self => self -> Bool -> IO ()
colorSelectionGetHasPalette :: ColorSelectionClass self => self -> IO Bool
colorSelectionSetHasPalette :: ColorSelectionClass self => self -> Bool -> IO ()
colorSelectionGetPreviousAlpha :: ColorSelectionClass self => self -> IO Int
colorSelectionSetPreviousAlpha :: ColorSelectionClass self => self -> Int -> IO ()
colorSelectionGetPreviousColor :: ColorSelectionClass self => self -> IO Color
colorSelectionSetPreviousColor :: ColorSelectionClass self => self -> Color -> IO ()
colorSelectionIsAdjusting :: ColorSelectionClass self => self -> IO Bool
colorSelectionHasOpacityControl :: ColorSelectionClass self => Attr self Bool
colorSelectionHasPalette :: ColorSelectionClass self => Attr self Bool
colorSelectionCurrentAlpha :: ColorSelectionClass self => Attr self Int
colorSelectionPreviousAlpha :: ColorSelectionClass self => Attr self Int
Detail
The ColorSelection is a widget that is used to select a color. It consists of a color wheel and number of sliders and entry boxes for color parameters such as hue, saturation, value, red, green, blue, and opacity. It is found on the standard color selection dialog box ColorSelectionDialog.
Class Hierarchy
 |  GObject
 |   +----Object
 |         +----Widget
 |               +----Container
 |                     +----Box
 |                           +----VBox
 |                                 +----ColorSelection
Types
data ColorSelection Source
class VBoxClass o => ColorSelectionClass o Source
castToColorSelection :: GObjectClass obj => obj -> ColorSelectionSource
gTypeColorSelection :: GTypeSource
toColorSelection :: ColorSelectionClass o => o -> ColorSelectionSource
Constructors
colorSelectionNew :: IO ColorSelectionSource
Creates a new ColorSelection.
Methods
colorSelectionGetCurrentAlphaSource
:: ColorSelectionClass self
=> selfreturns an integer between 0 and 65535.
-> IO Int
Returns the current alpha value.
colorSelectionSetCurrentAlphaSource
:: ColorSelectionClass self
=> selfalpha - an integer between 0 and 65535.
-> Int
-> IO ()
Sets the current opacity to be alpha. The first time this is called, it will also set the original opacity to be alpha too.
colorSelectionGetCurrentColor :: ColorSelectionClass self => self -> IO ColorSource
Gets the current color in the ColorSelection widget.
colorSelectionSetCurrentColorSource
:: ColorSelectionClass self
=> selfcolor - A Color to set the current color with.
-> Color
-> IO ()
Sets the current color to be color. The first time this is called, it will also set the original color to be color too.
colorSelectionGetHasOpacityControlSource
:: ColorSelectionClass self
=> selfreturns True if the color selector has an opacity control. False if it does't.
-> IO Bool
Determines whether the ColorSelection widget has an opacity control.
colorSelectionSetHasOpacityControlSource
:: ColorSelectionClass self
=> selfhasOpacity - True if color selector can set the opacity, False otherwise.
-> Bool
-> IO ()
Sets the ColorSelection widget to use or not use opacity.
colorSelectionGetHasPaletteSource
:: ColorSelectionClass self
=> selfreturns True if the selector has a palette. False if it hasn't.
-> IO Bool
Determines whether the color selector has a color palette.
colorSelectionSetHasPaletteSource
:: ColorSelectionClass self
=> selfhasPalette - True if palette is to be visible, False otherwise.
-> Bool
-> IO ()
Sets whether to show or hide the palette.
colorSelectionGetPreviousAlphaSource
:: ColorSelectionClass self
=> selfreturns an integer between 0 and 65535.
-> IO Int
Returns the previous alpha value.
colorSelectionSetPreviousAlphaSource
:: ColorSelectionClass self
=> selfalpha - an integer between 0 and 65535.
-> Int
-> IO ()
Sets the 'previous' alpha to be alpha. This function should be called with some hesitations, as it might seem confusing to have that alpha change.
colorSelectionGetPreviousColor :: ColorSelectionClass self => self -> IO ColorSource
Returns the original color value.
colorSelectionSetPreviousColor :: ColorSelectionClass self => self -> Color -> IO ()Source
Sets the 'previous' color to be color. This function should be called with some hesitations, as it might seem confusing to have that color change. Calling colorSelectionSetCurrentColor will also set this color the first time it is called.
colorSelectionIsAdjusting :: ColorSelectionClass self => self -> IO BoolSource
Gets the current state of the widget. Returns True if the user is currently dragging a color around, and False if the selection has stopped.
Attributes
colorSelectionHasOpacityControl :: ColorSelectionClass self => Attr self BoolSource

Whether the color selector should allow setting opacity.

Default value: False

colorSelectionHasPalette :: ColorSelectionClass self => Attr self BoolSource

Whether a palette should be used.

Default value: False

colorSelectionCurrentAlpha :: ColorSelectionClass self => Attr self IntSource

The current opacity value (0 fully transparent, 65535 fully opaque).

Allowed values: <= 65535

Default value: 65535

colorSelectionPreviousAlpha :: ColorSelectionClass self => Attr self IntSource
'previousAlpha' property. See colorSelectionGetPreviousAlpha and colorSelectionSetPreviousAlpha
Produced by Haddock version 2.6.0