SciChart Android 2D Charts API > ChartModifier API > ChartModifier APIs > Common ChartModifiers Features
Common ChartModifiers Features

All the ChartModifiers provided by SciChart implement the IChartModifier interface and derive from the ChartModifierBase class. These provide a powerful API which gives the full access to internals of a chart, axes, series, annotations. It is a must that Custom Modifiers implement IChartModifier; we recommend inheriting ChartModifierBase in such cases as well.

Please refer to the What is a ChartModifier article for the complete list of all the Chart Modifiers available out of the box in SciChart.

Common Features of Chart Modifiers

Feature Description
getParentSurface() Returns the surface which a modifier is attached to. See the isAttached() method below.
getModifierSurface() Returns the ModifierSurface from the parental SciChartSurface. It is used to place Views like tooltips, etc. onto it.
isAttached() Returns a value indicating whether a modifier is attached to a SciChartSurface or not. If it is, the getParentSurface() method will return the corresponding instance of SciChartSurface.
getIsEnabled()setIsEnabled() Allows to specify if a modifier should be available for interaction or not.
getReceiveHandledEvents()setReceiveHandledEvents() Allows to specify whether a modifier should receive events handled by another modifier.

ModifierGroup Features

ModifierGroup allows grouping of modifiers. This can be useful if modifiers create a logical group within which they are handled together. For example, all modifiers inside a ModifierGroup can be enabled/disabled together by calling setIsEnabled() on the ModifierGroup itself.

Also, this is useful in multi-chart scenarios. Several ModifierGroups can be united to share motion events between charts. This can be done setting MotionEventGroup to be the same for ModifierGroups which belong to different SciChartSurfaces.

Feature Description
getMotionEventGroup()setMotionEventGroup() Allows to specify which MotionEventGroup this modifier goes in. It is used to share motion events between modifiers that belong to different surfaces.
getEventsSource() Returns the ModifierSurface which is the source of motion events.
getChildModifiers()setChildModifiers() Assigns a collection of modifiers to a ModifierGroup. Also a collection can be passed into the class constructor during creation.

 For more detailed information about the ChartModifiers API, please refer to the Custom Modifiers - ChartModifierBase API article.

See Also