PlannerConfig<T> constructor
PlannerConfig<T> ({
- required List<
String> labels, - int minHour = 0,
- int maxHour = 23,
- String hourLabelFormatter(
- int hour
- int blockWidth = 200,
- int blockHeight = 40,
- int snapMinutes = 15,
- int snapMinutesForZoom(
- double zoom
- double minZoom = 0.5,
- double maxZoom = 4.0,
- TextStyle hourLabelStyle = const TextStyle(color: Colors.black),
- TextStyle dateLabelStyle = const TextStyle(color: Colors.black),
- TextStyle contextMenuTextStyle = const TextStyle(color: Colors.blue),
- TextStyle contextMenuDeleteTextStyle = const TextStyle(color: Colors.red),
- String contextMenuCreateLabel = 'Create Event',
- String contextMenuEditLabel = 'Edit Event',
- String contextMenuDeleteLabel = 'Delete Event',
- SpanOverlap spanOverlap = SpanOverlap.fullWidth,
- int? highlightedColumn,
- Color highlightColumnColor = const Color.fromARGB(40, 255, 255, 255),
- Color hourBackground = Colors.white,
- Color dateBackground = Colors.white,
- Color contextMenuBackground = Colors.white,
- bool showZoomControls = true,
- Color? zoomButtonColor,
- Color zoomButtonIconColor = Colors.white,
- double scrollStep = 20,
- bool showAllDayBand = false,
- double allDayBandLaneHeight = 24,
- Color allDayBandBackground = const Color.fromARGB(255, 60, 60, 60),
- Color plannerBackground = const Color.fromARGB(255, 50, 50, 50),
- Color horizontalLineColor = const Color.fromARGB(255, 100, 100, 100),
- Color verticalLineColor = const Color.fromARGB(255, 150, 150, 150),
- dynamic onEntryCreate(
- PlannerTime time
- void onEntryDelete(
- PlannerEntry<
T> entry
- PlannerEntry<
- void onEntryEdit(
- PlannerEntry<
T> entry
- PlannerEntry<
- void onEntryMove(
- PlannerEntry<
T> entry
- PlannerEntry<
- void onEntryLongPress(
- PlannerEntry<
T> entry
- PlannerEntry<
- double dateRowHeight = 50,
- 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,
});