Last updated

API / geotoolkit / axis / SecondaryTickGenerator / SecondaryTickGenerator

Class: SecondaryTickGenerator

axis.SecondaryTickGenerator.SecondaryTickGenerator

SecondaryTickGenerator utilizes "primaryValues-to-secondaryValues" mapping to generate ticks/labels linearly spaced in secondary model space, so that distance between major ticks/labels in the space is equal to "majorStep" (or "minorStep" for minor ticks/labels correspondingly). Note, that linear spacing in secondary space does not mean linear spacing in primary space.

Hierarchy

Table of contents

Constructors
[new SecondaryTickGenerator(options)](/solutions/geotoolkit/apis/classes/geotoolkit.axis.secondarytickgenerator.secondarytickgenerator.md#new secondarytickgenerator(options))[new SecondaryTickGenerator(options, secondaryValues, majorStep, minorStep)](/solutions/geotoolkit/apis/classes/geotoolkit.axis.secondarytickgenerator.secondarytickgenerator.md#new secondarytickgenerator(options, secondaryvalues, majorstep, minorstep))
Methods
Css Properties
Name Type Description
labeldecimationbooleanLabel decimation
labelstylesTextStyleAn object containing label style for specified grades
labelstyles-alignmentAlignmentStyleAlignment
labelstyles-autosizebooleanAuto font size on high definition display
labelstyles-backgroundstringBackground style
labelstyles-backgroundFillStyleBackground style
labelstyles-background-colorstringColor in CSS form
labelstyles-background-evenoddmodebooleanEven-odd fill mode
labelstyles-background-fillpatternPatternPattern
labelstyles-background-fillpattern-containernamestringAn optional container name, which creates an image pattern. This parameter is used for serialization if you want to save are reference to pattern instead of the pattern itself
labelstyles-background-fillpattern-patternnamestringName of this pattern for indexing
labelstyles-background-fillpattern-scalablebooleanFlag that sets scalability of the pattern coordinates, or relative to the shape it is filling (It is not supported)
labelstyles-background-foregroundstringForeground color
labelstyles-background-patternPatternPattern
labelstyles-baselineBaseLineStyleBase line
labelstyles-colorstringColor in CSS form
labelstyles-fillFillStyleText fill style
labelstyles-fontstringFont see
labelstyles-fonturlstringThe place from which the font will be loaded, if null - uses system fonts. It can be base64 with url keyword
labelstyles-lineheightstring | numberLine height
labelstyles-multilinebooleanAllow multi-line text
labelstyles-outlinestringOutline style
labelstyles-outlineLineStyleOutline style
labelstyles-outline-colorstringColor in CSS form
labelstyles-outline-fillstringOptional fill style to be used to fill lines generated with this style
labelstyles-outline-fillFillStyleOptional fill style to be used to fill lines generated with this style
labelstyles-outline-linecapCapStyleThe line cap style
labelstyles-outline-linedashoffsetnumberLine dash offset of dashed line
labelstyles-outline-linejoinJoinStyleThe line join style
labelstyles-outline-pixelsnapmodebooleanPixel Snap Mode, default(
labelstyles-outline-scalablebooleanTrue if width should depend on transformation
labelstyles-outline-unitstringOptional unit for the width
labelstyles-outline-widthnumber | stringThe line thickness
labelstyles-overflowwrapOverflowWrapStyleOverflow wrap
labelstyles-strikethroughstringStrikethrough style
labelstyles-strikethroughLineStyleStrikethrough style
labelstyles-textoverflowTextOverflowStyleText overflow
labelstyles-underlinestringUnderline style
labelstyles-underlineLineStyleUnderline style
labelstyles-underlineoffsetstring | numberUnderline offset distance
labelstyles-whitespaceWhiteSpaceStyleWhite space
labelstyles-wordbreakWordBreakStyleWord break
majorreversedTickOptionsSecondary major tick options
majorreversed-adjustlabelanchorbooleanAdjust position of the label anchor
majorreversed-labelanchorAnchorTypeOptional label anchor
majorreversed-labelanglenumberAngle label rotation angle, in radians
majorreversed-labelstylestringObject containing the properties to set TextStyle of label. See
majorreversed-labelstyleTextStyleObject containing the properties to set TextStyle of label. See
majorreversed-labelvisiblebooleanLabel visibility
majorreversed-ticksizenumberTick size
majorreversed-tickstyleLineStyleObject containing the properties to set LineStyle of tick. See
majorreversed-tickvisiblebooleanTick visibility
majorstepnumberTick step for major ticks (in secondary space)
minorreversedTickOptionsSecondary minor tick options
minorstepnumberTick step for minor ticks (in secondary space)
taganyTag user can specify info associated with current object
tickstylesLineStyleAn object containing tick styles for specified grades

Contents

Constructors

new SecondaryTickGenerator(options)

new SecondaryTickGenerator(options?)

Parameters

Name Type Description
Optional optionsOptionsgrowing array of values in primary model space the generator's axis parent model space)

Overrides

NumericTickGenerator.constructor


new SecondaryTickGenerator(options, secondaryValues, majorStep, minorStep)

new SecondaryTickGenerator(options, secondaryValues, majorStep, minorStep)

Parameters

Name Type
optionsnumber[]
secondaryValuesnumber[]
majorStepnumber
minorStepnumber

Overrides

NumericTickGenerator.constructor

Methods

clone

clone(): SecondaryTickGenerator

All subclasses should override copyConstructor or provide custom implementation for this method

Returns

SecondaryTickGenerator

clone

Overrides

NumericTickGenerator.clone


connectStyle

connectStyle(style, type, callback): SecondaryTickGenerator

Connects style.

This convenience method subscribes a listener to given style for the specified type.
And automatically un-subscribes listener if node is disposed to prevent memory leaks

Parameters

Name Type Description
styleEventDispatcherconnect style
typestringtype of event or property
callbackAttributeCallback<EventDispatcher>function to be called

Returns

SecondaryTickGenerator

Inherited from

NumericTickGenerator.connectStyle


copyConstructor

Protected copyConstructor(src, deepCopy?): SecondaryTickGenerator

Copy constructor

Parameters

Name Type Description
srcSecondaryTickGeneratorSource to copy from
Optional deepCopybooleandeep copy

Returns

SecondaryTickGenerator

this

Overrides

NumericTickGenerator.copyConstructor


disconnectStyle

disconnectStyle(style, type, callback): SecondaryTickGenerator

Disconnect style

This convenience method un-subscribes a listener to given style for the specified type.

Parameters

Name Type Description
styleEventDispatcherconnect style
typestringtype of event or property
callbackAttributeCallback<EventDispatcher>function to be called

Returns

SecondaryTickGenerator

Inherited from

NumericTickGenerator.disconnectStyle


dispose

dispose(): void

Disposes this node, once disposes a node should not be used anymore.
Clear all listeners, and disconnect styles to avoid memory leaks.
Also aggressively 'cleanup' this node by setting some of its members to null.

Returns

void

Inherited from

NumericTickGenerator.dispose


execute

execute(delegate): SecondaryTickGenerator

Executes delegate and returns the result

Parameters

Name Type Description
delegate(this: SecondaryTickGenerator) => voidexecute delegate and return the result

Returns

SecondaryTickGenerator

Inherited from

NumericTickGenerator.execute

execute<T>(delegate): T

Type parameters

Name
T

Parameters

Name Type
delegate(this: SecondaryTickGenerator) => T

Returns

T

Inherited from

NumericTickGenerator.execute


formatLabel

formatLabel(parent, orient, tickInfo, tickIndex, labelPos): string

Formats label text positioned at "labelPos" in primary model space. IMPORTANT: Textual content of the label is formatted out of its position in secondary space.

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfoan info about tick
tickIndexnumbertick index from 0 to count-1, which resetTicks returns
labelPosnumbermodel value (in primary space) - ignored by the implementation

Returns

string

label text

Overrides

NumericTickGenerator.formatLabel


formatLabelInternal

Protected formatLabelInternal(tickType, modelValue): string

Format label

Parameters

Name Type Description
tickTypestring"edge" or "major" or "minor"
modelValuestring | numbermodel coordinate position

Returns

string

Inherited from

NumericTickGenerator.formatLabelInternal


getAdjustLabelAnchor

getAdjustLabelAnchor(grade): boolean

Gets adjust label anchor flag for specified label grade

Parameters

Name Type Description
gradestringlabel grade

Returns

boolean

label anchor flag ("true" by default for any grade)

Inherited from

NumericTickGenerator.getAdjustLabelAnchor


getBoundingBox

getBoundingBox(tickInfo, orient, labelPos, labelText?): Rect

Returns bounding box of label

Parameters

Name Type Description
tickInfoTickInfoinfo about the tick
orientOrientationorientation
labelPosnumberlabel position along index direction
Optional labelTextstringlabel text. If not defined labelPos.toString() is used.

Returns

Rect

bbox bounding box

Inherited from

NumericTickGenerator.getBoundingBox


getClassName

getClassName(): string

Returns

string

Inherited from

NumericTickGenerator.getClassName


getFormatLabelHandler

getFormatLabelHandler(): LabelFormatHandler

Returns label format handler

Returns

LabelFormatHandler

Inherited from

NumericTickGenerator.getFormatLabelHandler


getGrades

getGrades(): string[]

Returns supported tick grades: ["major", "minor", "majorreversed" and "minorreversed"]

Returns

string[]

supported tick grades: ["major", "minor", "majorreversed" and "minorreversed"]

Overrides

NumericTickGenerator.getGrades


getInvalidateMethod

Protected getInvalidateMethod(): AttributeCallback<EventDispatcher>

invalidate Method

Returns

AttributeCallback<EventDispatcher>

method to invalidate this object

Inherited from

NumericTickGenerator.getInvalidateMethod


getLabelAnchorType

getLabelAnchorType(grade, transformation?): AnchorType

Gets label anchor type

Parameters

Name Type Description
gradestringtick grade
Optional transformationTransformationoptional transformation from model to device. It is used only for custom label anchor handler

Returns

AnchorType

Inherited from

NumericTickGenerator.getLabelAnchorType


getLabelFormat

getLabelFormat(tickGrade): Format

Returns label format

Parameters

Name Type Description
tickGradestringgrade to get format: "major", "minor", "edge"

Returns

Format

label format

Inherited from

NumericTickGenerator.getLabelFormat


getLabelRotationAngle

getLabelRotationAngle(tickGrade): number

Returns label rotation angle

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types

Returns

number

label rotation angle

Inherited from

NumericTickGenerator.getLabelRotationAngle


getLabelStyle

getLabelStyle(tickGrade): TextStyle

Returns label style

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types

Returns

TextStyle

label style

Inherited from

NumericTickGenerator.getLabelStyle


getLabelValueTransformer

getLabelValueTransformer(): ValueTransformer | (modelValue: number) => number

Gets label value transformer (by default: 'undefined' - no transformation is applied to a value)

Returns

ValueTransformer | (modelValue: number) => number

transformer label value transformer

Inherited from

NumericTickGenerator.getLabelValueTransformer


getLabelsDecimation

getLabelsDecimation(): boolean

Gets labels decimation state

Returns

boolean

labelsDecimation labels decimation state


getLocale

getLocale(): string | Locale

Return the current locale

Returns

string | Locale

Inherited from

NumericTickGenerator.getLocale


getMapping

getMapping(): Mapping

Gets primary-to-secondary values mapping.

Returns

Mapping


getMaxLabelHandler

getMaxLabelHandler(): MaxLabelEventHandler

Gets handler to return max label position

Returns

MaxLabelEventHandler

handler is called to specify max label

Inherited from

NumericTickGenerator.getMaxLabelHandler


getMaxLabelMetrics

getMaxLabelMetrics(parent, orientation, tickInfo, fromValue, toValue): Dimension

Returns maximum label metrics. For internal use only

Parameters

Name Type Description
parentIModelparent axis or grid
orientationOrientationorientation
tickInfoTickInfoinfo about tick position
fromValuenumbergenerate labels from
toValuenumbergenerate labels to

Returns

Dimension

Inherited from

NumericTickGenerator.getMaxLabelMetrics


getMaxLabels

Protected getMaxLabels(tickInfo, orient, fromValue, toValue): { type: string ; value: number }[]

Returns max labels for each type of grades

Parameters

Name Type Description
tickInfoTickInfoinfo about the tick
orientOrientationorientation
fromValuenumbergenerate labels from
toValuenumbergenerate labels to

Returns

{ type: string ; value: number }[]

array of {'type':tickGrade, 'value':maxValue}

Overrides

NumericTickGenerator.getMaxLabels


getNeatLimits

getNeatLimits(min, max, options): Limits

Return nice limits, default implementation is for linear model space

Parameters

Name Type
minnumber
maxnumber
optionsObject
Optional options.preciseboolean
options.sizenumber
options.spannumber

Returns

Limits

Inherited from

NumericTickGenerator.getNeatLimits


getProperties

getProperties(): OptionsOut

Gets all the properties pertaining to this object

Returns

OptionsOut

An object containing the properties to set

Overrides

NumericTickGenerator.getProperties


getTag

getTag(): any

Returns tag

Returns

any

the tag

Inherited from

NumericTickGenerator.getTag


getTickSize

getTickSize(tickGrade): number

Gets tick size (length)

Parameters

Name Type Description
tickGradestringtick grade

Returns

number

tickSize tick size

Overrides

NumericTickGenerator.getTickSize


getTickStep

getTickStep(tickGrade): number

Gets tick step (in secondary space)

Parameters

Name Type Description
tickGradestringtick grade

Returns

number

tick step


getTickStyle

getTickStyle(tickGrade): LineStyle

Returns tick style

Parameters

Name Type Description
tickGradestringTick Grade see TickGenerator.getGrades for valid Tick types

Returns

LineStyle

line style

Inherited from

NumericTickGenerator.getTickStyle


getVisibleLabelGrades

getVisibleLabelGrades(supported): string[]

Return an array of the visible label grades

Parameters

Name Type Description
supportedstring[]supported grades see TickGenerator.getGrades for valid Tick types

Returns

string[]

the visible grades

Inherited from

NumericTickGenerator.getVisibleLabelGrades


getVisibleTickGrades

getVisibleTickGrades(supported): string[]

Returns an array of the visible tick grades

Parameters

Name Type Description
supportedstring[]supported grades see TickGenerator.getGrades for valid Tick types

Returns

string[]

the visible grades

Inherited from

NumericTickGenerator.getVisibleTickGrades


hasEventListener

hasEventListener(type, callback?): boolean

Check if a list of event listeners for this type contains this listener

Parameters

Name Type Description
typestringtype of event or property
Optional callbackFunctionto be called, if null, check if any callback is registered

Returns

boolean

Inherited from

NumericTickGenerator.hasEventListener


isDisposed

isDisposed(): boolean

Returns whether this object has been disposed

Returns

boolean

Inherited from

NumericTickGenerator.isDisposed


isSilent

isSilent(): boolean

Return true if the event dispatcher doesn't notify any events

Returns

boolean

Inherited from

NumericTickGenerator.isSilent


isValid

isValid(parent, orient, tickInfo): boolean

Verify tick generator parameters to have better label distribution

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfotick info

Returns

boolean

true if no label intersection

Inherited from

NumericTickGenerator.isValid


isVisibleLabelGrade

isVisibleLabelGrade(tickGrade): boolean

Returns visibility of label for a specific tick grade

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types

Returns

boolean

true if label is visible

Inherited from

NumericTickGenerator.isVisibleLabelGrade


isVisibleTickGrade

isVisibleTickGrade(tickGrade): boolean

Returns visibility of tick for a specific tick grade

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types

Returns

boolean

true if the tick is visible

Inherited from

NumericTickGenerator.isVisibleTickGrade


nextLabel

nextLabel(parent, orient, tickInfo, tickIndex): number

Generates information about next label

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfoinfo about tick
tickIndexnumbertickIndex tick index from 0 to count-1, which resetLabels returns

Returns

number

the model position of the label

Inherited from

NumericTickGenerator.nextLabel


nextTick

nextTick(parent, orient, tickInfo, tickIndex): number

Generates information about next tick

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfoinfo about tick
tickIndexnumbertick index from 0 to count-1, which resetTicks returns

Returns

number

the model position of the tick

Inherited from

NumericTickGenerator.nextTick


notify

notify<E>(type, source, args?): SecondaryTickGenerator

Notify listeners

Type parameters

NameType
Eextends string

Parameters

Name Type Description
typeEevent types
sourceTickGeneratorof the event
Optional argsEventMap[E]arguments of the event

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.notify


off

off<E>(type?, callback?): SecondaryTickGenerator

Detach listener on event. Calling .off() with no arguments removes all attached listeners. Calling .off(type) with no callback removes all attached listeners for specific type.

Type parameters

NameType
Eextends string

Parameters

Name Type Description
Optional typeEtype of the event
Optional callback(eventType: E, sender: SecondaryTickGenerator, args: EventMap[E]) => voidfunction to be called

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.off


on

on<E>(type, callback): SecondaryTickGenerator

Attach listener on event that will be called whenever the specified event is delivered to the target

If the callback function is already in the list of event listeners for this target, the function is not added a second time.

If a particular anonymous function is in the list of event listeners registered for a certain target, and then later in the code, an identical anonymous function is given in an "on" call, the second function will also be added to the list of event listeners for that target.

Type parameters

NameType
Eextends string

Parameters

Name Type Description
typeEtype of event or property
callback(eventType: E, sender: SecondaryTickGenerator, args: EventMap[E]) => voidto be called

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.on


reset

reset(parent, orient, tickInfo): string[]

Resets tick generator

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfotick info

Returns

string[]

a supported tick grade list

Inherited from

NumericTickGenerator.reset


resetAsync

resetAsync(parent, orient, tickInfo, callback): void

Resets tick generator asynchronously

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfotick info
callback(x: string[]) => voidcalls when asynchronous reset is done

Returns

void

Inherited from

NumericTickGenerator.resetAsync


resetLabels

resetLabels(parent, orient, tickInfo): number

Resets labels. This method is called to start iterating through labels.

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfoan info about labels

Returns

number

labels count for the current tick type

Overrides

NumericTickGenerator.resetLabels


resetMaxLabels

resetMaxLabels(): SecondaryTickGenerator

Reset max label info

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.resetMaxLabels


resetTicks

resetTicks(parent, orient, tickInfo): number

Resets ticks. This method is called to start iteration by ticks. The implementation also sets appropriate LineStyle on the ticks as well as their tick size.

Parameters

Name Type Description
parentIModelparent axis or grid
orientOrientationorientation
tickInfoTickInfoan info about labels. This information is used to pass and receive information about the current tick or label

Returns

number

ticks count for the current tick type. The implementation returns 0 if the ticks can not be drawn; a positive number otherwise.

Inherited from

NumericTickGenerator.resetTicks


setAdjustLabelAnchor

setAdjustLabelAnchor(grade, flag): SecondaryTickGenerator

Sets adjust label anchor flag for specified label grade

Parameters

Name Type Description
gradestringlabel grade
flagbooleanadjust label anchor flag

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setAdjustLabelAnchor


setFormatLabelHandler

setFormatLabelHandler(handler): SecondaryTickGenerator

Sets label format handler

Parameters

Name Type Description
handlerLabelFormatHandlerhandler

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setFormatLabelHandler


setLabelAnchorType

setLabelAnchorType(grade, anchorType): SecondaryTickGenerator

Sets label anchor type

Parameters

Name Type Description
gradestringtick grade
anchorTypeAnchorType | AnchorStyleHandleranchorType

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLabelAnchorType


setLabelFormat

setLabelFormat(tickGrade, format): SecondaryTickGenerator

Sets label format

Throws

Error if labelformat is not supported

Example

// to set the precision of the tickGenerator labels use the following
import {NumberFormat} from '@int/geotoolkit/util/NumberFormat';
...
axis.getTickGenerator().setLabelFormat('major', new NumberFormat({'maximumfractiondigits':2}));

Parameters

Name Type Description
tickGradestringgrade to set format: "major", "minor", "edge"
formatFormatnumber format for label

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLabelFormat


setLabelRotationAngle

setLabelRotationAngle(tickGrade, angle): SecondaryTickGenerator

Sets label rotation angle

Example

// user can customize the label rotation angle based on tick grade.
tickGenerator.setLabelRotationAngle('major', -Math.PI / 2);

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types
anglenumberlabel rotation angle, in radians

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLabelRotationAngle


setLabelStyle

setLabelStyle(tickGrade, labelStyle?, merge?): SecondaryTickGenerator

Sets label style

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types
Optional labelStyleTypetick text style
Optional mergebooleantrue if you want to merge labelStyle with existing attribute, false by default

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLabelStyle


setLabelValueTransformer

setLabelValueTransformer(transformer): SecondaryTickGenerator

Sets label value transformer (optional)

Parameters

Name Type Description
transformerValueTransformer | (modelValue: number) => numberlabel value transformer

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLabelValueTransformer


setLabelsDecimation

setLabelsDecimation(labelsDecimation): SecondaryTickGenerator

Sets labels decimation state

Parameters

Name Type Description
labelsDecimationbooleanlabels decimation state

Returns

SecondaryTickGenerator

this


setLocale

setLocale(locale): SecondaryTickGenerator

Sets locale

Parameters

Name Type Description
localestring | Localelocale

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setLocale


setMapping

setMapping(primaryValues, secondaryValues): SecondaryTickGenerator

Gets primary-to-secondary values mapping.

Parameters

Name Type Description
primaryValuesnumber[]growing array of values in primary model space (the generator's axis parent model space)
secondaryValuesnumber[]an array of values in a secondary space

Returns

SecondaryTickGenerator

this


setMaxLabelHandler

setMaxLabelHandler(handler): SecondaryTickGenerator

Sets handler to return max label values

Example

// Return text
tickGenerator.setMaxLabelHandler((axis, tickInfo, orient, fromValue, toValue, array) => {
return [{'type': 'major', 'value': 'Buffalo Gap'}];
});

Example

// Return number
tickGenerator.setMaxLabelHandler((axis, tickInfo, orient, fromValue, toValue, array) => {
return [{'type': 'major', 'value': 1000}];
});

Parameters

Name Type Description
handlerMaxLabelEventHandlerhandler is called to specify max label

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setMaxLabelHandler


setProperties

setProperties(properties?): SecondaryTickGenerator

Sets all the properties pertaining to this object

Parameters

Name Type Description
Optional propertiesOptionsAn object containing the properties to set

Returns

SecondaryTickGenerator

Overrides

NumericTickGenerator.setProperties


setSilent

setSilent(bool): SecondaryTickGenerator

Set silent mode

Parameters

Name Type Description
boolbooleanflag to enable silent mode

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setSilent


setTag

setTag(tag): SecondaryTickGenerator

Sets tag

Parameters

Name Type Description
taganyuser can specify info associated with current object

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setTag


setTickOptions

setTickOptions(properties?, tickGrade?): SecondaryTickGenerator

Sets all the properties pertaining to this tick

Parameters

Name Type Description
Optional propertiesRecord<string, TickOptions>An object containing the properties to set
Optional tickGradestringTick grade

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setTickOptions


setTickSize

setTickSize(tickGrade, tickSize): SecondaryTickGenerator

Sets tick size (length)

Parameters

Name Type Description
tickGradestringtick grade
tickSizenumbertick size to set

Returns

SecondaryTickGenerator

this

Overrides

NumericTickGenerator.setTickSize


setTickStep

setTickStep(tickGrade, tickStep): SecondaryTickGenerator

Sets tick step (in secondary space)

Parameters

Name Type Description
tickGradestringtick grade
tickStepnumberamount each tick should step

Returns

SecondaryTickGenerator

this


setTickStyle

setTickStyle(tickGrade, lineStyle?, merge?): SecondaryTickGenerator

Sets tick style

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types
Optional lineStyleTypeline style for the tick
Optional mergebooleantrue if you want to merge lineStyle with existing attribute, false by default

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setTickStyle


setVisibleLabelGrade

setVisibleLabelGrade(tickGrade, visible): SecondaryTickGenerator

Sets visibility of label for a specific tick grade Implementation of the reset should check visibility of the labels.

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types
visiblebooleantick label visibility flag

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setVisibleLabelGrade


setVisibleTickGrade

setVisibleTickGrade(tickGrade, visible): SecondaryTickGenerator

Sets visibility of tick for a specific tick grade Implementation of the reset should check visibility of the ticks

Parameters

Name Type Description
tickGradestringTick grade see TickGenerator.getGrades for valid Tick types
visiblebooleantick grade visibility flag

Returns

SecondaryTickGenerator

this

Inherited from

NumericTickGenerator.setVisibleTickGrade


getClassName

Static getClassName(): string

Returns

string

Inherited from

NumericTickGenerator.getClassName