CreateColorPicker Method (IApplication) Send Feedback
See Also  Example
ColorPicker[out]
IColorPicker (see Remarks)
OnlyColorByIndex
True to limit users to only specifying standard LineColors, false to allow users to also specify RGB (Red, Green, Blue) or HSL (Hue, Saturation, and Lightness) LineColor values
EnableByBlockAndLayer
True if users can specify LineColors by Layer or by Block, false if not
Gets access to the DraftSight color picker, which allows users to assign standard and custom LineColors directly to entities, by Layer, or by Block.

Syntax

Visual Basic 
Function CreateColorPicker( _
   ByVal OnlyColorByIndex As System.Boolean, _
   ByVal EnableByBlockAndLayer As System.Boolean _
) As ColorPicker
C# 
ColorPicker CreateColorPicker( 
   System.bool OnlyColorByIndex,
   System.bool EnableByBlockAndLayer
)
JavaScript 
CreateColorPicker( 
   OnlyColorByIndex : Boolean,
   EnableByBlockAndLayer : Boolean
) : dsColorPicker
COM native C++ 
HRESULT CreateColorPicker( 
   VARIANT_BOOL OnlyColorByIndex,
   VARIANT_BOOL EnableByBlockAndLayer,
   IColorPicker** ColorPicker
) 
C++ 
DSRESULT CreateColorPicker( 
   bool OnlyColorByIndex,
   bool EnableByBlockAndLayer,
   dsColorPicker** ColorPicker
) 

Parameters

OnlyColorByIndex
True to limit users to only specifying standard LineColors, false to allow users to also specify RGB (Red, Green, Blue) or HSL (Hue, Saturation, and Lightness) LineColor values
EnableByBlockAndLayer
True if users can specify LineColors by Layer or by Block, false if not
ColorPicker[out] or Return Value
IColorPicker (see Remarks)

Example

Remarks

The IColorPicker interface corresponds to clicking Format > Line Color in the DraftSight user interface.
 

See Also

Availability

DraftSight V1R5.0