GH_ColourPickerBase Class

GH_ColourPickerBase Class

Provides Colour picker GUI not tied to a control-handle.
Inheritance Hierarchy
SystemObject
  Grasshopper.GUI.BaseGH_ColourPickerBase

Namespace:  Grasshopper.GUI.Base
Assembly:  Grasshopper (in Grasshopper.dll)
Syntax
public class GH_ColourPickerBase
Public Class GH_ColourPickerBase

The GH_ColourPickerBase type exposes the following members.

Constructors
  NameDescription
Public methodGH_ColourPickerBase
Create a new instance of the Colour Picker base control. This constructor assigns the default Colour space model and involves a call to the Grasshopper core settings server. You must call SetupColourPicker() prior to rendering this control on screen.
Top
Properties
  NameDescription
Public propertyAutoSize
Gets or sets a value indicating whether the width and height of the Bounds are adjusted to fit the UI.
Public propertyBackColour
Gets or sets the background colour of the picker.
Public propertyBaseColour
Gets the original base colour for this picker. Use SetupColourPicker to assign this colour.
Public propertyBaseColourBox
Gets the rectangle containing the base colour swatch.
Public propertyBounds
Gets or sets the Bounds for this control.
Public propertyChannelBox0
Gets the rectangle containing the tag string for the first channel slider.
Public propertyChannelBox1
Gets the rectangle containing the tag string for the second channel slider.
Public propertyChannelBox2
Gets the rectangle containing the tag string for the third channel slider.
Public propertyChannelBox3
Gets the rectangle containing the tag string for the fourth channel slider.
Public propertyColourCubeBox
Gets the rectangle that contains the colour space cube.
Public propertyColourSpace
Gets the Colour space mode used in this picker.
Public propertyCube
Gets the graphics object that describes the current colour cube.
Public propertyDesiredHeight
Gets the ideal height for this colour picker given it's width and UI settings.
Public propertyDrawAlphaSlider
Gets or sets whether or not the alpha slider is included in the UI.
Public propertyDrawBackground
Gets or sets whether the background of the picker is drawn.
Public propertyDrawChannelSliders
Gets or sets whether or not the three basic channel sliders are included in the UI.
Public propertyDropperPreviewBox
Gets the rectangle in which the eye-dropped preview will be drawn.
Public propertyFont
Gets or sets the Font used in this Colour Picker. Do not Dispose the Font returned by this property.
Public propertyHSVSpaceBox
Gets the rectangle containing the base colour space.
Public propertyIsTextInput
Gets whether any of the slider is currently displaying a text input box.
Public propertyPadding
Gets or sets the Padding for this control.
Public propertyPickColour
Gets the picked colour.
Public propertyPickColourBox
Gets the rectangle containing the pick colour swatch.
Public propertyRGBSpaceBox
Gets the rectangle containing the pick colour space.
Public propertySRCSpaceBox
Gets the rectangle containing the eye-dropper function.
Top
Methods
  NameDescription
Public methodInvalidate
Raise the Invalidated event.
Public methodMouseClick
Respond to mouse-click events.
Public methodMouseDoubleClick
Respond to mouse-doubleclick events.
Public methodMouseDown
Respond to mouse-down events.
Public methodMouseMove
Respond to mouse-move events.
Public methodMouseUp
Respond to mouse-up events.
Public methodOnColorChanged
Raise the ColorChanged event.
Public methodRender
Render this slider into a Graphics context.
Public methodRespondToEnter
Public methodRespondToEscape
Public methodSetUiScaling
Public methodSetupColourPicker(Color, Point4d, GH_ColourSpace)
Setup all UI elements.
Public methodSetupColourPicker(Color, Color, GH_ColourSpace)
Setup all UI elements.
Top
Events
  NameDescription
Public eventColorChanged
Raised whenever the color of this picker is changed due to User-Interface methods.
Public eventInvalidated
Raised whenever a redraw is required.
Top
See Also