Nevron Open Vision Documentation
User Interface / Widgets / Color Pickers / HSB Wheel Color Picker
In This Topic
    HSB Wheel Color Picker
    In This Topic

    The HSB wheel color picker lets the user select a color by picking its hue from a hue color wheel and its saturation and brightness from an SB triangle:

     Properties and Events

    The HSB wheel color picker provides the following properties:

    Name Description
    SelectedColor Defines the currently selected color. This property is automatically updated when the user drags the SB Selector or the Hue selector. When the value of this property has changed, the SelectedColorChanged event is raised.
    UpdateWhileDragging Determines whether the selected color should be updated while the user drags one of the color picker selectors or only when he releases them.
    HueSelectorSectorAngle The sector angle of the hue selector, which defines the sector (arc) of the wheel occupied by the hue selector.
    HueWheelWidthPercent The hue wheel width percent, which defines the width of the hue wheel relative to the hue wheel outer radius.
    HueSelectorExtendPercent The extend of the hue selector pointers, measured as a percent of the hue wheel width.
    SBTriangleMarginsPercent The margins applied to the SB triangle, measures as a percent of the hue wheel inner radius.
    SBSelectorRadiusPercent The radius percent for the SB selector circle, measured as a percent of the hue wheel inner radius.
     Code Example

    The following example demonstrates how to create a HSB color picker and handle it SelectedColorChanged event:

    HSB Wheel Color Picker Example
    Copy Code
    NHsbWheelColorPicker colorPicker = new NHsbWheelColorPicker();
    colorPicker.HorizontalPlacement = ENHorizontalPlacement.Left;
    colorPicker.VerticalPlacement = ENVerticalPlacement.Top;
    colorPicker.SelectedColorChanged += new Function<NValueChangeEventArgs>(OnSelectedColorChanged);
    private void OnSelectedColorChanged(NValueChangeEventArgs arg1)
        // Get the new selected color
        NColor selectedColor = (NColor)arg1.NewValue;