Legend<D> constructor

Legend<D>({
  1. required SelectionModelType selectionModelType,
  2. required LegendEntryGenerator<D> legendEntryGenerator,
  3. TextStyleSpec? entryTextStyle,
})

Implementation

Legend({
  required this.selectionModelType,
  required this.legendEntryGenerator,
  TextStyleSpec? entryTextStyle,
}) {
  _lifecycleListener = LifecycleListener(
    onPostprocess: _postProcess,
    onPreprocess: _preProcess,
    onData: onData,
  );
  legendEntryGenerator.entryTextStyle = entryTextStyle;

  // Calling the setter will automatically use a non-null default value.
  showOverlaySeries = null;
}