Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public class Chart
ImplementsAnimation, Editable, StyleListener
An interactive, animated chart.
Form form = new Form("Revenue", new BorderLayout());
Chart chart = new Chart()
.setXAxis(new CategoryAxis(Axis.BOTTOM, "Q1", "Q2", "Q3", "Q4"))
.setTitle("Revenue");
chart.addSeries(new BarSeries("2025").setValues(12, 18, 9, 22));
chart.addSeries(new LineSeries("Target").setDashed(true).setValues(15, 15, 15, 15));
form.add(BorderLayout.CENTER, chart);Layout is automatic: the chart measures every label before it draws, picks as many round-number ticks as fit, thins and shortens category labels that would collide and sizes the plot to whatever space is left. Data labels go through a collision layout and are dropped rather than drawn over each other.
Interaction works the same with touch, mouse, trackpad and keyboard: drag to pan once zoomed, pinch or scroll to zoom (spreading the fingers horizontally zooms only the x axis), double tap to zoom in and double tap again to reset, tap or hover a point for its tooltip, and tap a legend entry to hide or show its series. Data changes animate.
Style the component with the Chart UIID; its padding surrounds the plot, its font is
the label font and its background shows through. Colours come from ChartTheme.

Fields
public static final int LEGEND_NONE = 0 | No legend. |
public static final int LEGEND_TOP = 1 | Legend above the plot. |
public static final int LEGEND_BOTTOM = 2 | Legend below the plot. |
public static final int LEGEND_RIGHT = 3 | Legend right of the plot. |
public static final int TOOLTIP_NONE = 0 | No tooltip. |
public static final int TOOLTIP_POINT = 1 | Tooltip for the single point under the finger or pointer. |
public static final int TOOLTIP_SHARED = 2 | Tooltip listing every series at the x nearest the finger or pointer, with a crosshair. |
public static final int ZOOM_AUTO = 0 | Zoom gestures scale the value axis too unless the x axis is a category or time axis. |
public static final int ZOOM_X = 1 | Zoom gestures scale the x (category) axis only; values keep their scale. |
public static final int ZOOM_XY = 2 | Zoom gestures scale both axes, following the direction of a pinch. |
Constructors
public Chart() | Creates an empty chart with numeric axes. |
Methods
public Chart addSeries(Series s) | Adds a series, animating it in when the chart is showing. |
public Chart removeSeries(Series s) | Removes a series. |
public Chart clearSeries() | Removes every series. |
public List<Series> getSeries() | The series, in paint order. |
public int indexOf(Series s) | The position of a series, which also selects its default palette colour. |
public Chart addAnnotation(Annotation a) | Adds a reference line, band or marker. |
public Chart removeAnnotation(Annotation a) | Removes an annotation. |
public void update(Runnable changes) | Runs several data changes as one animated transition. |
public Axis getXAxis() | The x (category) axis. |
public Chart setXAxis(Axis a) | Replaces the x axis, for example with a CategoryAxis or TimeAxis. |
public Axis getYAxis() | The primary value axis. |
public Chart setYAxis(Axis a) | Replaces the primary value axis, for example with a LogAxis. |
public Axis getSecondaryYAxis() | The secondary value axis on the right, or null. |
public Chart setSecondaryYAxis(Axis a) | Adds a right hand value axis for series with setSecondaryAxis(true). |
public ChartTheme getTheme() | The colour theme. |
protected void refreshTheme(String id, boolean merge) | Makes sure the component is up to date with the given UIID |
public void styleChanged(String propertyName, Style source) | Invoked to indicate a change in a propertyName of a Style |
public Chart setTheme(ChartTheme theme) | Replaces the colour theme. |
public String getTitle() | The chart title, or null. |
public Chart setTitle(String title) | Sets a title drawn above the plot. |
public Chart setLegendPosition(int pos) | One of the LEGEND_ constants. |
public Chart setTooltipMode(int mode) | One of the TOOLTIP_ constants. |
public Chart setTooltipRenderer(TooltipRenderer r) | Customizes the tooltip’s rows. |
public boolean isRotated() | True for a horizontal bar chart: the x (category) axis runs down the left side. |
public Chart setRotated(boolean rotated) | Swaps the axes so categories run vertically and values horizontally. |
public Chart setZoomEnabled(boolean zoomEnabled) | Whether pinch, wheel, double tap and drag zoom and pan the chart. |
public Chart setZoomMode(int zoomMode) | Which axes pinch, wheel, double tap and keyboard zoom: ZOOM_AUTO (the default), ZOOM_X or ZOOM_XY. |
public int getZoomMode() | One of the ZOOM_ constants. |
public Chart setAnimationDuration(int ms) | Transition length in milliseconds; 0 applies data changes without animating. |
public Chart setLoading(String text) | Shows that data is on its way: with no data yet the text replaces the empty state, and over existing data the chart is dimmed under it. |
public boolean isLoading() | Whether setLoading is showing a loading state. |
public Chart setBrushEnabled(boolean enabled) | Makes a drag inside the plot select a range of x values instead of scrubbing or panning; pinch, the wheel and the keyboard still zoom and pan. |
public Chart setBrushZooms(boolean zooms) | Whether a brush selection also zooms the chart to it; true by default. |
public void addRangeListener(RangeListener l) | Adds a listener for brush selections. |
public void removeRangeListener(RangeListener l) | Removes a brush selection listener. |
public Chart setEmptyText(String text) | Text shown when there is nothing to plot. |
public void addSelectionListener(SelectionListener l) | Listens for taps on data points. |
public void removeSelectionListener(SelectionListener l) | Stops listening. |
public Chart setSelection(Series s, int index) | Selects point index of s and shows its tooltip, as a tap on it would; null clears the selection. |
public Chart showTooltipAtX(double x) | Shows the shared tooltip and crosshair at data x x, as a tap there would in TOOLTIP_SHARED mode; linked charts follow. |
public double getTooltipX() | The data x the shared tooltip shows, or NaN when it shows none. |
public Chart setLegendToggles(boolean toggles) | Whether tapping a legend entry hides and shows its series (the default). |
public boolean isLegendToggles() | Whether tapping a legend entry hides and shows its series. |
public void addLegendListener(LegendListener l) | Listens for taps on legend entries. |
public void removeLegendListener(LegendListener l) | Stops listening. |
public ChartPoint getSelection() | The selected point, or null. |
public ChartContext getLastContext() | The frame last painted; hit testing and transitions read its geometry. |
public Image toImage(int width, int height) | Renders the chart into an image, for sharing or export. |
public void beginChange() | Snapshots what is on screen as the start of the next transition. |
protected void initComponent() | Allows subclasses to bind functionality that relies on fully initialized and “ready for action” component state |
protected void deinitialize() | Invoked to indicate that the component initialization is being reversed since the component was detached from the container hierarchy. |
public boolean animate() | Allows the animation to reduce “repaint” calls when it returns false. |
protected Dimension calcPreferredSize() | Calculates the preferred size based on component content. |
public void paint(Graphics g) | This method paints the Component on the screen, it should be overriden by subclasses to perform custom drawing or invoke the UI API’s to let the PLAF perform the rendering. |
public List<String[]> getTableRows() | The chart’s data as rows of {series, item, value}, in series order. |
public TableModel toTableModel() | The chart’s data as a table model with the columns Series, Item and Value, for a data table view, export, or a screen reader friendly alternative to the picture. |
public Table toTable() | A table component showing the chart’s data; offer it beside or instead of the chart for readers who cannot see it. |
public String describe() | A one paragraph summary of the chart for screen readers: its title and, for each series, how many values it has and their range. |
public String getAccessibilityText() | The accessibility text set on the chart, or a generated summary of its data. |
public ChartPoint hitTest(int x, int y) | Finds the point at a chart relative position, the topmost series first. |
public void pointerPressed(int x, int y) | If this Component is focused, the pointer pressed event will call this method |
public void pointerDragged(int[] x, int[] y) | If this Component is focused, the pointer dragged event will call this method |
protected void pinchReleased(int x, int y) | To be implemented by subclasses interested in being notified when a pinch zoom has ended (i.e the user has removed one of their fingers, but is still dragging). |
public void pointerReleased(int x, int y) | If this Component is focused, the pointer released event will call this method |
public void resetZoom() | Returns to the full data range with an animation. |
protected boolean mouseWheel(WheelEvent ev) | Handles a scroll wheel or trackpad scroll over this component, before its listeners and before anything above it in the hierarchy. |
public void pointerHover(int[] x, int[] y) | Invoked for devices where the pointer can hover without actually clicking the display. |
public void pointerHoverReleased(int[] x, int[] y) | Invoked for devices where the pointer can hover without actually clicking the display. |
public void keyReleased(int keyCode) | If this Component is focused, the key released event will call this method |
public void syncWith(Chart other) | Links this chart’s x axis viewport and crosshair with other charts, as a price chart and its volume or indicator panes need: panning or zooming one pans the others. |
public void unsync() | Leaves the group joined with syncWith: this chart stops following the others and they stop following it, while the rest of the group stays linked. |
Inherited fields
From Component
DEFAULT_CURSOR, CROSSHAIR_CURSOR, TEXT_CURSOR, WAIT_CURSOR, SW_RESIZE_CURSOR, SE_RESIZE_CURSOR, NW_RESIZE_CURSOR, NE_RESIZE_CURSOR, N_RESIZE_CURSOR, S_RESIZE_CURSOR, W_RESIZE_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, MOVE_CURSOR, DRAG_REGION_NOT_DRAGGABLE, DRAG_REGION_POSSIBLE_DRAG_X, DRAG_REGION_POSSIBLE_DRAG_Y, DRAG_REGION_POSSIBLE_DRAG_XY, DRAG_REGION_LIKELY_DRAG_X, DRAG_REGION_LIKELY_DRAG_Y, DRAG_REGION_LIKELY_DRAG_XY, DRAG_REGION_IMMEDIATELY_DRAG_X, DRAG_REGION_IMMEDIATELY_DRAG_Y, DRAG_REGION_IMMEDIATELY_DRAG_XY, BRB_CONSTANT_ASCENT, BRB_CONSTANT_DESCENT, BRB_CENTER_OFFSET, BRB_OTHER, CENTER, TOP, LEFT, BOTTOM, RIGHT, BASELINE
Inherited methods
From Component
setSameSize, isSetCursorSupported, parsePreferredSize, getDefaultDragTransparency, setDefaultDragTransparency, getEditingDelegate, setEditingDelegate, getCursor, setCursor, showNativeOverlay, hideNativeOverlay, updateNativeOverlay, getNativeOverlay, getAllStyles, getSameWidth, setSameWidth, getSameHeight, setSameHeight, initLaf, getUIManager, getX, setX, getOuterX, getInnerX, getY, setY, getOuterY, getInnerY, isVisible, setVisible, getClientProperty, stripMarginAndPadding, clearClientProperties, putClientProperty, getDirtyRegion, setDirtyRegion, isOpaque, setOpaque, getWidth, setWidth, getOuterWidth, getInnerWidth, getHeight, setHeight, getOuterHeight, getInnerHeight, isDragRegion, getDragRegionStatus, getBaseline, getBaselineResizeBehavior, getPreferredSizeStr, setPreferredSizeStr, getPreferredSize, setPreferredSize, getScrollDimension, calcScrollSize, setScrollSize, getPreferredW, setPreferredW, getPreferredH, setPreferredH, getOuterPreferredH, getInnerPreferredH, getOuterPreferredW, getInnerPreferredW, setSize, getUIID, setUIID, setUIIDFinal, setUIID, getInlineAllStyles, setInlineAllStyles, getInlineSelectedStyles, setInlineSelectedStyles, getInlineUnselectedStyles, setInlineUnselectedStyles, getInlineDisabledStyles, setInlineDisabledStyles, getInlinePressedStyles, setInlinePressedStyles, remove, getParent, getOwner, setOwner, isOwnedBy, containsOrOwns, addFocusListener, removeFocusListener, addScrollListener, removeScrollListener, fireClicked, isSelectableInteraction, getSelectCommandText, setSelectCommandText, getLabelForComponent, setLabelForComponent, focusGained, focusLost, paintBackgrounds, paintShadows, getAbsoluteX, getAbsoluteY, isInClippingRegion, paintIntersectingComponentsAbove, paintScrollbars, paintScrollbarX, getScrollOpacity, getSelectedRect, paintScrollbarY, paintComponent, paintComponent, getBorder, getScrollable, paintBackground, isScrollable, isScrollableX, isScrollableY, getScrollX, setScrollX, getScrollY, setScrollY, onScrollX, onScrollY, getDraggedx, getDraggedy, getBottomGap, getSideGap, contains, visibleBoundsContains, hasFixedPreferredSize, getBounds, getBounds, getVisibleBounds, getVisibleBounds, isFocusable, setFocusable, onSetFocusable, resetFocusable, getTabIndex, setTabIndex, getPreferredTabIndex, setPreferredTabIndex, isTraversable, setTraversable, setShouldCalcPreferredSize, handlesInput, setHandlesInput, consumesRawTextInput, hasFocus, setFocus, getComponentForm, getTopLevelContainer, repaint, repaint, longKeyPress, keyPressed, keyRepeated, registerForAnimation, deregisterFromAnimation, getAnimationManager, getScrollAnimationSpeed, setScrollAnimationSpeed, isBlockLead, setBlockLead, isIgnorePointerEvents, setIgnorePointerEvents, isRippleEffect, setRippleEffect, getInlineStylesTheme, setInlineStylesTheme, shouldRenderComponentSelection, isHideInLandscape, setHideInLandscape, createStyleAnimation, isSmoothScrolling, setSmoothScrolling, stopScrollMomentum, pointerHoverPressed, pinch, pinch, rotation, isPinchBlocksDragAndDrop, setPinchBlocksDragAndDrop, getDragImage, getDragTransparency, setDragTransparency, toImage, dragInitiated, drawDraggedImage, draggingOver, dragEnter, dragExit, drop, addPullToRefresh, setPullToRefresh, respondsToPointerEvents, pointerDragged, isStickyDrag, pointerPressed, isDragAndDropOperation, pointerReleased, longPointerPress, setVerticalScrollBounds, setHorizontalScrollBounds, isVScrollThumbGrabbed, isHScrollThumbGrabbed, isVScrollThumbHover, isHScrollThumbHover, isTensileDragEnabled, setTensileDragEnabled, getTextSelectionSupport, addDropListener, removeDropListener, addDragOverListener, removeDragOverListener, isNativeDragSource, setNativeDragSource, getNativeDragOperation, setNativeDragOperation, createNativeDragOperation, isNativeDropTarget, setNativeDropTarget, getAcceptedDropMimeTypes, setAcceptedDropMimeTypes, getAcceptedDropActions, setAcceptedDropActions, canAcceptNativeDrop, nativeDragEnter, nativeDragOver, nativeDragExit, nativeDrop, addNativeDropListener, removeNativeDropListener, addNativeDragOverListener, removeNativeDragOverListener, dragFinished, addDragFinishedListener, addStateChangeListener, removeStateChangeListener, addPointerPressedListener, addLongPressListener, addContextMenuListener, removeContextMenuListener, addMouseWheelListener, removeMouseWheelListener, addStylusListener, removeStylusListener, getContextMenuCommands, setContextMenuCommands, paintRippleOverlay, removePointerPressedListener, removeLongPressListener, removeDragFinishedListener, addPointerReleasedListener, removePointerReleasedListener, addPointerDraggedListener, removePointerDraggedListener, getDragSpeed, getStyle, getPressedStyle, getHoverStyle, setHoverStyle, isHovered, setHovered, setPressedStyle, initUnselectedStyle, initPressedStyle, initDisabledStyle, initSelectedStyle, getUnselectedStyle, setUnselectedStyle, getSelectedStyle, setSelectedStyle, getDisabledStyle, setDisabledStyle, installDefaultPainter, requestFocus, toString, paramString, refreshTheme, refreshTheme, isDragActivated, getGridPosY, getGridPosX, scrollRectToVisible, scrollRectToVisible, paintBorder, paintBorderBackground, isCellRenderer, setCellRenderer, isScrollVisible, setScrollVisible, setIsScrollVisible, startEditingAsync, stopEditing, isEditing, isEditable, laidOut, isInitialized, setInitialized, getNextFocusDown, setNextFocusDown, getNextFocusUp, setNextFocusUp, getNextFocusLeft, setNextFocusLeft, getNextFocusRight, setNextFocusRight, isEnabled, setEnabled, getName, setName, initCustomStyle, deinitializeCustomStyle, isRTL, setRTL, isTactileTouch, isTactileTouch, setTactileTouch, getPropertyNames, getPropertyTypes, getPropertyTypeNames, getPropertyValue, setPropertyValue, paintLockRelease, paintLock, isSnapToGrid, setSnapToGrid, shouldBlockSideSwipe, shouldBlockSideSwipeLeft, shouldBlockSideSwipeRight, blocksSideSwipe, isFlatten, setFlatten, getTensileLength, setTensileLength, isGrabsPointerEvents, setGrabsPointerEvents, getScrollOpacityChangeSpeed, setScrollOpacityChangeSpeed, growShrink, isAlwaysTensile, setAlwaysTensile, isDraggable, setDraggable, isDropTarget, setDropTarget, isChildOf, isHideInPortrait, setHideInPortrait, cancelRepaints, getBindablePropertyNames, getBindablePropertyTypes, bindProperty, unbindProperty, getBoundPropertyValue, setBoundPropertyValue, getCloudBoundProperty, setCloudBoundProperty, getCloudDestinationProperty, setCloudDestinationProperty, getComponentState, setComponentState, setHidden, isHidden, setHidden, isHidden, announceForAccessibility, setAccessibilityText, getSemantics, getAccessibilityNode, accessibilityChanged, accessibilityChanged, getTooltip, setTooltip
Field details
LEGEND_NONE
public static final int LEGEND_NONE = 0LEGEND_TOP
public static final int LEGEND_TOP = 1LEGEND_BOTTOM
public static final int LEGEND_BOTTOM = 2LEGEND_RIGHT
public static final int LEGEND_RIGHT = 3TOOLTIP_NONE
public static final int TOOLTIP_NONE = 0TOOLTIP_POINT
public static final int TOOLTIP_POINT = 1TOOLTIP_SHARED
public static final int TOOLTIP_SHARED = 2ZOOM_AUTO
public static final int ZOOM_AUTO = 0ZOOM_X
public static final int ZOOM_X = 1ZOOM_XY
public static final int ZOOM_XY = 2Constructor details
Chart
public Chart()Method details
addSeries
public Chart addSeries(Series s)removeSeries
public Chart removeSeries(Series s)clearSeries
public Chart clearSeries()getSeries
public List<Series> getSeries()indexOf
public int indexOf(Series s)addAnnotation
public Chart addAnnotation(Annotation a)removeAnnotation
public Chart removeAnnotation(Annotation a)update
public void update(Runnable changes)getXAxis
public Axis getXAxis()setXAxis
public Chart setXAxis(Axis a)CategoryAxis or TimeAxis.getYAxis
public Axis getYAxis()setYAxis
public Chart setYAxis(Axis a)LogAxis.getSecondaryYAxis
public Axis getSecondaryYAxis()setSecondaryYAxis
public Chart setSecondaryYAxis(Axis a)Adds a right hand value axis for series with setSecondaryAxis(true).
A rotated chart (setRotated(true)) has no room for a second horizontal value axis,
so while it is rotated the secondary axis is neither laid out nor painted and its series
and annotations are measured against the primary value axis instead.
getTheme
public ChartTheme getTheme()refreshTheme
protected void refreshTheme(String id, boolean merge)Parameters
idString- The Style Id to update the Component with
mergeboolean- indicates if the current styles should be merged with the new styles
styleChanged
public void styleChanged(String propertyName, Style source)Invoked to indicate a change in a propertyName of a Style
NOTE By default this will trigger a call to Container#revalidate() on the parent
container, which is expensive. You can disable this behavior by calling CN.setProperty("Component.revalidateOnStyleChange", "false").
The intention is to change this behavior so that the default is to “not” revalidate on style change, so we encourage you to
set this to “false” to ensure for future compatibility.
Parameters
propertyNameString- the property name that was changed
sourceStyle- The changed Style object
setTheme
public Chart setTheme(ChartTheme theme)getTitle
public String getTitle()setTitle
public Chart setTitle(String title)setLegendPosition
public Chart setLegendPosition(int pos)LEGEND_ constants. The default is below the plot; a chart with a single
series and no pie hides its legend automatically.setTooltipMode
public Chart setTooltipMode(int mode)TOOLTIP_ constants.setTooltipRenderer
public Chart setTooltipRenderer(TooltipRenderer r)isRotated
public boolean isRotated()setRotated
public Chart setRotated(boolean rotated)setZoomEnabled
public Chart setZoomEnabled(boolean zoomEnabled)setZoomMode
public Chart setZoomMode(int zoomMode)ZOOM_AUTO (the default),
ZOOM_X or ZOOM_XY.getZoomMode
public int getZoomMode()ZOOM_ constants.setAnimationDuration
public Chart setAnimationDuration(int ms)setLoading
public Chart setLoading(String text)setLoading(null), so a caller
that loads in steps decides when the data is complete.Parameters
textString- the text to show, or null to stop showing it
Returns
isLoading
public boolean isLoading()setLoading is showing a loading state.setBrushEnabled
public Chart setBrushEnabled(boolean enabled)addRangeListener and, unless setBrushZooms(false), the chart zooms to it. While the
chart is zoomed a one finger drag pans instead, so a zoomed chart stays reachable by
touch; resetting the zoom brings the brush back.Parameters
enabledboolean- true to brush
Returns
setBrushZooms
public Chart setBrushZooms(boolean zooms)Parameters
zoomsboolean- false to only report the selection
Returns
addRangeListener
public void addRangeListener(RangeListener l)removeRangeListener
public void removeRangeListener(RangeListener l)setEmptyText
public Chart setEmptyText(String text)addSelectionListener
public void addSelectionListener(SelectionListener l)removeSelectionListener
public void removeSelectionListener(SelectionListener l)setSelection
public Chart setSelection(Series s, int index)index of s and shows its tooltip, as a tap on it would; null
clears the selection. Arrow-key stepping continues from the point, and the screen
reader announces it. Selection listeners are not called: they report the user’s
taps and keys, and the caller already knows what it selected. Before the chart is
first painted the selection is kept and applied by that paint.showTooltipAtX
public Chart showTooltipAtX(double x)x, as a tap there would in
TOOLTIP_SHARED mode; linked charts follow. Does nothing in other modes.getTooltipX
public double getTooltipX()setLegendToggles
public Chart setLegendToggles(boolean toggles)isLegendToggles
public boolean isLegendToggles()addLegendListener
public void addLegendListener(LegendListener l)removeLegendListener
public void removeLegendListener(LegendListener l)getSelection
public ChartPoint getSelection()getLastContext
public ChartContext getLastContext()toImage
public Image toImage(int width, int height)beginChange
public void beginChange()update(Runnable) instead.initComponent
protected void initComponent()deinitialize
protected void deinitialize()animate
public boolean animate()com.codename1.ui.Display class.Returns
calcPreferredSize
protected Dimension calcPreferredSize()Returns
paint
public void paint(Graphics g)Parameters
gGraphics- the component graphics
getTableRows
public List<String[]> getTableRows(){series, item, value}, in series order. Hidden series are
included: the table is the complete data, not what happens to be on screen. A gap has no
value and no row.Returns
toTableModel
public TableModel toTableModel()Returns
toTable
public Table toTable()Returns
describe
public String describe()Returns
getAccessibilityText
public String getAccessibilityText()Returns
null if nonehitTest
public ChartPoint hitTest(int x, int y)pointerPressed
public void pointerPressed(int x, int y)Parameters
xint- the pointer x coordinate
yint- the pointer y coordinate
pointerDragged
public void pointerDragged(int[] x, int[] y)Parameters
xint[]- the pointer x coordinate
yint[]- the pointer y coordinate
pinchReleased
protected void pinchReleased(int x, int y)Parameters
xint- The x-coordinate of the remaining finger in the drag. (Absolute)
yint- The y-coordinate of the remaining finger in the drag. (Absolute)
pointerReleased
public void pointerReleased(int x, int y)Parameters
xint- the pointer x coordinate
yint- the pointer y coordinate
resetZoom
public void resetZoom()mouseWheel
protected boolean mouseWheel(WheelEvent ev)Handles a scroll wheel or trackpad scroll over this component, before its listeners and before anything above it in the hierarchy.
A component that moves its own content – an editor that scrolls itself, a viewer that pans – implements this. Everything else leaves it alone and the wheel scrolls the nearest scrollable ancestor, which is what a wheel means.
This exists because a wheel used to arrive as a synthetic press, drag and release played into the component tree: a component that wanted the wheel got it by handling pointer events, and so did every component that did not want it. The events are gone and this is what replaces them, for the few components that have something of their own to move.
Parameters
evWheelEvent- the wheel event, carrying the scroll deltas in display pixels
Returns
pointerHover
public void pointerHover(int[] x, int[] y)Parameters
xint[]- the pointer x coordinate
yint[]- the pointer y coordinate
pointerHoverReleased
public void pointerHoverReleased(int[] x, int[] y)Parameters
xint[]- the pointer x coordinate
yint[]- the pointer y coordinate
keyReleased
public void keyReleased(int keyCode)Parameters
keyCodeint- the key code value to indicate a physical key.
syncWith
public void syncWith(Chart other)unsync
public void unsync()syncWith: this chart stops following the others and
they stop following it, while the rest of the group stays linked. Removing a chart
from its form does not unlink it, so a chart shown again keeps syncing; call this when
a linked chart is discarded.