ImChart class
The easiest, zero-boilerplate entry point for Im Charts.
Can be used in three ways:
- Zero-boilerplate static chart:
ImChart.simple( candles: myCandleList, ) - Instant live streaming chart:
ImChart.live( initialCandles: myCandleList, liveTickStream: myTickStream, ) - Controller-driven chart:
ImChart( controller: myChartController, )
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- ImChart
Constructors
-
ImChart({Key? key, TradingChartController? controller, List<
Candle> ? candles, Stream<Tick> ? liveTickStream, String symbol = 'NIFTY 50', String exchange = 'NSE', String brandName = 'Im Charts', Timeframe timeframe = Timeframe.fiveMinutes, CandleStyle candleStyle = CandleStyle.candles, ChartTheme? theme, List<Indicator> ? indicators, List<ChartOrder> ? orders, List<ChartPosition> ? positions, bool showToolbar = false, bool showHeader = true, bool showDrawingToolbar = false, bool showVolume = true, bool showVolumeProfile = false, bool showSMC = false, bool showWatermark = true, bool showCountdownTimer = true, bool enableChartTrading = true, bool enableContextMenu = true, ChartLayoutMode layoutMode = ChartLayoutMode.auto, double mobileBreakpoint = 600.0, GlobalKey<State< ? repaintBoundaryKey, void onOrderPlaced(ChartOrder order)?, void onOrderModified(ChartOrder order)?, void onOrderCancelled(String orderId)?, void onPositionClosed(ChartPosition position)?})StatefulWidget> > -
Default constructor accommodating both controller-driven and props-driven usage.
const
-
ImChart.live({Key? key, required List<
Candle> candles, required Stream<Tick> liveTickStream, String symbol = 'NIFTY 50', String exchange = 'NSE', String brandName = 'Im Charts', Timeframe timeframe = Timeframe.fiveMinutes, CandleStyle candleStyle = CandleStyle.candles, ChartTheme? theme, List<Indicator> ? indicators, List<ChartOrder> ? orders, List<ChartPosition> ? positions, bool showToolbar = false, bool showHeader = true, bool showDrawingToolbar = false, bool showVolume = true, bool showVolumeProfile = false, bool showSMC = false, bool showWatermark = true, bool showCountdownTimer = true, bool enableChartTrading = true, bool enableContextMenu = true, ChartLayoutMode layoutMode = ChartLayoutMode.auto, double mobileBreakpoint = 600.0, GlobalKey<State< ? repaintBoundaryKey, void onOrderPlaced(ChartOrder order)?, void onOrderModified(ChartOrder order)?, void onOrderCancelled(String orderId)?, void onPositionClosed(ChartPosition position)?})StatefulWidget> > -
Instant zero-boilerplate constructor for real-time live streaming charts.
const
-
ImChart.simple({Key? key, required List<
Candle> candles, String symbol = 'NIFTY 50', String exchange = 'NSE', String brandName = 'Im Charts', Timeframe timeframe = Timeframe.fiveMinutes, CandleStyle candleStyle = CandleStyle.candles, ChartTheme? theme, List<Indicator> ? indicators, List<ChartOrder> ? orders, List<ChartPosition> ? positions, bool showToolbar = false, bool showHeader = true, bool showDrawingToolbar = false, bool showVolume = true, bool showVolumeProfile = false, bool showSMC = false, bool showWatermark = true, bool showCountdownTimer = true, bool enableChartTrading = true, bool enableContextMenu = true, ChartLayoutMode layoutMode = ChartLayoutMode.auto, double mobileBreakpoint = 600.0, GlobalKey<State< ? repaintBoundaryKey, void onOrderPlaced(ChartOrder order)?, void onOrderModified(ChartOrder order)?, void onOrderCancelled(String orderId)?, void onPositionClosed(ChartPosition position)?})StatefulWidget> > -
Instant zero-boilerplate constructor for an existing list of candles.
const
Properties
- brandName → String
-
final
-
candles
→ List<
Candle> ? -
final
- candleStyle → CandleStyle
-
final
- controller → TradingChartController?
-
final
- enableChartTrading → bool
-
final
- enableContextMenu → bool
-
final
- exchange → String
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
indicators
→ List<
Indicator> ? -
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- layoutMode → ChartLayoutMode
-
final
-
liveTickStream
→ Stream<
Tick> ? -
final
- mobileBreakpoint → double
-
final
- onOrderCancelled → void Function(String orderId)?
-
final
- onOrderModified → void Function(ChartOrder order)?
-
final
- onOrderPlaced → void Function(ChartOrder order)?
-
final
- onPositionClosed → void Function(ChartPosition position)?
-
final
-
orders
→ List<
ChartOrder> ? -
final
-
positions
→ List<
ChartPosition> ? -
final
-
repaintBoundaryKey
→ GlobalKey<
State< ?StatefulWidget> > -
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- showCountdownTimer → bool
-
final
- showDrawingToolbar → bool
-
final
- showHeader → bool
-
final
- showSMC → bool
-
final
- showToolbar → bool
-
final
- showVolume → bool
-
final
- showVolumeProfile → bool
-
final
- showWatermark → bool
-
final
- symbol → String
-
final
- theme → ChartTheme?
-
final
- timeframe → Timeframe
-
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< ImChart> -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited