divergingChartColor function

Color divergingChartColor({
  1. required Color lowSeed,
  2. required Color highSeed,
  3. required Brightness brightness,
  4. required double t,
  5. Color? background,
  6. double contrast = 0.5,
  7. Algo algo = Algo.apca,
})

Diverging chart color at t in 0–1, neutral at exactly 0.5; see ChartColors.divergingWith.

Implementation

Color divergingChartColor({
  required Color lowSeed,
  required Color highSeed,
  required Brightness brightness,
  required double t,
  Color? background,
  double contrast = 0.5,
  Algo algo = Algo.apca,
}) {
  return _chartColors(
    lowSeed,
    brightness,
    background,
    contrast,
    algo,
  ).divergingWith(highSeed).at(t);
}