PlannerConfig<T> constructor

PlannerConfig<T>({
  1. required List<String> labels,
  2. int minHour = 0,
  3. int maxHour = 23,
  4. String hourLabelFormatter(
    1. int hour
    )?,
  5. int blockWidth = 200,
  6. int blockHeight = 40,
  7. int snapMinutes = 15,
  8. int snapMinutesForZoom(
    1. double zoom
    )?,
  9. double minZoom = 0.5,
  10. double maxZoom = 4.0,
  11. TextStyle hourLabelStyle = const TextStyle(color: Colors.black),
  12. TextStyle dateLabelStyle = const TextStyle(color: Colors.black),
  13. TextStyle contextMenuTextStyle = const TextStyle(color: Colors.blue),
  14. TextStyle contextMenuDeleteTextStyle = const TextStyle(color: Colors.red),
  15. String contextMenuCreateLabel = 'Create Event',
  16. String contextMenuEditLabel = 'Edit Event',
  17. String contextMenuDeleteLabel = 'Delete Event',
  18. SpanOverlap spanOverlap = SpanOverlap.fullWidth,
  19. int? highlightedColumn,
  20. Color highlightColumnColor = const Color.fromARGB(40, 255, 255, 255),
  21. Color hourBackground = Colors.white,
  22. Color dateBackground = Colors.white,
  23. Color contextMenuBackground = Colors.white,
  24. bool showZoomControls = true,
  25. Color? zoomButtonColor,
  26. Color zoomButtonIconColor = Colors.white,
  27. double scrollStep = 20,
  28. bool showAllDayBand = false,
  29. double allDayBandLaneHeight = 24,
  30. Color allDayBandBackground = const Color.fromARGB(255, 60, 60, 60),
  31. Color plannerBackground = const Color.fromARGB(255, 50, 50, 50),
  32. Color horizontalLineColor = const Color.fromARGB(255, 100, 100, 100),
  33. Color verticalLineColor = const Color.fromARGB(255, 150, 150, 150),
  34. dynamic onEntryCreate(
    1. PlannerTime time
    )?,
  35. void onEntryDelete(
    1. PlannerEntry<T> entry
    )?,
  36. void onEntryEdit(
    1. PlannerEntry<T> entry
    )?,
  37. void onEntryMove(
    1. PlannerEntry<T> entry
    )?,
  38. void onEntryLongPress(
    1. PlannerEntry<T> entry
    )?,
  39. double dateRowHeight = 50,
  40. double hourColumnWidth = 50,
})

Implementation

PlannerConfig({
  required this.labels,
  this.minHour = 0,
  this.maxHour = 23,
  this.hourLabelFormatter,
  this.blockWidth = 200,
  this.blockHeight = 40,
  this.snapMinutes = 15,
  this.snapMinutesForZoom,
  this.minZoom = 0.5,
  this.maxZoom = 4.0,
  this.hourLabelStyle = const TextStyle(color: Colors.black),
  this.dateLabelStyle = const TextStyle(color: Colors.black),
  this.contextMenuTextStyle = const TextStyle(color: Colors.blue),
  this.contextMenuDeleteTextStyle = const TextStyle(color: Colors.red),
  this.contextMenuCreateLabel = 'Create Event',
  this.contextMenuEditLabel = 'Edit Event',
  this.contextMenuDeleteLabel = 'Delete Event',
  this.spanOverlap = SpanOverlap.fullWidth,
  this.highlightedColumn,
  this.highlightColumnColor = const Color.fromARGB(40, 255, 255, 255),
  this.hourBackground = Colors.white,
  this.dateBackground = Colors.white,
  this.contextMenuBackground = Colors.white,
  this.showZoomControls = true,
  this.zoomButtonColor,
  this.zoomButtonIconColor = Colors.white,
  this.scrollStep = 20,
  this.showAllDayBand = false,
  this.allDayBandLaneHeight = 24,
  this.allDayBandBackground = const Color.fromARGB(255, 60, 60, 60),
  this.plannerBackground = const Color.fromARGB(255, 50, 50, 50),
  this.horizontalLineColor = const Color.fromARGB(255, 100, 100, 100),
  this.verticalLineColor = const Color.fromARGB(255, 150, 150, 150),
  this.onEntryCreate,
  this.onEntryDelete,
  this.onEntryEdit,
  this.onEntryMove,
  this.onEntryLongPress,
  this.dateRowHeight = 50,
  this.hourColumnWidth = 50,
});