class

LSProtocol::ColorPresentation

Inherits JSON::Serializable / Reference / Object

Constructors

new(pull : JSON::PullParser)
Source
new(label : String | Nil, additional_text_edits : Array(TextEdit) | Nil = nil, text_edit : TextEdit | Nil = nil)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

additional_text_edits

An optional array of additional TextEdit that are applied when selecting this color presentation. Edits must not overlap with the main ColorPresentation#textEdit nor with themselves.

Source
label

The label of this color presentation. It will be shown on the color picker header. By default this is also the text that is inserted when selecting this color presentation.

Source
text_edit

An TextEdit which is applied to a document when selecting this presentation for the color. When falsy the ColorPresentation#label is used.

Source