SfThemeData constructor

SfThemeData({
  1. Brightness? brightness,
  2. SfPdfViewerThemeData? pdfViewerThemeData,
  3. SfChartThemeData? chartThemeData,
  4. SfCalendarThemeData? calendarThemeData,
  5. SfDataGridThemeData? dataGridThemeData,
  6. SfDataPagerThemeData? dataPagerThemeData,
  7. SfDateRangePickerThemeData? dateRangePickerThemeData,
  8. SfBarcodeThemeData? barcodeThemeData,
  9. SfGaugeThemeData? gaugeThemeData,
  10. SfSliderThemeData? sliderThemeData,
  11. SfRangeSliderThemeData? rangeSliderThemeData,
  12. SfRangeSelectorThemeData? rangeSelectorThemeData,
  13. SfMapsThemeData? mapsThemeData,
})

Creating an argument constructor of SfThemeData class.

Implementation

factory SfThemeData(
    {Brightness? brightness,
    SfPdfViewerThemeData? pdfViewerThemeData,
    SfChartThemeData? chartThemeData,
    SfCalendarThemeData? calendarThemeData,
    SfDataGridThemeData? dataGridThemeData,
    SfDataPagerThemeData? dataPagerThemeData,
    SfDateRangePickerThemeData? dateRangePickerThemeData,
    SfBarcodeThemeData? barcodeThemeData,
    SfGaugeThemeData? gaugeThemeData,
    SfSliderThemeData? sliderThemeData,
    SfRangeSliderThemeData? rangeSliderThemeData,
    SfRangeSelectorThemeData? rangeSelectorThemeData,
    SfMapsThemeData? mapsThemeData}) {
  brightness ??= Brightness.light;
  pdfViewerThemeData =
      pdfViewerThemeData ?? SfPdfViewerThemeData(brightness: brightness);
  chartThemeData = chartThemeData ?? SfChartThemeData(brightness: brightness);
  calendarThemeData =
      calendarThemeData ?? SfCalendarThemeData(brightness: brightness);
  dataGridThemeData =
      dataGridThemeData ?? SfDataGridThemeData(brightness: brightness);
  dateRangePickerThemeData = dateRangePickerThemeData ??
      SfDateRangePickerThemeData(brightness: brightness);
  barcodeThemeData =
      barcodeThemeData ?? SfBarcodeThemeData(brightness: brightness);
  gaugeThemeData = gaugeThemeData ?? SfGaugeThemeData(brightness: brightness);
  sliderThemeData =
      sliderThemeData ?? SfSliderThemeData(brightness: brightness);
  rangeSelectorThemeData = rangeSelectorThemeData ??
      SfRangeSelectorThemeData(brightness: brightness);
  rangeSliderThemeData =
      rangeSliderThemeData ?? SfRangeSliderThemeData(brightness: brightness);
  mapsThemeData = mapsThemeData ?? SfMapsThemeData(brightness: brightness);
  dataPagerThemeData =
      dataPagerThemeData ?? SfDataPagerThemeData(brightness: brightness);
  return SfThemeData.raw(
      brightness: brightness,
      pdfViewerThemeData: pdfViewerThemeData,
      chartThemeData: chartThemeData,
      calendarThemeData: calendarThemeData,
      dataGridThemeData: dataGridThemeData,
      dataPagerThemeData: dataPagerThemeData,
      dateRangePickerThemeData: dateRangePickerThemeData,
      barcodeThemeData: barcodeThemeData,
      gaugeThemeData: gaugeThemeData,
      sliderThemeData: sliderThemeData,
      rangeSelectorThemeData: rangeSelectorThemeData,
      rangeSliderThemeData: rangeSliderThemeData,
      mapsThemeData: mapsThemeData);
}