Class
RadColorDialog

Represents a dialog that can be used to select color with rich UI and extended functionality.

Definition

Namespace:Telerik.WinControls

Assembly:Telerik.WinControls.dll

Syntax:

cs-api-definition
[TelerikToolboxCategory("Dialogs")]
public class RadColorDialog : CommonDialog, IComponent, IDisposable

Inheritance: objectMarshalByRefObjectComponentCommonDialogRadColorDialog

Implements: IComponentIDisposable

Inherited Members CommonDialog.HookProc(IntPtr, int, IntPtr, IntPtr)CommonDialog.OnHelpRequest(EventArgs)CommonDialog.OwnerWndProc(IntPtr, int, IntPtr, IntPtr)CommonDialog.ShowDialog()CommonDialog.ShowDialog(IWin32Window)CommonDialog.TagCommonDialog.HelpRequestComponent.Dispose()Component.GetService(Type)Component.ToString()Component.CanRaiseEventsComponent.EventsComponent.SiteComponent.ContainerComponent.DesignModeComponent.DisposedMarshalByRefObject.MemberwiseClone(bool)MarshalByRefObject.GetLifetimeService()MarshalByRefObject.InitializeLifetimeService()MarshalByRefObject.CreateObjRef(Type)

Constructors

RadColorDialog()

Initializes a new instance of the RadColorDialog class.

Declaration

cs-api-definition
public RadColorDialog()

Properties

ColorDialogForm

Gets the instance of IRadColorDialog, which incorporates various settings of the underlying color selection Form and ColorSelector user control.

Declaration

cs-api-definition
[Browsable(false)]
public IRadColorDialog ColorDialogForm { get; }

Property Value

IRadColorDialog

CustomColors

Gets the user-defined colors. References to CustomColors of ColorDialogForm.

Declaration

cs-api-definition
[Browsable(false)]
public Color[] CustomColors { get; }

Property Value

Color[]

Icon

Gets or sets the icon displayed for this dialog.

Declaration

cs-api-definition
public Icon Icon { get; set; }

Property Value

Icon

OldColor

Gets or sets the selected color that was previously selected. References to OldColor of ColorDialogForm.

Declaration

cs-api-definition
public Color OldColor { get; set; }

Property Value

Color

RightToLeft

Gets or sets a value indicating whether control's elements are aligned to support locales using right-to-left fonts.

Declaration

cs-api-definition
public virtual RightToLeft RightToLeft { get; set; }

Property Value

RightToLeft

One of the RightToLeft values. The default is Inherit.

Exceptions

InvalidEnumArgumentException

The assigned value is not one of the RightToLeft values.

SelectedColor

Gets or sets the selected color. References to SelectedColor of ColorDialogForm.

Declaration

cs-api-definition
public Color SelectedColor { get; set; }

Property Value

Color

SelectedHslColor

Gets or sets the selected HSL color. References to SelectedHslColor of ColorDialogForm.

Declaration

cs-api-definition
public HslColor SelectedHslColor { get; set; }

Property Value

HslColor

Methods

Dispose(bool)

Releases the unmanaged resources used by the RadColorDialog and optionally releases the managed resources.

Declaration

cs-api-definition
protected override void Dispose(bool disposing)

Parameters

disposing

bool

true to release both managed and unmanaged resources; false to release only unmanaged resources.

Overrides Component.Dispose(bool)

Reset()

Resets the properties of a color dialog box to their default values. Replaces the underlying ColorDialogForm with new instance.

Declaration

cs-api-definition
public override void Reset()

Overrides CommonDialog.Reset()

RunDialog(IntPtr)

Shows the modal dialog box with the specified owner.

Declaration

cs-api-definition
protected override bool RunDialog(IntPtr hwndOwner)

Parameters

hwndOwner

IntPtr

A value that represents the window handle of the owner window for the common dialog box.

Returns

bool

true if the dialog box was successfully run and the user clicked OK; otherwise, false.

Overrides CommonDialog.RunDialog(IntPtr)