Class: c3.Plot.Layer.Region
Defined in: | js/c3-layers.coffee |
Inherits: | c3.Plot.Layer |
Overview
Render a rectangular region in an XY Plot Chart.
Define x
and x2
options for vertical regions,
y
and y2
for horizontal regions, or all four for rectangular regions.
The regions may be enabled to be draggable
and/or resizable
.
The chart will move or resize the region interactively, however it is up to
the user code to modify the data elements based on the drag
or dragend
events. These callbacks are called with a structure of the new values and
the data element as parameters. The structure of new values is an object
with x
, x2
and y
, y2
members.
Extensibility
The following c3.Selection members are made available if appropriate:
- regions
- rects
Events
- dragstart - called with the data element.
- drag - called with the new position and the data element.
- dragend - called with the new position and the data element.
Variables Summary
- type =
-
'region'
Variable inherited from c3.Plot.Layer
version type _next_uid data name class static_data h v x y h_orient v_orient options handlers restyle
Instance Method Summary
- # (void) _init() Bound
- # (void) _size() Bound
- # (void) _update(origin) Bound
- # (void) _draw(origin) Bound
- # (void) _style(style_new) Bound
Inherited Method Summary
Methods inherited from
c3.Plot.Layer
#init #size #update #draw #style #zoom #pan #redraw #scale #min_x #max_x #min_y #max_y
Instance Method Details
#
(void)
_init()
Bound
#
(void)
_size()
Bound
#
(void)
_update(origin)
Bound
#
(void)
_draw(origin)
Bound
#
(void)
_style(style_new)
Bound