Top
You are looking at an outdated 7.4.0 version of this document. Switch to the 8.0.1 version to see the up to date information.

class anychart.core.axes.Ticks Improve this Doc

Extends: anychart.core.VisualBase

Axis ticks class.
You can change position, length and line features.

Methods Overview

Miscellaneous
length()Getter for current ticks length.
position()Getter for the current ticks position.
stroke()Sets stroke settings.

Methods Description

length

Getter for current ticks length.

Returns:

number - Length of ticks.
Setter for ticks length.

Params:

Name Type Description
value number Value to set.

Returns:

anychart.core.axes.Ticks - Self instance for method chaining.

position

Getter for the current ticks position.

Returns:

anychart.enums.SidePosition string - Current position.
Setter for ticks position.
You can set ticks inside of a chart area or outside its position.

Params:

Name Type Default Description
value anychart.enums.SidePosition | string
anychart.enums.SidePosition.OUTSIDE
Value to set.

Returns:

anychart.core.axes.Ticks - Self instance for method chaining.

stroke

Returns a current stroke settings.

Returns:

anychart.graphics.vector.Stroke - Returns the current stroke settings.
Sets stroke settings via single parameter.
The following options are acceptable: Note: String parts order is significant and '3px red' is not the same as 'red 3px'.

Params:

Name Type Default Description
value anychart.graphics.vector.Stroke
'black'
Fill style as '[thickness ]color[ opacity]'.

Returns:

anychart.core.axes.Ticks - Self instance for method chaining.
Example
ticks.stroke('2 blue .7');