Class: Highlighter

Highlighter

The Highlighter object controls highlighting and popovers of features, plots and other elements on the Viewer when the mouse hovers over them.

Attributes

Option Default Description
feature HighlighterElement Describes the highlightling options for features
plot HighlighterElement Describes the highlightling options for plots
contig HighlighterElement Describes the highlightling options for contigs
backbone HighlighterElement Describes the highlightling options for the backbone
showMetaData true Should meta data be shown in popovers

new Highlighter(viewer, options)

Create a Highlighter

Name Type Description
viewer Viewer

The viewer

options Object

Attributes used to create the highlighter.

Extends

Members

Get the backbone HighlighterElement

canvasCanvas

Get the canvas.

Get the contig HighlighterElement

Get the feature HighlighterElement

layoutLayout

Get the layout.

metaBoolean

Get or Set the meta data of this object. See the meta data tutorial for details.

Get the plot HighlighterElement

sequenceSequence

Get the sequence.

viewerViewer

Get the viewer.

visibleBoolean

Get or Set the visibility of this object.

Methods

inherited addPluginOptions(id, options)

Add a plugin to the object.

Name Type Description
id String

The id of the plugin

options Object

The plugin options

inherited deleteFromObjects()

Remove the object from Viewer.objects

inherited hasPlugin(pluginID){Boolean}

Does this object have a particular plugin?

Name Type Description
pluginID String

The ID of the plugin

Returns:
Type Description
Boolean
  • Whether the object has the plugin

inherited optionsForPlugin(pluginName){Object}

Get the options for a particular plugin.

Name Type Description
pluginName String

The name of the plugin

Returns:
Type Description
Object
  • The options for the plugin or undefined if the plugin is not found

inherited toString(){String}

Return the class name as a string.

Returns:
Type Description
String
  • 'CGObject'

inherited updatePluginOptions(id, options)

Update plugin options. Merge the new options with the old options.

Name Type Description
id String

The id of the plugin

options Object

The plugin options