├── .github
└── workflows
│ ├── build.yml
│ ├── codeql.yml
│ └── release.yml
├── .gitignore
├── .mvn
└── wrapper
│ ├── maven-wrapper.jar
│ └── maven-wrapper.properties
├── CHANGELOG.md
├── CHANGES.txt
├── CODE_OF_CONDUCT.md
├── CalendarFXApp
├── .gitignore
├── pom.xml
└── src
│ └── main
│ └── java
│ ├── com
│ └── calendarfx
│ │ └── app
│ │ ├── CalendarApp.java
│ │ ├── CalendarAppLauncher.java
│ │ └── MonthViewApp.java
│ └── module-info.java
├── CalendarFXGoogle
├── .gitignore
├── pom.xml
└── src
│ ├── main
│ ├── java
│ │ ├── com
│ │ │ └── calendarfx
│ │ │ │ └── google
│ │ │ │ ├── GoogleCalendarApp.java
│ │ │ │ ├── converter
│ │ │ │ ├── BeanConverter.java
│ │ │ │ ├── BidirectionalBeanConverter.java
│ │ │ │ ├── CalendarListEntryToGoogleCalendarConverter.java
│ │ │ │ ├── EventToGoogleEntryConverter.java
│ │ │ │ ├── GoogleCalendarToCalendarConverter.java
│ │ │ │ ├── GoogleCalendarToCalendarListEntryConverter.java
│ │ │ │ └── GoogleEntryToEventConverter.java
│ │ │ │ ├── model
│ │ │ │ ├── GoogleAccount.java
│ │ │ │ ├── GoogleCalendar.java
│ │ │ │ ├── GoogleCalendarEvent.java
│ │ │ │ ├── GoogleEntry.java
│ │ │ │ ├── GoogleEntryReminder.java
│ │ │ │ └── IGoogleCalendarSearchTextProvider.java
│ │ │ │ ├── service
│ │ │ │ ├── BeanConverterService.java
│ │ │ │ ├── GoogleCalendarService.java
│ │ │ │ ├── GoogleConnector.java
│ │ │ │ ├── GoogleGeocoderService.java
│ │ │ │ └── SecurityService.java
│ │ │ │ └── view
│ │ │ │ ├── GoogleCalendarAppView.java
│ │ │ │ ├── data
│ │ │ │ ├── GoogleCalendarData.java
│ │ │ │ ├── IGoogleCalendarDataProvider.java
│ │ │ │ └── Slice.java
│ │ │ │ ├── log
│ │ │ │ ├── ActionType.java
│ │ │ │ ├── LogItem.java
│ │ │ │ ├── LogPane.java
│ │ │ │ └── StatusType.java
│ │ │ │ ├── popover
│ │ │ │ ├── GoogleEntryAttendeesView.java
│ │ │ │ ├── GoogleEntryDetailsView.java
│ │ │ │ ├── GoogleEntryGMapsFXView.java
│ │ │ │ └── GoogleEntryPopOverContentPane.java
│ │ │ │ ├── task
│ │ │ │ ├── DeleteEntryTask.java
│ │ │ │ ├── GoogleTask.java
│ │ │ │ ├── InsertCalendarTask.java
│ │ │ │ ├── InsertEntryTask.java
│ │ │ │ ├── LoadAllCalendarsTask.java
│ │ │ │ ├── LoadEntriesBySliceTask.java
│ │ │ │ ├── LoadEntriesByTextTask.java
│ │ │ │ ├── MoveEntryTask.java
│ │ │ │ ├── RefreshCalendarsTask.java
│ │ │ │ └── UpdateEntryTask.java
│ │ │ │ └── thread
│ │ │ │ ├── CalendarViewTimeUpdateThread.java
│ │ │ │ ├── GoogleAutoRefreshThread.java
│ │ │ │ ├── GoogleNotificationPopupThread.java
│ │ │ │ └── GoogleTaskExecutor.java
│ │ ├── impl
│ │ │ └── com
│ │ │ │ └── calendarfx
│ │ │ │ └── google
│ │ │ │ └── view
│ │ │ │ ├── GoogleCalendarAppViewSkin.java
│ │ │ │ ├── GoogleCalendarCreateView.java
│ │ │ │ ├── GoogleCalendarDataManager.java
│ │ │ │ ├── GoogleCalendarSearchTextManager.java
│ │ │ │ ├── GoogleSyncManager.java
│ │ │ │ └── log
│ │ │ │ └── LogPaneSkin.java
│ │ └── module-info.java
│ └── resources
│ │ └── com
│ │ └── calendarfx
│ │ └── google
│ │ ├── service
│ │ ├── StoredCredential
│ │ └── client-secrets.json
│ │ └── view
│ │ └── popover
│ │ └── google-popover.css
│ └── test
│ └── java
│ └── com
│ └── calendarfx
│ └── google
│ └── view
│ └── popover
│ └── HelloGoogleEntryPopOverContentPane.java
├── CalendarFXResourceApp
├── .gitignore
├── pom.xml
└── src
│ └── main
│ └── java
│ ├── com
│ └── calendarfx
│ │ └── resource
│ │ └── app
│ │ ├── ResourceCalendarApp.java
│ │ └── ResourceCalendarAppLauncher.java
│ └── module-info.java
├── CalendarFXSampler
├── .gitignore
├── pom.xml
└── src
│ └── main
│ ├── java
│ ├── com
│ │ └── calendarfx
│ │ │ └── demo
│ │ │ ├── CalendarFXDateControlSample.java
│ │ │ ├── CalendarFXSample.java
│ │ │ ├── CalendarFXSampler.java
│ │ │ ├── CalendarFXSamplerProject.java
│ │ │ ├── CalendarFXSamplerWelcome.java
│ │ │ ├── entries
│ │ │ ├── HelloAllDayEntryView.java
│ │ │ ├── HelloDayEntryView.java
│ │ │ ├── HelloEntryViewBase.java
│ │ │ └── HelloMonthEntryView.java
│ │ │ ├── pages
│ │ │ ├── HelloDayPage.java
│ │ │ ├── HelloMonthPage.java
│ │ │ ├── HelloWeekPage.java
│ │ │ └── HelloYearPage.java
│ │ │ ├── performance
│ │ │ └── HelloPerformance.java
│ │ │ ├── popover
│ │ │ ├── HelloEntryDetailsView.java
│ │ │ ├── HelloEntryHeaderView.java
│ │ │ └── HelloPopOverContentPane.java
│ │ │ ├── print
│ │ │ ├── HelloOptionsView.java
│ │ │ ├── HelloPaperView.java
│ │ │ ├── HelloPreviewPane.java
│ │ │ ├── HelloPrintView.java
│ │ │ ├── HelloSettingsView.java
│ │ │ ├── HelloTimeRangeField.java
│ │ │ └── HelloTimeRangeView.java
│ │ │ └── views
│ │ │ ├── HelloAgendaView.java
│ │ │ ├── HelloAllDayView.java
│ │ │ ├── HelloAvailabilityCalendar.java
│ │ │ ├── HelloCalendar.java
│ │ │ ├── HelloCalendarHeaderView.java
│ │ │ ├── HelloCalendarSelector.java
│ │ │ ├── HelloCalendarView.java
│ │ │ ├── HelloDayView.java
│ │ │ ├── HelloDetailedDayView.java
│ │ │ ├── HelloDetailedWeekView.java
│ │ │ ├── HelloMonthSheetView.java
│ │ │ ├── HelloMonthView.java
│ │ │ ├── HelloRecurrenceView.java
│ │ │ ├── HelloResourcesCalendarView.java
│ │ │ ├── HelloScrollingDayView.java
│ │ │ ├── HelloScrollingTimeScaleView.java
│ │ │ ├── HelloSourceGridView.java
│ │ │ ├── HelloSourceView.java
│ │ │ ├── HelloTimeField.java
│ │ │ ├── HelloTimeScaleView.java
│ │ │ ├── HelloTimezones.java
│ │ │ ├── HelloTopLayer.java
│ │ │ ├── HelloVisualBounds.java
│ │ │ ├── HelloWeekDayHeaderView.java
│ │ │ ├── HelloWeekDayView.java
│ │ │ ├── HelloWeekFieldsView.java
│ │ │ ├── HelloWeekTimeScaleView.java
│ │ │ ├── HelloWeekView.java
│ │ │ ├── HelloYearMonthView.java
│ │ │ ├── HelloYearView.java
│ │ │ └── resources
│ │ │ └── HelloResourcesView.java
│ └── module-info.java
│ └── resources
│ └── META-INF
│ └── services
│ └── fxsampler.FXSamplerProject
├── CalendarFXSchedulerApp
├── .gitignore
├── pom.xml
└── src
│ └── main
│ └── java
│ ├── com
│ └── calendarfx
│ │ └── scheduler
│ │ ├── SchedulerApp.java
│ │ └── SchedulerAppLauncher.java
│ └── module-info.java
├── CalendarFXView
├── .gitignore
├── logging.properties
├── pom.xml
└── src
│ ├── main
│ ├── asciidoc
│ │ ├── manual-images
│ │ │ ├── all-day-view.png
│ │ │ ├── calendar-header-view.png
│ │ │ ├── calendar-view.png
│ │ │ ├── date-picker.png
│ │ │ ├── datecontrol.png
│ │ │ ├── day-page.png
│ │ │ ├── day-view.png
│ │ │ ├── detailed-day-view-agenda.png
│ │ │ ├── detailed-week-view.png
│ │ │ ├── developer-console.png
│ │ │ ├── distribution.png
│ │ │ ├── entry.png
│ │ │ ├── hierarchy.png
│ │ │ ├── month-page.png
│ │ │ ├── month-sheet-view-aligned.png
│ │ │ ├── month-sheet-view.png
│ │ │ ├── month-view.png
│ │ │ ├── resources-view-availability.png
│ │ │ ├── resources-view-dates-over-resources.png
│ │ │ ├── resources-view-resources-over-dates.png
│ │ │ ├── title.png
│ │ │ ├── week-page.png
│ │ │ ├── week-view.png
│ │ │ ├── year-page-2.png
│ │ │ ├── year-page.png
│ │ │ └── year-view.png
│ │ └── manual.adoc
│ ├── java
│ │ ├── com
│ │ │ └── calendarfx
│ │ │ │ ├── model
│ │ │ │ ├── Calendar.java
│ │ │ │ ├── CalendarEvent.java
│ │ │ │ ├── CalendarSource.java
│ │ │ │ ├── Entry.java
│ │ │ │ ├── Interval.java
│ │ │ │ ├── IntervalTree.java
│ │ │ │ ├── LoadEvent.java
│ │ │ │ ├── Marker.java
│ │ │ │ ├── Resource.java
│ │ │ │ └── package-info.java
│ │ │ │ ├── util
│ │ │ │ ├── CalendarFX.java
│ │ │ │ ├── LoggingDomain.java
│ │ │ │ ├── LoggingFormatter.java
│ │ │ │ ├── ViewHelper.java
│ │ │ │ ├── WeakList.java
│ │ │ │ └── package-info.java
│ │ │ │ └── view
│ │ │ │ ├── AgendaView.java
│ │ │ │ ├── AllDayEntryView.java
│ │ │ │ ├── AllDayView.java
│ │ │ │ ├── ButtonBar.java
│ │ │ │ ├── CalendarFXControl.java
│ │ │ │ ├── CalendarHeaderView.java
│ │ │ │ ├── CalendarSelector.java
│ │ │ │ ├── CalendarView.java
│ │ │ │ ├── ContextMenuProvider.java
│ │ │ │ ├── CreateAndDeleteHandler.java
│ │ │ │ ├── DateControl.java
│ │ │ │ ├── DateSelectionModel.java
│ │ │ │ ├── DayEntryView.java
│ │ │ │ ├── DayView.java
│ │ │ │ ├── DayViewBase.java
│ │ │ │ ├── DeleteHandler.java
│ │ │ │ ├── DetailedDayView.java
│ │ │ │ ├── DetailedWeekView.java
│ │ │ │ ├── DeveloperConsole.java
│ │ │ │ ├── DraggedEntry.java
│ │ │ │ ├── EntryViewBase.java
│ │ │ │ ├── Messages.java
│ │ │ │ ├── MonthEntryView.java
│ │ │ │ ├── MonthSheetView.java
│ │ │ │ ├── MonthView.java
│ │ │ │ ├── MonthViewBase.java
│ │ │ │ ├── RecurrenceView.java
│ │ │ │ ├── RequestEvent.java
│ │ │ │ ├── ResourceCalendarView.java
│ │ │ │ ├── ResourcesView.java
│ │ │ │ ├── SearchResultView.java
│ │ │ │ ├── SourceGridView.java
│ │ │ │ ├── SourceView.java
│ │ │ │ ├── TimeField.java
│ │ │ │ ├── TimeScaleView.java
│ │ │ │ ├── VirtualGrid.java
│ │ │ │ ├── WeekDayHeaderView.java
│ │ │ │ ├── WeekDayView.java
│ │ │ │ ├── WeekFieldsView.java
│ │ │ │ ├── WeekTimeScaleView.java
│ │ │ │ ├── WeekView.java
│ │ │ │ ├── YearMonthView.java
│ │ │ │ ├── YearView.java
│ │ │ │ ├── ZonedDateTimeProvider.java
│ │ │ │ ├── package-info.java
│ │ │ │ ├── page
│ │ │ │ ├── DayPage.java
│ │ │ │ ├── MonthPage.java
│ │ │ │ ├── PageBase.java
│ │ │ │ ├── WeekPage.java
│ │ │ │ ├── YearPage.java
│ │ │ │ └── package-info.java
│ │ │ │ ├── popover
│ │ │ │ ├── DatePopOver.java
│ │ │ │ ├── EntriesPane.java
│ │ │ │ ├── EntryDetailsView.java
│ │ │ │ ├── EntryHeaderView.java
│ │ │ │ ├── EntryMapView.java
│ │ │ │ ├── EntryPopOverContentPane.java
│ │ │ │ ├── EntryPopOverPane.java
│ │ │ │ ├── EntryPropertiesView.java
│ │ │ │ ├── PopOverContentPane.java
│ │ │ │ ├── PopOverTitledPane.java
│ │ │ │ ├── RecurrencePopup.java
│ │ │ │ ├── ZoneIdComparator.java
│ │ │ │ └── package-info.java
│ │ │ │ └── print
│ │ │ │ ├── OptionsView.java
│ │ │ │ ├── PaperView.java
│ │ │ │ ├── PreviewPane.java
│ │ │ │ ├── PrintView.java
│ │ │ │ ├── PrintablePage.java
│ │ │ │ ├── SettingsView.java
│ │ │ │ ├── TimeRangeField.java
│ │ │ │ ├── TimeRangeView.java
│ │ │ │ ├── ViewType.java
│ │ │ │ ├── ViewTypeControl.java
│ │ │ │ ├── ZoomPane.java
│ │ │ │ └── package-info.java
│ │ ├── impl
│ │ │ └── com
│ │ │ │ └── calendarfx
│ │ │ │ └── view
│ │ │ │ ├── AgendaViewSkin.java
│ │ │ │ ├── AllDayEntryViewSkin.java
│ │ │ │ ├── AllDayViewSkin.java
│ │ │ │ ├── AutoScrollPane.java
│ │ │ │ ├── ButtonBarSkin.java
│ │ │ │ ├── CalendarHeaderViewSkin.java
│ │ │ │ ├── CalendarPropertySheet.java
│ │ │ │ ├── CalendarSelectorSkin.java
│ │ │ │ ├── CalendarViewSkin.java
│ │ │ │ ├── DataLoader.java
│ │ │ │ ├── DateControlSkin.java
│ │ │ │ ├── DayEntryViewSkin.java
│ │ │ │ ├── DayViewBaseSkin.java
│ │ │ │ ├── DayViewEditController.java
│ │ │ │ ├── DayViewScrollPane.java
│ │ │ │ ├── DayViewSkin.java
│ │ │ │ ├── DetailedDayViewSkin.java
│ │ │ │ ├── DetailedWeekViewSkin.java
│ │ │ │ ├── DeveloperConsoleSkin.java
│ │ │ │ ├── LoadDataSettingsProvider.java
│ │ │ │ ├── MonthEntryViewSkin.java
│ │ │ │ ├── MonthSheetViewSkin.java
│ │ │ │ ├── MonthViewSkin.java
│ │ │ │ ├── NavigateDateView.java
│ │ │ │ ├── NumericTextField.java
│ │ │ │ ├── RecurrenceViewSkin.java
│ │ │ │ ├── ResourceCalendarViewSkin.java
│ │ │ │ ├── ResourcesViewContainer.java
│ │ │ │ ├── ResourcesViewContainerSkin.java
│ │ │ │ ├── ResourcesViewSkin.java
│ │ │ │ ├── SearchResultViewSkin.java
│ │ │ │ ├── SourceGridViewSkin.java
│ │ │ │ ├── SourceViewSkin.java
│ │ │ │ ├── TimeFieldSkin.java
│ │ │ │ ├── TimeScaleViewSkin.java
│ │ │ │ ├── WeekDayHeaderViewSkin.java
│ │ │ │ ├── WeekDayViewSkin.java
│ │ │ │ ├── WeekFieldsViewSkin.java
│ │ │ │ ├── WeekTimeScaleViewSkin.java
│ │ │ │ ├── WeekViewSkin.java
│ │ │ │ ├── YearMonthViewSkin.java
│ │ │ │ ├── YearViewSkin.java
│ │ │ │ ├── ZoneIdStringConverter.java
│ │ │ │ ├── page
│ │ │ │ ├── DayPageSkin.java
│ │ │ │ ├── MonthPageSkin.java
│ │ │ │ ├── PageBaseSkin.java
│ │ │ │ ├── WeekPageSkin.java
│ │ │ │ └── YearPageSkin.java
│ │ │ │ ├── popover
│ │ │ │ └── RecurrencePopupSkin.java
│ │ │ │ ├── print
│ │ │ │ ├── OptionsViewSkin.java
│ │ │ │ ├── PaperViewSkin.java
│ │ │ │ ├── PreviewPaneSkin.java
│ │ │ │ ├── PrintViewSkin.java
│ │ │ │ ├── PrintablePageSkin.java
│ │ │ │ ├── SettingsViewSkin.java
│ │ │ │ ├── TimeRangeFieldSkin.java
│ │ │ │ ├── TimeRangeViewSkin.java
│ │ │ │ └── ZoomPaneSkin.java
│ │ │ │ └── util
│ │ │ │ ├── Placement.java
│ │ │ │ ├── TimeBoundsCluster.java
│ │ │ │ ├── TimeBoundsColumn.java
│ │ │ │ ├── TimeBoundsResolver.java
│ │ │ │ ├── Util.java
│ │ │ │ ├── VisualBoundsCluster.java
│ │ │ │ ├── VisualBoundsColumn.java
│ │ │ │ └── VisualBoundsResolver.java
│ │ └── module-info.java
│ ├── javadoc
│ │ ├── com.calendarfx.model
│ │ │ └── com
│ │ │ │ └── calendarfx
│ │ │ │ └── model
│ │ │ │ └── doc-files
│ │ │ │ ├── calendar-source.png
│ │ │ │ ├── entry.png
│ │ │ │ ├── full-day.png
│ │ │ │ ├── multi-day.png
│ │ │ │ └── styles.png
│ │ └── com.calendarfx.view
│ │ │ └── com
│ │ │ └── calendarfx
│ │ │ └── view
│ │ │ ├── doc-files
│ │ │ ├── agenda-view.png
│ │ │ ├── all-day-view-today.png
│ │ │ ├── all-day-view.png
│ │ │ ├── button-bar.png
│ │ │ ├── calendar-header-view.png
│ │ │ ├── calendar-selector.png
│ │ │ ├── calendar-view.png
│ │ │ ├── current-time-marker.png
│ │ │ ├── current-week.png
│ │ │ ├── date-picker.png
│ │ │ ├── day-entry-view.png
│ │ │ ├── day-view.png
│ │ │ ├── detailed-day-view-agenda.png
│ │ │ ├── detailed-day-view.png
│ │ │ ├── detailed-week-view.png
│ │ │ ├── developer-console.png
│ │ │ ├── month-cell-factory.png
│ │ │ ├── month-sheet-view-aligned.png
│ │ │ ├── month-sheet-view.png
│ │ │ ├── month-view.png
│ │ │ ├── multi-days.png
│ │ │ ├── recurrence-view.png
│ │ │ ├── search-result-view.png
│ │ │ ├── source-view.png
│ │ │ ├── time-field.png
│ │ │ ├── time-scale-view.png
│ │ │ ├── today.png
│ │ │ ├── usage-colors.png
│ │ │ ├── week-numbers.png
│ │ │ ├── week-view.png
│ │ │ ├── week-weekdays.png
│ │ │ ├── weekdays.png
│ │ │ ├── weekend.png
│ │ │ └── year-view.png
│ │ │ ├── page
│ │ │ └── doc-files
│ │ │ │ ├── day-page.png
│ │ │ │ ├── month-page.png
│ │ │ │ ├── week-page.png
│ │ │ │ ├── year-page-2.png
│ │ │ │ └── year-page.png
│ │ │ ├── popover
│ │ │ └── doc-files
│ │ │ │ └── date-popover.png
│ │ │ └── print
│ │ │ └── doc-files
│ │ │ ├── options-view.png
│ │ │ ├── paper-view.png
│ │ │ ├── preview-dialog.png
│ │ │ ├── print-view.png
│ │ │ ├── settings-view.png
│ │ │ ├── time-range-field.png
│ │ │ └── time-range-view.png
│ └── resources
│ │ └── com
│ │ └── calendarfx
│ │ ├── util
│ │ ├── public_key.properties
│ │ └── version.properties
│ │ └── view
│ │ ├── calendar.css
│ │ ├── messages.properties
│ │ ├── messages_de.properties
│ │ ├── messages_es.properties
│ │ ├── messages_fr.properties
│ │ ├── messages_it.properties
│ │ ├── messages_pt_BR.properties
│ │ └── messages_sk.properties
│ └── test
│ └── java
│ └── com
│ └── calendarfx
│ ├── model
│ ├── CalendarTest.java
│ ├── EntryTest.java
│ └── IntervalTest.java
│ └── view
│ └── DateSelectionModelTests.java
├── CalendarFXWeather
├── .gitignore
├── pom.xml
└── src
│ └── main
│ └── java
│ ├── com
│ └── calendarfx
│ │ └── weather
│ │ ├── WeatherApp.java
│ │ └── WeatherAppLauncher.java
│ └── module-info.java
├── CalendarFXiCal
├── .gitignore
├── pom.xml
└── src
│ └── main
│ ├── java
│ ├── com
│ │ └── calendarfx
│ │ │ └── ical
│ │ │ ├── ICalCalendarApp.java
│ │ │ ├── ICalCalendarAppLauncher.java
│ │ │ ├── ICalRepository.java
│ │ │ ├── model
│ │ │ ├── ICalCalendar.java
│ │ │ └── ICalCalendarEntry.java
│ │ │ └── view
│ │ │ ├── ICalWebSourceFactory.java
│ │ │ └── ICalWebSourcePane.java
│ └── module-info.java
│ └── resources
│ └── com
│ └── calendarfx
│ └── ical
│ ├── dialog.css
│ └── ical.png
├── LICENSE
├── README.md
├── docs
├── index.html
└── manual-images
│ ├── all-day-view.png
│ ├── calendar-header-view.png
│ ├── calendar-view.png
│ ├── date-picker.png
│ ├── datecontrol.png
│ ├── day-page.png
│ ├── day-view.png
│ ├── detailed-day-view-agenda.png
│ ├── detailed-week-view.png
│ ├── developer-console.png
│ ├── distribution.png
│ ├── entry.png
│ ├── hierarchy.png
│ ├── month-page.png
│ ├── month-sheet-view-aligned.png
│ ├── month-sheet-view.png
│ ├── month-view.png
│ ├── resources-view-availability.png
│ ├── resources-view-dates-over-resources.png
│ ├── resources-view-resources-over-dates.png
│ ├── title.png
│ ├── week-page.png
│ ├── week-view.png
│ ├── year-page-2.png
│ ├── year-page.png
│ └── year-view.png
├── formatter-settings.xml
├── jreleaser.yml
├── mvnw
├── mvnw.cmd
├── pom.xml
└── screenshot.png
/.github/workflows/build.yml:
--------------------------------------------------------------------------------
1 | name: Build
2 | on:
3 | push:
4 | branches:
5 | - master-11
6 | pull_request:
7 | types: [opened, synchronize, reopened]
8 | jobs:
9 | build:
10 | name: Build
11 | runs-on: ubuntu-latest
12 | if: startsWith(github.event.head_commit.message, '🏁 Releasing version') != true
13 | steps:
14 | - uses: actions/checkout@v2
15 | with:
16 | fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
17 | - name: Set up JDK 17
18 | uses: actions/setup-java@v1
19 | with:
20 | java-version: 17
21 | - name: Cache SonarCloud packages
22 | uses: actions/cache@v1
23 | with:
24 | path: ~/.sonar/cache
25 | key: ${{ runner.os }}-sonar
26 | restore-keys: ${{ runner.os }}-sonar
27 | - name: Cache Maven packages
28 | uses: actions/cache@v1
29 | with:
30 | path: ~/.m2
31 | key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
32 | restore-keys: ${{ runner.os }}-m2
33 | - name: Build and analyze
34 | env:
35 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
36 | SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
37 | run: ./mvnw -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
--------------------------------------------------------------------------------
/.github/workflows/codeql.yml:
--------------------------------------------------------------------------------
1 | name: "CodeQL"
2 |
3 | on:
4 | push:
5 | branches: [ "master-11" ]
6 | pull_request:
7 | branches: [ "master-11" ]
8 | schedule:
9 | - cron: "46 7 * * 1"
10 |
11 | jobs:
12 | analyze:
13 | name: Analyze
14 | runs-on: ubuntu-latest
15 | permissions:
16 | actions: read
17 | contents: read
18 | security-events: write
19 |
20 | strategy:
21 | fail-fast: false
22 | matrix:
23 | language: [ java ]
24 |
25 | steps:
26 | - name: Checkout
27 | uses: actions/checkout@v3
28 |
29 | - name: Initialize CodeQL
30 | uses: github/codeql-action/init@v2
31 | with:
32 | languages: ${{ matrix.language }}
33 | queries: +security-and-quality
34 |
35 | - name: Autobuild
36 | uses: github/codeql-action/autobuild@v2
37 |
38 | - name: Perform CodeQL Analysis
39 | uses: github/codeql-action/analyze@v2
40 | with:
41 | category: "/language:${{ matrix.language }}"
42 |
--------------------------------------------------------------------------------
/.github/workflows/release.yml:
--------------------------------------------------------------------------------
1 | name: Release
2 |
3 | on:
4 | workflow_dispatch:
5 | inputs:
6 | version:
7 | description: "Release version"
8 | required: true
9 |
10 | jobs:
11 | release:
12 | runs-on: ubuntu-latest
13 | steps:
14 | - uses: actions/checkout@v2
15 | with:
16 | fetch-depth: 0
17 |
18 | - name: 'Set up Java'
19 | uses: actions/setup-java@v2
20 | with:
21 | java-version: 14
22 | distribution: 'zulu'
23 | server-id: central
24 | server-username: MAVEN_USERNAME
25 | server-password: MAVEN_CENTRAL_TOKEN
26 | gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
27 | gpg-passphrase: MAVEN_GPG_PASSPHRASE
28 |
29 | - name: 'Cache Maven packages'
30 | uses: actions/cache@v2
31 | with:
32 | path: ~/.m2
33 | key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
34 | restore-keys: ${{ runner.os }}-m2
35 |
36 | - name: Update version
37 | id: version
38 | run: |
39 | VERSION=${{ github.event.inputs.version }}
40 | echo "Updating POMs to version $VERSION"
41 | ./mvnw -B versions:set versions:commit -DnewVersion=$VERSION
42 | git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
43 | git config --global user.name "GitHub Action"
44 | git commit -a -m "🏁 Releasing version $VERSION"
45 | git push origin HEAD:master-11
46 |
47 | - name: Release to Maven Central
48 | env:
49 | MAVEN_USERNAME: ${{ secrets.SONATYPE_WITH_TOKEN_USERNAME }}
50 | MAVEN_CENTRAL_TOKEN: ${{ secrets.SONATYPE_WITH_TOKEN_PASSWORD }}
51 | MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
52 | run: |
53 | export GPG_TTY=$(tty)
54 | ./mvnw --no-transfer-progress -B --file pom.xml \
55 | -Drepository.url=https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git \
56 | -Dmaven.site.skip=true -Drelease=true deploy
57 |
58 | - name: Release to GitHub
59 | env:
60 | JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
61 | run: ./mvnw -B --file pom.xml -Prelease -pl :calendar jreleaser:full-release
62 |
63 | - name: JReleaser output
64 | if: always()
65 | uses: actions/upload-artifact@v3
66 | with:
67 | name: jreleaser-logs
68 | path: |
69 | target/jreleaser/trace.log
70 | target/jreleaser/output.properties
71 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /target/
2 | .idea
3 | *.iml
4 | .project
5 | *.prefs
6 | CalendarFXApp/.classpath
7 | *.classpath
8 | *.log
9 |
--------------------------------------------------------------------------------
/.mvn/wrapper/maven-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/.mvn/wrapper/maven-wrapper.jar
--------------------------------------------------------------------------------
/.mvn/wrapper/maven-wrapper.properties:
--------------------------------------------------------------------------------
1 | # Licensed to the Apache Software Foundation (ASF) under one
2 | # or more contributor license agreements. See the NOTICE file
3 | # distributed with this work for additional information
4 | # regarding copyright ownership. The ASF licenses this file
5 | # to you under the Apache License, Version 2.0 (the
6 | # "License"); you may not use this file except in compliance
7 | # with the License. You may obtain a copy of the License at
8 | #
9 | # http://www.apache.org/licenses/LICENSE-2.0
10 | #
11 | # Unless required by applicable law or agreed to in writing,
12 | # software distributed under the License is distributed on an
13 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 | # KIND, either express or implied. See the License for the
15 | # specific language governing permissions and limitations
16 | # under the License.
17 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.8.4/apache-maven-3.8.4-bin.zip
18 | wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.1.0/maven-wrapper-3.1.0.jar
19 |
--------------------------------------------------------------------------------
/CalendarFXApp/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | *.iml
3 |
--------------------------------------------------------------------------------
/CalendarFXApp/pom.xml:
--------------------------------------------------------------------------------
1 |
16 |
17 |
19 | 4.0.0
20 | application
21 | CalendarFXApp
22 |
23 |
24 | com.calendarfx
25 | calendar
26 | 11.12.7
27 | ../pom.xml
28 |
29 |
30 |
31 | true
32 |
33 |
34 |
35 |
36 | com.calendarfx
37 | view
38 |
39 |
40 | fr.brouillard.oss
41 | cssfx
42 |
43 |
44 |
45 |
46 |
47 |
48 | org.openjfx
49 | javafx-maven-plugin
50 | ${javafx.maven.plugin.version}
51 |
52 | com.calendarfx.app.CalendarApp
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/CalendarFXApp/src/main/java/com/calendarfx/app/CalendarAppLauncher.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.app;
18 |
19 | public class CalendarAppLauncher {
20 |
21 | public static void main(String[] args) {
22 | System.setProperty("calendarfx.developer", "true");
23 | CalendarApp.main(args);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/CalendarFXApp/src/main/java/com/calendarfx/app/MonthViewApp.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.app;
18 |
19 | import com.calendarfx.view.MonthView;
20 | import javafx.application.Application;
21 | import javafx.scene.Scene;
22 | import javafx.scene.layout.StackPane;
23 | import javafx.stage.Stage;
24 |
25 | public class MonthViewApp extends Application {
26 |
27 | @Override
28 | public void start(Stage primaryStage) {
29 | MonthView monthView = new MonthView();
30 |
31 | StackPane stackPane = new StackPane();
32 | stackPane.getChildren().addAll(monthView); // introPane);
33 |
34 | Scene scene = new Scene(stackPane);
35 | primaryStage.setTitle("Month View");
36 | primaryStage.setScene(scene);
37 | primaryStage.sizeToScene();
38 | primaryStage.centerOnScreen();
39 | primaryStage.show();
40 | }
41 |
42 | public static void main(String[] args) {
43 | launch(args);
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/CalendarFXApp/src/main/java/module-info.java:
--------------------------------------------------------------------------------
1 | module com.calendarfx.app {
2 | requires transitive javafx.graphics;
3 | requires fr.brouillard.oss.cssfx;
4 | requires javafx.controls;
5 | requires com.calendarfx.view;
6 |
7 | exports com.calendarfx.app;
8 | }
--------------------------------------------------------------------------------
/CalendarFXGoogle/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | *.iml
3 | /bin/
4 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/GoogleCalendarApp.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google;
18 |
19 | import com.calendarfx.google.view.GoogleCalendarAppView;
20 | import com.calendarfx.view.CalendarView;
21 | import javafx.application.Application;
22 | import javafx.scene.Scene;
23 | import javafx.stage.Stage;
24 |
25 | import java.time.LocalDate;
26 | import java.time.LocalTime;
27 |
28 | public class GoogleCalendarApp extends Application {
29 |
30 | @Override
31 | public void start(Stage primaryStage) {
32 | CalendarView calendarView = new CalendarView();
33 | calendarView.setToday(LocalDate.now());
34 | calendarView.setTime(LocalTime.now());
35 | calendarView.setShowDeveloperConsole(Boolean.getBoolean("calendarfx.developer"));
36 |
37 | GoogleCalendarAppView appView = new GoogleCalendarAppView(calendarView);
38 | appView.getStylesheets().add(CalendarView.class.getResource("calendar.css").toExternalForm());
39 |
40 | primaryStage.setTitle("Google Calendar");
41 | primaryStage.setScene(new Scene(appView));
42 | primaryStage.setWidth(1400);
43 | primaryStage.setHeight(950);
44 | primaryStage.centerOnScreen();
45 | primaryStage.show();
46 | }
47 |
48 | public static void main(String[] args) {
49 | launch(args);
50 | }
51 |
52 | }
53 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/converter/BeanConverter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.converter;
18 |
19 | /**
20 | * Interface representing a converter from/to a single bean.
21 | *
22 | * Created by gdiaz on 20/02/2017.
23 | */
24 | public interface BeanConverter {
25 |
26 | /**
27 | * Converts the given source into an object of type defined by the target.
28 | *
29 | * @param source The object source to be converted.
30 | * @return The target result of the convertion.
31 | */
32 | T convert(S source);
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/converter/BidirectionalBeanConverter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.converter;
18 |
19 | /**
20 | * Converter in both directions.
21 | *
22 | * Created by gdiaz on 28/04/2017.
23 | */
24 | public interface BidirectionalBeanConverter extends BeanConverter {
25 |
26 | R leftToRight(L left);
27 |
28 | L rightToLeft(R right);
29 |
30 | @Override
31 | default R convert(L source) {
32 | return leftToRight(source);
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/converter/CalendarListEntryToGoogleCalendarConverter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.converter;
18 |
19 | import com.calendarfx.google.model.GoogleCalendar;
20 | import com.calendarfx.google.model.GoogleEntryReminder;
21 | import com.google.api.services.calendar.model.CalendarListEntry;
22 | import com.google.api.services.calendar.model.EventReminder;
23 |
24 | import java.util.ArrayList;
25 | import java.util.List;
26 |
27 | /**
28 | * Converts from google api to calendarfx api.
29 | *
30 | * Created by gdiaz on 20/02/2017.
31 | */
32 | public final class CalendarListEntryToGoogleCalendarConverter implements BeanConverter {
33 | @Override
34 | public GoogleCalendar convert(CalendarListEntry source) {
35 | GoogleCalendar calendar = new GoogleCalendar();
36 | calendar.setId(source.getId());
37 | calendar.setName(source.getSummary());
38 | calendar.setShortName(source.getSummary());
39 | calendar.setPrimary(source.isPrimary());
40 | calendar.setReadOnly(GoogleCalendar.isReadOnlyAccessRole(source.getAccessRole()));
41 | List reminders = new ArrayList<>();
42 | if (source.getDefaultReminders() != null) {
43 | for (EventReminder r : source.getDefaultReminders()) {
44 | reminders.add(new GoogleEntryReminder(r));
45 | }
46 | }
47 | calendar.getDefaultReminders().setAll(reminders);
48 | return calendar;
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/converter/GoogleCalendarToCalendarConverter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.converter;
18 |
19 | import com.calendarfx.google.model.GoogleCalendar;
20 | import com.google.api.services.calendar.model.Calendar;
21 |
22 | import java.time.ZoneId;
23 |
24 | /**
25 | * BeanConverter between calendarfx and google api.
26 | *
27 | * Created by gdiaz on 26/03/2017.
28 | */
29 | public class GoogleCalendarToCalendarConverter implements BeanConverter {
30 | @Override
31 | public Calendar convert(GoogleCalendar source) {
32 | Calendar target = new Calendar();
33 | target.setSummary(source.getName());
34 | target.setTimeZone(ZoneId.systemDefault().getId());
35 | return target;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/converter/GoogleCalendarToCalendarListEntryConverter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.converter;
18 |
19 | import com.calendarfx.google.model.GoogleCalendar;
20 | import com.calendarfx.google.model.GoogleEntryReminder;
21 | import com.google.api.services.calendar.model.CalendarListEntry;
22 | import com.google.api.services.calendar.model.EventReminder;
23 |
24 | import java.util.ArrayList;
25 | import java.util.List;
26 |
27 | /**
28 | * Converts from calendar (calendarfx api) to calendar list entry (google api).
29 | *
30 | * Created by gdiaz on 20/02/2017.
31 | */
32 | public final class GoogleCalendarToCalendarListEntryConverter implements BeanConverter {
33 | @Override
34 | public CalendarListEntry convert(GoogleCalendar source) {
35 | CalendarListEntry calendarListEntry = new CalendarListEntry();
36 | calendarListEntry.setId(source.getId());
37 | calendarListEntry.setSummary(source.getName());
38 | calendarListEntry.setPrimary(source.isPrimary());
39 | List reminders = new ArrayList<>();
40 | for (GoogleEntryReminder reminder : source.getDefaultReminders()) {
41 | EventReminder er = new EventReminder();
42 | er.setMethod(reminder.getMethod().getId());
43 | er.setMinutes(reminder.getMinutes());
44 | reminders.add(er);
45 | }
46 | calendarListEntry.setDefaultReminders(reminders);
47 | return calendarListEntry;
48 | }
49 | }
50 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/model/IGoogleCalendarSearchTextProvider.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.model;
18 |
19 | /**
20 | * Objects that provides external searching of entries by a given text on a single calendar.
21 | *
22 | * Created by gdiaz on 5/05/2017.
23 | */
24 | public interface IGoogleCalendarSearchTextProvider {
25 |
26 | void search(GoogleCalendar calendar, String searchText);
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/GoogleCalendarAppView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view;
18 |
19 | import com.calendarfx.google.view.log.LogPane;
20 | import com.calendarfx.view.CalendarFXControl;
21 | import com.calendarfx.view.CalendarView;
22 | import com.calendarfx.view.DateControl;
23 | import impl.com.calendarfx.google.view.GoogleCalendarAppViewSkin;
24 | import javafx.scene.control.Skin;
25 |
26 | import java.util.Objects;
27 |
28 | /**
29 | * Control which allows to log in by using a Google account in order to get
30 | * access to the user calendar data. Displays the Google Login web page and then
31 | * lets the user authorize us to read/write his calendar information. After
32 | * authorization this displays a {@link DateControl} configured externally.
33 | *
34 | * @author Gabriel Diaz, 14.02.2015.
35 | */
36 | public class GoogleCalendarAppView extends CalendarFXControl {
37 |
38 | private final CalendarView calendarView;
39 |
40 | private final LogPane logPane;
41 |
42 | public GoogleCalendarAppView(CalendarView calendarView) {
43 | super();
44 | this.calendarView = Objects.requireNonNull(calendarView);
45 | this.logPane = new LogPane();
46 | }
47 |
48 | @Override
49 | protected Skin> createDefaultSkin() {
50 | return new GoogleCalendarAppViewSkin(this);
51 | }
52 |
53 | public CalendarView getCalendarView() {
54 | return calendarView;
55 | }
56 |
57 | public LogPane getLogPane() {
58 | return logPane;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/data/IGoogleCalendarDataProvider.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.data;
18 |
19 | import com.calendarfx.google.model.GoogleCalendar;
20 |
21 | /**
22 | * Provider of the google calendar data.
23 | *
24 | * Created by gdiaz on 5/05/2017.
25 | */
26 | public interface IGoogleCalendarDataProvider {
27 |
28 | default GoogleCalendarData getCalendarData(GoogleCalendar calendar) {
29 | return getCalendarData(calendar, false);
30 | }
31 |
32 | GoogleCalendarData getCalendarData(GoogleCalendar calendar, boolean create);
33 |
34 | void removeCalendarData(GoogleCalendar calendar);
35 |
36 | void clearData();
37 | }
38 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/log/ActionType.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.log;
18 |
19 | /**
20 | * Action performed by the user.
21 | *
22 | * Created by gdiaz on 28/02/2017.
23 | */
24 | public enum ActionType {
25 |
26 | LOAD {
27 | @Override
28 | public String getDisplayName() {
29 | return "Load";
30 | }
31 | },
32 |
33 | INSERT {
34 | @Override
35 | public String getDisplayName() {
36 | return "Insert";
37 | }
38 | },
39 |
40 | UPDATE {
41 | @Override
42 | public String getDisplayName() {
43 | return "Update";
44 | }
45 | },
46 |
47 | DELETE {
48 | @Override
49 | public String getDisplayName() {
50 | return "Delete";
51 | }
52 | },
53 |
54 | MOVE {
55 | @Override
56 | public String getDisplayName() {
57 | return "Move";
58 | }
59 | },
60 |
61 | REFRESH {
62 | @Override
63 | public String getDisplayName() {
64 | return "Refresh";
65 | }
66 | };
67 |
68 | public abstract String getDisplayName();
69 | }
70 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/DeleteEntryTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.model.GoogleAccount;
20 | import com.calendarfx.google.model.GoogleCalendar;
21 | import com.calendarfx.google.model.GoogleEntry;
22 | import com.calendarfx.google.service.GoogleConnector;
23 | import com.calendarfx.google.view.log.ActionType;
24 |
25 | /**
26 | * Task that deletes one entry from google.
27 | *
28 | * Created by gdiaz on 12/03/2017.
29 | */
30 | public final class DeleteEntryTask extends GoogleTask {
31 |
32 | private final GoogleEntry entry;
33 | private final GoogleCalendar calendar;
34 | private final GoogleAccount account;
35 |
36 | public DeleteEntryTask(GoogleEntry entry, GoogleCalendar calendar, GoogleAccount account) {
37 | this.entry = entry;
38 | this.calendar = calendar;
39 | this.account = account;
40 | this.logItem.setCalendar(calendar.getName());
41 | this.logItem.setDescription(getDescription());
42 | }
43 |
44 | @Override
45 | public ActionType getAction() {
46 | return ActionType.DELETE;
47 | }
48 |
49 | @Override
50 | public String getDescription() {
51 | return "Delete " + entry;
52 | }
53 |
54 | @Override
55 | protected Boolean call() throws Exception {
56 | GoogleConnector.getInstance().getCalendarService(account.getId()).deleteEntry(entry, calendar);
57 | return true;
58 | }
59 |
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/GoogleTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.view.log.ActionType;
20 | import com.calendarfx.google.view.log.LogItem;
21 | import com.calendarfx.google.view.log.StatusType;
22 | import javafx.concurrent.Task;
23 |
24 | import java.time.LocalDateTime;
25 |
26 | /**
27 | * Base class for tasks executed for google calendar interaction.
28 | *
29 | * Created by gdiaz on 28/02/2017.
30 | */
31 | public abstract class GoogleTask extends Task {
32 |
33 | final LogItem logItem;
34 |
35 | protected GoogleTask() {
36 | super();
37 | logItem = new LogItem();
38 | logItem.setTime(LocalDateTime.now());
39 | logItem.setStatus(StatusType.PENDING);
40 | logItem.setDescription(getDescription());
41 | logItem.setAction(getAction());
42 | }
43 |
44 | public LogItem getLogItem() {
45 | return logItem;
46 | }
47 |
48 | public abstract ActionType getAction();
49 |
50 | public abstract String getDescription();
51 |
52 | @Override
53 | protected void failed() {
54 | logItem.setStatus(StatusType.FAILED);
55 | logItem.setException(getException());
56 | }
57 |
58 | @Override
59 | protected void cancelled() {
60 | logItem.setStatus(StatusType.CANCELLED);
61 | }
62 |
63 | @Override
64 | protected void succeeded() {
65 | logItem.setStatus(StatusType.SUCCEEDED);
66 | }
67 | }
68 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/InsertCalendarTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.model.GoogleAccount;
20 | import com.calendarfx.google.model.GoogleCalendar;
21 | import com.calendarfx.google.service.GoogleConnector;
22 | import com.calendarfx.google.view.log.ActionType;
23 |
24 | /**
25 | * Task that performs an insert operation into google.
26 | *
27 | * Created by gdiaz on 06.03.2017.
28 | */
29 | public final class InsertCalendarTask extends GoogleTask {
30 |
31 | private final GoogleCalendar calendar;
32 | private final GoogleAccount account;
33 |
34 | public InsertCalendarTask(GoogleCalendar calendar, GoogleAccount account) {
35 | this.calendar = calendar;
36 | this.account = account;
37 | this.logItem.setDescription(getDescription());
38 | }
39 |
40 | @Override
41 | public ActionType getAction() {
42 | return ActionType.INSERT;
43 | }
44 |
45 | @Override
46 | public String getDescription() {
47 | return "Insert " + calendar;
48 | }
49 |
50 | @Override
51 | protected GoogleCalendar call() throws Exception {
52 | GoogleConnector.getInstance().getCalendarService(account.getId()).insertCalendar(calendar);
53 | return calendar;
54 | }
55 |
56 | @Override
57 | protected void succeeded() {
58 | super.succeeded();
59 | account.getCalendars().add(calendar);
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/InsertEntryTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.model.GoogleAccount;
20 | import com.calendarfx.google.model.GoogleCalendar;
21 | import com.calendarfx.google.model.GoogleEntry;
22 | import com.calendarfx.google.service.GoogleConnector;
23 | import com.calendarfx.google.view.log.ActionType;
24 |
25 | /**
26 | * Task that inserts an entry into google.
27 | *
28 | * Created by gdiaz on 12/03/2017.
29 | */
30 | public final class InsertEntryTask extends GoogleTask {
31 |
32 | private final GoogleEntry entry;
33 | private final GoogleCalendar calendar;
34 | private final GoogleAccount account;
35 |
36 | public InsertEntryTask(GoogleEntry entry, GoogleCalendar calendar, GoogleAccount account) {
37 | this.entry = entry;
38 | this.calendar = calendar;
39 | this.account = account;
40 | this.logItem.setCalendar(calendar.getName());
41 | this.logItem.setDescription(getDescription());
42 | }
43 |
44 | @Override
45 | public ActionType getAction() {
46 | return ActionType.INSERT;
47 | }
48 |
49 | @Override
50 | public String getDescription() {
51 | return "Insert " + entry;
52 | }
53 |
54 | @Override
55 | protected GoogleEntry call() throws Exception {
56 | return GoogleConnector.getInstance().getCalendarService(account.getId()).insertEntry(entry, calendar);
57 | }
58 |
59 | @Override
60 | protected void succeeded() {
61 | super.succeeded();
62 | calendar.addEntries(entry);
63 | }
64 | }
65 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/LoadAllCalendarsTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.model.GoogleAccount;
20 | import com.calendarfx.google.model.GoogleCalendar;
21 | import com.calendarfx.google.service.GoogleConnector;
22 | import com.calendarfx.google.view.log.ActionType;
23 |
24 | import java.util.List;
25 |
26 | /**
27 | * Task that queries all calendars from google and updates the google calendar source.
28 | *
29 | * Created by gdiaz on 28/02/2017.
30 | */
31 | public final class LoadAllCalendarsTask extends GoogleTask> {
32 |
33 | private final GoogleAccount account;
34 |
35 | public LoadAllCalendarsTask(GoogleAccount account) {
36 | super();
37 | this.account = account;
38 | }
39 |
40 | @Override
41 | public ActionType getAction() {
42 | return ActionType.LOAD;
43 | }
44 |
45 | @Override
46 | public String getDescription() {
47 | return "Loading all calendars";
48 | }
49 |
50 | @Override
51 | protected List call() throws Exception {
52 | return GoogleConnector.getInstance().getCalendarService(account.getId()).getCalendars();
53 | }
54 |
55 | @Override
56 | protected void succeeded() {
57 | super.succeeded();
58 | account.getCalendars().setAll(getValue());
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/task/MoveEntryTask.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.task;
18 |
19 | import com.calendarfx.google.model.GoogleAccount;
20 | import com.calendarfx.google.model.GoogleCalendar;
21 | import com.calendarfx.google.model.GoogleEntry;
22 | import com.calendarfx.google.service.GoogleConnector;
23 | import com.calendarfx.google.view.log.ActionType;
24 |
25 | /**
26 | * Moves an entry from one calendar to another.
27 | *
28 | * Created by gdiaz on 19/03/2017.
29 | */
30 | public final class MoveEntryTask extends GoogleTask {
31 |
32 | private final GoogleEntry entry;
33 | private final GoogleCalendar from;
34 | private final GoogleCalendar to;
35 | private final GoogleAccount account;
36 |
37 | public MoveEntryTask(GoogleEntry entry, GoogleCalendar from, GoogleCalendar to, GoogleAccount account) {
38 | this.entry = entry;
39 | this.from = from;
40 | this.to = to;
41 | this.account = account;
42 | this.logItem.setCalendar(from.getName());
43 | this.logItem.setDescription(getDescription());
44 | }
45 |
46 | @Override
47 | public ActionType getAction() {
48 | return ActionType.MOVE;
49 | }
50 |
51 | @Override
52 | public String getDescription() {
53 | return "Moving " + entry + " to " + to;
54 | }
55 |
56 | @Override
57 | protected GoogleEntry call() throws Exception {
58 | return GoogleConnector.getInstance().getCalendarService(account.getId()).moveEntry(entry, from, to);
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/com/calendarfx/google/view/thread/CalendarViewTimeUpdateThread.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.thread;
18 |
19 | import com.calendarfx.view.CalendarView;
20 | import javafx.application.Platform;
21 |
22 | import java.time.LocalDate;
23 | import java.time.LocalTime;
24 |
25 | /**
26 | * Thread that updates the current tine on the calendar view
27 | *
28 | * Created by gdiaz on 4/05/2017.
29 | */
30 | public class CalendarViewTimeUpdateThread extends Thread {
31 |
32 | private static final int TEN_SECONDS = 10000;
33 |
34 | private final CalendarView calendarView;
35 |
36 | public CalendarViewTimeUpdateThread(CalendarView calendarView) {
37 | super("Google-Calendar-Update Current Time");
38 | this.calendarView = calendarView;
39 | setPriority(MIN_PRIORITY);
40 | setDaemon(true);
41 | }
42 |
43 | @Override
44 | @SuppressWarnings("InfiniteLoopStatement")
45 | public void run() {
46 | while (true) {
47 | Platform.runLater(() -> {
48 | calendarView.setToday(LocalDate.now());
49 | calendarView.setTime(LocalTime.now());
50 | });
51 |
52 | try {
53 | sleep(TEN_SECONDS);
54 | } catch (InterruptedException e) {
55 | // Do nothing
56 | }
57 | }
58 | }
59 |
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/java/module-info.java:
--------------------------------------------------------------------------------
1 | module com.calendarfx.google {
2 | requires transitive javafx.graphics;
3 |
4 | requires org.kordamp.ikonli.javafx;
5 | requires org.kordamp.ikonli.fontawesome;
6 | requires org.kordamp.ikonli.core;
7 |
8 | requires com.calendarfx.view;
9 | requires javafx.base;
10 | requires com.google.api.services.calendar;
11 | requires org.controlsfx.controls;
12 | requires javafx.controls;
13 | requires javafx.web;
14 | requires geocoder.java;
15 | requires com.dlsc.gmapsfx;
16 | requires com.google.common;
17 | requires com.google.api.client;
18 | requires com.google.api.client.auth;
19 | requires com.google.api.services.oauth2;
20 | requires com.google.api.client.json.jackson2;
21 | requires google.api.client;
22 |
23 | exports com.calendarfx.google;
24 | }
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/resources/com/calendarfx/google/service/StoredCredential:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXGoogle/src/main/resources/com/calendarfx/google/service/StoredCredential
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/resources/com/calendarfx/google/service/client-secrets.json:
--------------------------------------------------------------------------------
1 | {
2 | "installed": {
3 | "auth_uri": "https://accounts.google.com/o/oauth2/auth",
4 | "client_secret": "Tnwk7IGPlvnnn7TQ-WbvpWv3",
5 | "token_uri": "https://accounts.google.com/o/oauth2/token",
6 | "client_email": "",
7 | "redirect_uris": [
8 | "urn:ietf:wg:oauth:2.0:oob",
9 | "oob"
10 | ],
11 | "client_x509_cert_url": "",
12 | "client_id": "972996368401-vlm70ls1ivnpvlfu80odn880bhne1pnc.apps.googleusercontent.com",
13 | "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs"
14 | }
15 | }
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/main/resources/com/calendarfx/google/view/popover/google-popover.css:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 |
18 | .title {
19 | -fx-font-weight: bold;
20 | }
21 |
22 | .button-icon {
23 | -fx-cursor: hand;
24 | }
25 |
26 | .link {
27 | -fx-cursor: hand;
28 | -fx-underline: true;
29 | }
30 |
31 | .details-view .notification-item {
32 | -fx-spacing: 5;
33 | -fx-padding: 0 0 5 0;
34 | }
35 |
36 | .attendees-view .top {
37 | -fx-spacing: 5;
38 | -fx-padding: 0 0 5 0;
39 | }
40 |
41 | .attendees-view .center {
42 | -fx-spacing: 5;
43 | -fx-padding: 0 0 10 0;
44 | -fx-fill-width: true;
45 | -fx-fit-to-width: true;
46 | }
47 |
48 | .attendees-view .scroll-pane {
49 | -fx-padding: 5;
50 | -fx-background-color: transparent;
51 | -fx-border-color: transparent;
52 | -fx-fit-to-width: true;
53 | }
54 |
55 | .attendees-view .bottom {
56 | -fx-spacing: 5;
57 | -fx-padding: 5;
58 | }
59 |
60 | .attendees-view .bottom .checks-parent {
61 | -fx-spacing: 10;
62 | }
63 |
64 | .attendees-view .email-field {
65 | -fx-text-fill: black;
66 | }
67 |
68 | .attendees-view .email-field:invalid {
69 | -fx-text-fill: red;
70 | }
71 |
72 | .attendee-item {
73 | -fx-spacing: 5;
74 | -fx-padding: 5;
75 | -fx-background-color: #EEE;
76 | }
77 |
78 | .popover-footer {
79 | -fx-padding: 0.0 !important;
80 | }
81 |
82 | .map-placeholder {
83 | -fx-padding: 10.0;
84 | }
85 |
86 | .map-view-wrapper {
87 | -fx-padding: 0 20 20 20;
88 | }
89 |
90 | .map {
91 | -fx-border-color: gray;
92 | }
93 |
--------------------------------------------------------------------------------
/CalendarFXGoogle/src/test/java/com/calendarfx/google/view/popover/HelloGoogleEntryPopOverContentPane.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.google.view.popover;
18 |
19 | import com.calendarfx.google.model.GoogleEntry;
20 | import com.calendarfx.model.Calendar;
21 | import com.calendarfx.view.CalendarView;
22 | import com.calendarfx.view.DayView;
23 | import javafx.application.Application;
24 | import javafx.collections.FXCollections;
25 | import javafx.collections.ObservableList;
26 | import javafx.scene.Scene;
27 | import javafx.stage.Stage;
28 |
29 | /**
30 | * Sample for the google entry pop over.
31 | *
32 | * Created by gdiaz on 13/01/2017.
33 | */
34 | public class HelloGoogleEntryPopOverContentPane extends Application {
35 |
36 | @Override
37 | public void start(Stage primaryStage) throws Exception {
38 | Calendar calendar = new Calendar();
39 | calendar.setName("Google Calendar");
40 | calendar.setStyle(Calendar.Style.STYLE2);
41 |
42 | GoogleEntry entry = new GoogleEntry();
43 | entry.setTitle("Google Entry");
44 | entry.setCalendar(calendar);
45 | entry.setLocation("Bogota");
46 |
47 | ObservableList allCalendars = FXCollections.observableArrayList(calendar);
48 |
49 | DayView dayView = new DayView();
50 | GoogleEntryPopOverContentPane pane = new GoogleEntryPopOverContentPane(entry, allCalendars, dayView);
51 |
52 | primaryStage.setTitle("Google Calendar");
53 | Scene scene = new Scene(pane, 400, 600);
54 | scene.getStylesheets().add(CalendarView.class.getResource("calendar.css").toExternalForm());
55 | primaryStage.setScene(scene);
56 | primaryStage.sizeToScene();
57 | primaryStage.centerOnScreen();
58 | primaryStage.show();
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXResourceApp/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | *.iml
3 |
--------------------------------------------------------------------------------
/CalendarFXResourceApp/pom.xml:
--------------------------------------------------------------------------------
1 |
16 |
17 |
19 | 4.0.0
20 | resources
21 | CalendarFXResourceApp
22 |
23 |
24 | com.calendarfx
25 | calendar
26 | 11.12.7
27 | ../pom.xml
28 |
29 |
30 |
31 | true
32 |
33 |
34 |
35 |
36 |
37 | com.calendarfx
38 | view
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 | org.openjfx
47 | javafx-maven-plugin
48 | ${javafx.maven.plugin.version}
49 |
50 | com.calendarfx.resource.app.ResourceCalendarApp
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/CalendarFXResourceApp/src/main/java/com/calendarfx/resource/app/ResourceCalendarAppLauncher.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.resource.app;
18 |
19 | public class ResourceCalendarAppLauncher {
20 |
21 | public static void main(String[] args) {
22 | System.setProperty("calendarfx.developer", "true");
23 | ResourceCalendarApp.main(args);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/CalendarFXResourceApp/src/main/java/module-info.java:
--------------------------------------------------------------------------------
1 | module com.calendarfx.resource.app {
2 | requires transitive javafx.graphics;
3 |
4 | requires javafx.controls;
5 | requires com.calendarfx.view;
6 |
7 | exports com.calendarfx.resource.app;
8 | }
--------------------------------------------------------------------------------
/CalendarFXSampler/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | *.iml
3 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/CalendarFXSampler.java:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (C) 2014 - 2021 DLSC Software & Consulting GmbH (dlsc.com)
3 | *
4 | * This file is part of FlexGanttFX.
5 | */
6 | package com.calendarfx.demo;
7 |
8 | import fxsampler.FXSampler;
9 |
10 | public class CalendarFXSampler {
11 |
12 | public static void main(String[] args) {
13 | FXSampler.main(args);
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/CalendarFXSamplerProject.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo;
19 |
20 | import fxsampler.FXSamplerProject;
21 | import fxsampler.model.WelcomePage;
22 |
23 | public class CalendarFXSamplerProject implements FXSamplerProject {
24 |
25 | @Override
26 | public String getProjectName() {
27 | return "CalendarFX";
28 | }
29 |
30 | @Override
31 | public String getSampleBasePackage() {
32 | return "com.calendarfx.demo";
33 | }
34 |
35 | @Override
36 | public WelcomePage getWelcomePage() {
37 | return new CalendarFXSamplerWelcome();
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/CalendarFXSamplerWelcome.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo;
19 |
20 | import fxsampler.model.WelcomePage;
21 | import javafx.geometry.Insets;
22 | import javafx.geometry.Pos;
23 | import javafx.scene.control.Label;
24 | import javafx.scene.text.TextAlignment;
25 |
26 | public class CalendarFXSamplerWelcome extends WelcomePage {
27 |
28 | public CalendarFXSamplerWelcome() {
29 | super("CalendarFX", new Label(""));
30 |
31 | Label label = (Label) getContent();
32 | label.setWrapText(true);
33 | label.setMaxWidth(Double.MAX_VALUE);
34 | label.setMaxHeight(Double.MAX_VALUE);
35 | label.setTextAlignment(TextAlignment.CENTER);
36 | label.setAlignment(Pos.CENTER);
37 | label.setPadding(new Insets(50));
38 | label.setText("Welcome to the CalendarFX sampler. This application allows you to quickly browse through the "
39 | + "various controls that are available in this framework. In each sample you can play around with the "
40 | + "properties and controls shown on the right-hand side.");
41 | }
42 |
43 | }
44 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/entries/HelloAllDayEntryView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.entries;
19 |
20 | import com.calendarfx.model.Entry;
21 | import com.calendarfx.view.AllDayEntryView;
22 | import com.calendarfx.view.EntryViewBase;
23 |
24 | public class HelloAllDayEntryView extends HelloEntryViewBase {
25 |
26 | @Override
27 | public String getSampleName() {
28 | return "All Day Entry View";
29 | }
30 |
31 | @Override
32 | protected EntryViewBase> createEntryView(Entry> entry) {
33 | AllDayEntryView view = new AllDayEntryView(entry);
34 | view.setPrefSize(400, 20);
35 | return view;
36 | }
37 |
38 | @Override
39 | public String getSampleDescription() {
40 | return "This view is used to display a single entry in an all day view.";
41 | }
42 |
43 | @Override
44 | protected Class> getJavaDocClass() {
45 | return AllDayEntryView.class;
46 | }
47 |
48 | public static void main(String[] args) {
49 | launch(args);
50 | }
51 | }
52 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/entries/HelloEntryViewBase.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.entries;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Entry;
23 | import com.calendarfx.view.EntryViewBase;
24 | import impl.com.calendarfx.view.CalendarPropertySheet;
25 | import javafx.scene.Node;
26 | import org.controlsfx.control.PropertySheet;
27 |
28 | public abstract class HelloEntryViewBase extends CalendarFXSample {
29 |
30 | protected EntryViewBase> entryView;
31 | protected Entry> entry;
32 |
33 | public HelloEntryViewBase() {
34 | Calendar calendar = new Calendar("Test Calendar");
35 | entry = new Entry<>("Test Entry");
36 | entry.setCalendar(calendar);
37 | }
38 |
39 | @Override
40 | protected Node createControl() {
41 | entryView = createEntryView(entry);
42 | control = entryView;
43 | return entryView;
44 | }
45 |
46 | protected abstract EntryViewBase> createEntryView(Entry> entry);
47 |
48 | @Override
49 | public Node getControlPanel() {
50 | PropertySheet sheet = new CalendarPropertySheet(entryView.getPropertySheetItems());
51 | sheet.getItems().addAll(entry.getPropertySheetItems());
52 | return sheet;
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/entries/HelloMonthEntryView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.entries;
19 |
20 | import com.calendarfx.model.Entry;
21 | import com.calendarfx.view.EntryViewBase;
22 | import com.calendarfx.view.MonthEntryView;
23 |
24 | import java.time.LocalDate;
25 |
26 | public class HelloMonthEntryView extends HelloEntryViewBase {
27 |
28 | public HelloMonthEntryView() {
29 | super();
30 |
31 | entry.setInterval(LocalDate.now(), LocalDate.now().plusDays(5));
32 | }
33 |
34 | @Override
35 | protected EntryViewBase> createEntryView(Entry> entry) {
36 | MonthEntryView view = new MonthEntryView(entry);
37 | view.setPrefSize(400, 20);
38 | return view;
39 | }
40 |
41 | @Override
42 | public String getSampleName() {
43 | return "Month Entry View";
44 | }
45 |
46 | @Override
47 | protected Class> getJavaDocClass() {
48 | return MonthEntryView.class;
49 | }
50 |
51 | @Override
52 | public String getSampleDescription() {
53 | return "This view is used to display a single entry in a month view.";
54 | }
55 |
56 | public static void main(String[] args) {
57 | launch(args);
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/pages/HelloDayPage.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.pages;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Calendar.Style;
23 | import com.calendarfx.model.CalendarSource;
24 | import com.calendarfx.view.DateControl;
25 | import com.calendarfx.view.page.DayPage;
26 |
27 | public class HelloDayPage extends CalendarFXDateControlSample {
28 |
29 | private DayPage dayPage;
30 |
31 | @Override
32 | protected DateControl createControl() {
33 | CalendarSource calendarSource = new CalendarSource("My Calendars");
34 | final Calendar calendar = new Calendar("Calendar");
35 | calendar.setShortName("C");
36 | calendar.setStyle(Style.STYLE2);
37 | calendarSource.getCalendars().add(calendar);
38 |
39 | dayPage = new DayPage();
40 | dayPage.getCalendarSources().add(calendarSource);
41 |
42 | return dayPage;
43 | }
44 |
45 | @Override
46 | public String getSampleName() {
47 | return "Day Page";
48 | }
49 |
50 | @Override
51 | public String getSampleDescription() {
52 | return "The day page displays the calendar information for a single day.";
53 | }
54 |
55 | @Override
56 | protected Class> getJavaDocClass() {
57 | return DayPage.class;
58 | }
59 |
60 | public static void main(String[] args) {
61 | launch(args);
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/pages/HelloWeekPage.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.pages;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.CalendarSource;
23 | import com.calendarfx.view.DateControl;
24 | import com.calendarfx.view.page.WeekPage;
25 |
26 | public class HelloWeekPage extends CalendarFXDateControlSample {
27 |
28 | private WeekPage weekPage;
29 |
30 | @Override
31 | protected DateControl createControl() {
32 | CalendarSource calendarSource = new CalendarSource("My Calendars");
33 | calendarSource.getCalendars().add(new Calendar("Test"));
34 |
35 | weekPage = new WeekPage();
36 | weekPage.getCalendarSources().add(calendarSource);
37 |
38 | return weekPage;
39 | }
40 |
41 | @Override
42 | protected Class> getJavaDocClass() {
43 | return WeekPage.class;
44 | }
45 |
46 | @Override
47 | public String getSampleName() {
48 | return "Week Page";
49 | }
50 |
51 | @Override
52 | public String getSampleDescription() {
53 | return "The week page displays a week view.";
54 | }
55 |
56 | public static void main(String[] args) {
57 | launch(args);
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/pages/HelloYearPage.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.pages;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.CalendarSource;
23 | import com.calendarfx.view.DateControl;
24 | import com.calendarfx.view.page.YearPage;
25 |
26 | public class HelloYearPage extends CalendarFXDateControlSample {
27 |
28 | private YearPage yearPage;
29 |
30 | @Override
31 | protected DateControl createControl() {
32 | CalendarSource calendarSource = new CalendarSource("My Calendars");
33 | calendarSource.getCalendars().add(new Calendar("Test"));
34 |
35 | yearPage = new YearPage();
36 | yearPage.getCalendarSources().add(calendarSource);
37 |
38 | return yearPage;
39 | }
40 |
41 | @Override
42 | public String getSampleName() {
43 | return "Year Page";
44 | }
45 |
46 | @Override
47 | protected Class> getJavaDocClass() {
48 | return YearPage.class;
49 | }
50 |
51 | @Override
52 | public String getSampleDescription() {
53 | return "The year page displays the calendar information for a full year.";
54 | }
55 |
56 | public static void main(String[] args) {
57 | launch(args);
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/popover/HelloEntryDetailsView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.popover;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Entry;
23 | import com.calendarfx.view.DayView;
24 | import com.calendarfx.view.popover.EntryDetailsView;
25 | import javafx.scene.Node;
26 |
27 | public class HelloEntryDetailsView extends CalendarFXSample {
28 |
29 | @Override
30 | public String getSampleName() {
31 | return "Entry Details";
32 | }
33 |
34 | @Override
35 | protected Node createControl() {
36 | DayView dayView = new DayView();
37 | Entry entry = new Entry<>("Hello Entry");
38 | entry.setCalendar(new Calendar("Dummy Calendar"));
39 | return new EntryDetailsView(entry, dayView);
40 | }
41 |
42 | @Override
43 | protected Class> getJavaDocClass() {
44 | return EntryDetailsView.class;
45 | }
46 |
47 | @Override
48 | public String getSampleDescription() {
49 | return "A view used to edit various properties of a calendar entry.";
50 | }
51 |
52 | public static void main(String[] args) {
53 | launch(args);
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/popover/HelloEntryHeaderView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.popover;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Calendar.Style;
23 | import com.calendarfx.model.Entry;
24 | import com.calendarfx.view.popover.EntryHeaderView;
25 | import javafx.scene.Node;
26 |
27 | import java.util.ArrayList;
28 | import java.util.List;
29 |
30 | public class HelloEntryHeaderView extends CalendarFXSample {
31 |
32 | @Override
33 | public String getSampleName() {
34 | return "Entry Header View";
35 | }
36 |
37 | @Override
38 | protected Node createControl() {
39 | Calendar meetings = new Calendar("Meetings");
40 | Calendar training = new Calendar("Training");
41 | Calendar customers = new Calendar("Customers");
42 | Calendar holidays = new Calendar("Holidays");
43 |
44 | meetings.setStyle(Style.STYLE2);
45 | training.setStyle(Style.STYLE3);
46 | customers.setStyle(Style.STYLE4);
47 | holidays.setStyle(Style.STYLE5);
48 |
49 | List calendars = new ArrayList<>();
50 | calendars.add(meetings);
51 | calendars.add(training);
52 | calendars.add(customers);
53 | calendars.add(holidays);
54 |
55 | Entry entry = new Entry<>("Hello Header View");
56 | entry.setCalendar(meetings);
57 |
58 | return new EntryHeaderView(entry, calendars);
59 | }
60 |
61 | @Override
62 | protected Class> getJavaDocClass() {
63 | return EntryHeaderView.class;
64 | }
65 |
66 | @Override
67 | public String getSampleDescription() {
68 | return "A view used to select a calendar from a list of calendars.";
69 | }
70 |
71 | public static void main(String[] args) {
72 | launch(args);
73 | }
74 | }
75 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/popover/HelloPopOverContentPane.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.demo.popover;
18 |
19 | import com.calendarfx.model.Calendar;
20 | import com.calendarfx.model.Entry;
21 | import com.calendarfx.view.CalendarView;
22 | import com.calendarfx.view.popover.EntryPropertiesView;
23 | import com.calendarfx.view.popover.PopOverContentPane;
24 | import com.calendarfx.view.popover.PopOverTitledPane;
25 | import javafx.application.Application;
26 | import javafx.scene.Scene;
27 | import javafx.stage.Stage;
28 |
29 | public class HelloPopOverContentPane extends Application {
30 |
31 | @Override
32 | public void start(Stage primaryStage) {
33 | Calendar calendar = new Calendar();
34 | calendar.setName("Calendar");
35 | calendar.setStyle(Calendar.Style.STYLE2);
36 |
37 | Entry entry = new Entry<>();
38 | entry.setTitle("Google Entry");
39 | entry.setCalendar(calendar);
40 | entry.setLocation("Bogota");
41 |
42 | PopOverContentPane pane = new PopOverContentPane();
43 |
44 | EntryPropertiesView entryPropertiesView = new EntryPropertiesView(entry);
45 | PopOverTitledPane titledPane = new PopOverTitledPane("Properties", entryPropertiesView);
46 | titledPane.getStyleClass().add("no-padding");
47 |
48 | titledPane.setExpanded(true);
49 |
50 | pane.getPanes().add(titledPane);
51 |
52 | primaryStage.setTitle("Entry Properties");
53 | Scene scene = new Scene(pane, 400, 600);
54 | scene.getStylesheets().add(CalendarView.class.getResource("calendar.css").toExternalForm());
55 | primaryStage.setScene(scene);
56 | primaryStage.sizeToScene();
57 | primaryStage.centerOnScreen();
58 | primaryStage.show();
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/print/HelloOptionsView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.print;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.print.OptionsView;
22 | import javafx.scene.Node;
23 |
24 | public class HelloOptionsView extends CalendarFXSample {
25 |
26 | private final OptionsView view = new OptionsView();
27 |
28 | @Override
29 | protected Class> getJavaDocClass() {
30 | return OptionsView.class;
31 | }
32 |
33 | @Override
34 | protected Node createControl() {
35 | return view;
36 | }
37 |
38 | @Override
39 | public String getSampleName() {
40 | return "Options View";
41 | }
42 |
43 | @Override
44 | public String getSampleDescription() {
45 | return "A control that allows to change a few basic settings before printing a calendar view.";
46 | }
47 |
48 | public static void main(String[] args) {
49 | launch(args);
50 | }
51 |
52 | }
53 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/print/HelloPaperView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.print;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.print.PaperView;
22 | import javafx.scene.Node;
23 |
24 | public class HelloPaperView extends CalendarFXSample {
25 |
26 | @Override
27 | protected Node createControl() {
28 | return new PaperView();
29 | }
30 |
31 | @Override
32 | protected Class> getJavaDocClass() {
33 | return PaperView.class;
34 | }
35 |
36 | @Override
37 | public String getSampleName() {
38 | return "Paper View";
39 | }
40 |
41 | @Override
42 | public String getSampleDescription() {
43 | return "This control allows to select the view that is going to be printed and configure the paper type and print margins.";
44 | }
45 |
46 | public static void main(String[] args) {
47 | launch(args);
48 | }
49 |
50 | }
51 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/print/HelloTimeRangeField.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.print;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.print.TimeRangeField;
22 | import javafx.scene.Node;
23 |
24 | public class HelloTimeRangeField extends CalendarFXSample {
25 |
26 | @Override
27 | public String getSampleName() {
28 | return "Time Range Field";
29 | }
30 |
31 | @Override
32 | public String getSampleDescription() {
33 | return "Allows to setup a field on the time range selector.";
34 | }
35 |
36 | @Override
37 | protected Class> getJavaDocClass() {
38 | return TimeRangeField.class;
39 | }
40 |
41 | @Override
42 | protected Node createControl() {
43 | return new TimeRangeField();
44 | }
45 |
46 | public static void main(String[] args) {
47 | launch(args);
48 | }
49 |
50 | }
51 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloAgendaView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.model.CalendarSource;
22 | import com.calendarfx.view.AgendaView;
23 | import com.calendarfx.view.DateControl;
24 |
25 | public class HelloAgendaView extends CalendarFXDateControlSample {
26 |
27 | private AgendaView agendaView;
28 |
29 | @Override
30 | public String getSampleName() {
31 | return "Agenda View";
32 | }
33 |
34 | @Override
35 | protected DateControl createControl() {
36 | agendaView = new AgendaView();
37 | agendaView.setPrefWidth(400);
38 |
39 | CalendarSource calendarSource = new CalendarSource();
40 | HelloCalendar calendar1 = new HelloCalendar();
41 | HelloCalendar calendar2 = new HelloCalendar();
42 | HelloCalendar calendar3 = new HelloCalendar();
43 | HelloCalendar calendar4 = new HelloCalendar();
44 | calendarSource.getCalendars().addAll(calendar1, calendar2, calendar3, calendar4);
45 |
46 | agendaView.getCalendarSources().add(calendarSource);
47 |
48 | return agendaView;
49 | }
50 |
51 | @Override
52 | protected boolean isSupportingDeveloperConsole() {
53 | return false;
54 | }
55 |
56 | @Override
57 | protected Class> getJavaDocClass() {
58 | return AgendaView.class;
59 | }
60 |
61 | @Override
62 | public String getSampleDescription() {
63 | return "The agenda view displays a (text) list of calendar entries for today and several days into the future or past.";
64 | }
65 |
66 | public static void main(String[] args) {
67 | launch(args);
68 | }
69 | }
70 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloCalendar.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.model.Calendar;
21 | import com.calendarfx.model.Entry;
22 |
23 | import java.time.LocalDate;
24 | import java.time.LocalTime;
25 | import java.time.YearMonth;
26 |
27 | /**
28 | * Created by gdiaz on 26/11/2016.
29 | */
30 | class HelloCalendar extends Calendar {
31 |
32 | public HelloCalendar() {
33 | for (int i = 1; i < 28; i++) {
34 |
35 | LocalDate date = YearMonth.now().atDay(i);
36 |
37 | for (int j = 0; j < (int) (Math.random() * 7); j++) {
38 | Entry> entry = new Entry<>();
39 | entry.changeStartDate(date);
40 | entry.changeEndDate(date.plusDays((int) (Math.random() * 4)));
41 |
42 | entry.setTitle("Entry " + (j + 1));
43 |
44 | int hour = (int) (Math.random() * 23);
45 | int durationInHours = Math.min(24 - hour,
46 | (int) (Math.random() * 4));
47 |
48 | LocalTime startTime = LocalTime.of(hour, 0);
49 | LocalTime endTime = startTime.plusHours(durationInHours);
50 |
51 | entry.changeStartTime(startTime);
52 | entry.changeEndTime(endTime);
53 |
54 | if (Math.random() < .3) {
55 | entry.setFullDay(true);
56 | }
57 |
58 | entry.setCalendar(this);
59 | }
60 | }
61 | }
62 | }
63 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloCalendarHeaderView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Calendar.Style;
23 | import com.calendarfx.view.CalendarHeaderView;
24 | import javafx.scene.Node;
25 |
26 | public class HelloCalendarHeaderView extends CalendarFXSample {
27 |
28 | @Override
29 | public String getSampleName() {
30 | return "Calendar Header View";
31 | }
32 |
33 | @Override
34 | protected Node createControl() {
35 | CalendarHeaderView calendarHeaderView = new CalendarHeaderView();
36 | calendarHeaderView.setNumberOfDays(5);
37 | calendarHeaderView.setMaxHeight(30);
38 |
39 | Calendar dirk = new Calendar("Dirk");
40 | Calendar katja = new Calendar("Katja");
41 | Calendar philip = new Calendar("Philip");
42 | Calendar jule = new Calendar("Jule");
43 | Calendar armin = new Calendar("Armin");
44 |
45 | dirk.setStyle(Style.STYLE1);
46 | katja.setStyle(Style.STYLE1);
47 | philip.setStyle(Style.STYLE2);
48 | jule.setStyle(Style.STYLE1);
49 | armin.setStyle(Style.STYLE3);
50 |
51 | calendarHeaderView.getCalendars().add(dirk);
52 | calendarHeaderView.getCalendars().add(katja);
53 | calendarHeaderView.getCalendars().add(philip);
54 | calendarHeaderView.getCalendars().add(jule);
55 | calendarHeaderView.getCalendars().add(armin);
56 |
57 | return calendarHeaderView;
58 | }
59 |
60 | @Override
61 | protected Class> getJavaDocClass() {
62 | return CalendarHeaderView.class;
63 | }
64 |
65 | @Override
66 | public String getSampleDescription() {
67 | return "The all-day view displays entries that last all day / span multiple days.";
68 | }
69 |
70 | public static void main(String[] args) {
71 | launch(args);
72 | }
73 | }
74 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloCalendarSelector.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.model.Calendar;
22 | import com.calendarfx.model.Calendar.Style;
23 | import com.calendarfx.view.CalendarSelector;
24 | import javafx.scene.Node;
25 | import javafx.scene.control.Label;
26 | import javafx.scene.layout.HBox;
27 |
28 | public class HelloCalendarSelector extends CalendarFXSample {
29 |
30 | @Override
31 | public String getSampleName() {
32 | return "Calendar Selector";
33 | }
34 |
35 | @Override
36 | protected Node createControl() {
37 | Calendar meetings = new Calendar("Meetings");
38 | Calendar training = new Calendar("Training");
39 | Calendar customers = new Calendar("Customers");
40 | Calendar holidays = new Calendar("Holidays");
41 |
42 | meetings.setStyle(Style.STYLE2);
43 | training.setStyle(Style.STYLE3);
44 | customers.setStyle(Style.STYLE4);
45 | holidays.setStyle(Style.STYLE5);
46 |
47 | CalendarSelector view = new CalendarSelector();
48 | view.getCalendars().addAll(meetings, training, customers, holidays);
49 | view.setCalendar(meetings);
50 |
51 | Label label = new Label("Selected: " + view.getCalendar().getName());
52 | label.setMaxHeight(Double.MAX_VALUE);
53 | view.calendarProperty().addListener(it -> label.setText("Selected: " + view.getCalendar().getName()));
54 |
55 | HBox box = new HBox(20);
56 | box.setFillHeight(true);
57 | box.getChildren().addAll(view, label);
58 |
59 | return box;
60 | }
61 |
62 | @Override
63 | protected Class> getJavaDocClass() {
64 | return CalendarSelector.class;
65 | }
66 |
67 | @Override
68 | public String getSampleDescription() {
69 | return "A view used to select a calendar from a list of calendars.";
70 | }
71 |
72 | public static void main(String[] args) {
73 | launch(args);
74 | }
75 | }
76 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloRecurrenceView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.RecurrenceView;
22 | import javafx.geometry.Orientation;
23 | import javafx.geometry.Pos;
24 | import javafx.scene.Node;
25 | import javafx.scene.control.Label;
26 | import javafx.scene.control.Separator;
27 | import javafx.scene.layout.VBox;
28 |
29 | public class HelloRecurrenceView extends CalendarFXSample {
30 |
31 | @Override
32 | public String getSampleName() {
33 | return "Recurrence View";
34 | }
35 |
36 | @Override
37 | protected Node createControl() {
38 | RecurrenceView view = new RecurrenceView();
39 |
40 | Label label = new Label("Rule: " + view.getRecurrenceRule());
41 | label.setMaxWidth(300);
42 | label.setWrapText(true);
43 |
44 | view.recurrenceRuleProperty().addListener(it -> label.setText(view.getRecurrenceRule()));
45 |
46 | Separator separator = new Separator(Orientation.HORIZONTAL);
47 |
48 | VBox box = new VBox(20);
49 | box.setFillWidth(true);
50 | box.getChildren().addAll(view, separator, label);
51 | box.setAlignment(Pos.CENTER);
52 |
53 | return box;
54 | }
55 |
56 | @Override
57 | protected Class> getJavaDocClass() {
58 | return RecurrenceView.class;
59 | }
60 |
61 | @Override
62 | public String getSampleDescription() {
63 | return "The recurrence view allows the user to specify recurrence rules according to RFC 2445.";
64 | }
65 |
66 | public static void main(String[] args) {
67 | launch(args);
68 | }
69 | }
70 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloTimeField.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.TimeField;
22 | import javafx.scene.Node;
23 | import javafx.scene.control.Label;
24 | import javafx.scene.layout.VBox;
25 |
26 | public class HelloTimeField extends CalendarFXSample {
27 |
28 | @Override
29 | public String getSampleName() {
30 | return "Time Field";
31 | }
32 |
33 | @Override
34 | protected Node createControl() {
35 | TimeField timeField = new TimeField();
36 | Label label = new Label("Time: ");
37 | label.setText("Time: " + timeField.getValue().toString());
38 | timeField.valueProperty().addListener(it -> label.setText("Time: " + timeField.getValue().toString()));
39 |
40 | VBox box = new VBox();
41 | box.setSpacing(20);
42 | box.getChildren().addAll(timeField, label);
43 |
44 | return box;
45 | }
46 |
47 | @Override
48 | protected Class> getJavaDocClass() {
49 | return TimeField.class;
50 | }
51 |
52 | @Override
53 | public String getSampleDescription() {
54 | return "A control used to specify a local time (hour, minute).";
55 | }
56 |
57 | public static void main(String[] args) {
58 | launch(args);
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloWeekDayHeaderView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.view.DateControl;
22 | import com.calendarfx.view.WeekDayHeaderView;
23 | import javafx.geometry.Pos;
24 | import javafx.scene.Node;
25 | import javafx.scene.effect.Reflection;
26 | import javafx.scene.layout.HBox;
27 | import javafx.scene.layout.StackPane;
28 |
29 | public class HelloWeekDayHeaderView extends CalendarFXDateControlSample {
30 |
31 | @Override
32 | public String getSampleName() {
33 | return "Week Day Header View";
34 | }
35 |
36 | @Override
37 | protected DateControl createControl() {
38 | return new WeekDayHeaderView();
39 | }
40 |
41 | @Override
42 | protected Node wrap(Node node) {
43 | HBox box = new HBox();
44 | box.setMaxWidth(Double.MAX_VALUE);
45 | box.setAlignment(Pos.CENTER);
46 | box.setFillHeight(false);
47 |
48 | StackPane stackPane = new StackPane();
49 | stackPane.setStyle("-fx-background-color: white; -fx-border-color: gray; -fx-border-width: .25px; -fx-padding: 20px;");
50 | box.getChildren().add(stackPane);
51 |
52 | stackPane.getChildren().add(node);
53 | stackPane.setEffect(new Reflection());
54 |
55 | return box;
56 | }
57 |
58 | @Override
59 | public String getSampleDescription() {
60 | return "The week day header view displays the labels for each week day.";
61 | }
62 |
63 | @Override
64 | protected Class> getJavaDocClass() {
65 | return WeekDayHeaderView.class;
66 | }
67 |
68 | public static void main(String[] args) {
69 | launch(args);
70 | }
71 | }
72 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloWeekFieldsView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXSample;
21 | import com.calendarfx.view.AgendaView;
22 | import com.calendarfx.view.WeekFieldsView;
23 | import javafx.scene.control.Control;
24 |
25 | public class HelloWeekFieldsView extends CalendarFXSample {
26 |
27 | private WeekFieldsView view;
28 |
29 | @Override
30 | public String getSampleName() {
31 | return "Week Fields View";
32 | }
33 |
34 | @Override
35 | protected Control createControl() {
36 | view = new WeekFieldsView();
37 | return view;
38 | }
39 |
40 | @Override
41 | protected Class> getJavaDocClass() {
42 | return AgendaView.class;
43 | }
44 |
45 | @Override
46 | public String getSampleDescription() {
47 | return "The week fields view lets the user specify the first day of the week " +
48 | "(e.g. MONDAY in Germany, SUNDAY in the US) and the minimum number of " +
49 | "days in the first week of the year.";
50 | }
51 |
52 | public static void main(String[] args) {
53 | launch(args);
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/com/calendarfx/demo/views/HelloWeekTimeScaleView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | * Copyright (C) 2006 Google Inc.
4 | *
5 | * Licensed under the Apache License, Version 2.0 (the "License");
6 | * you may not use this file except in compliance with the License.
7 | * You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package com.calendarfx.demo.views;
19 |
20 | import com.calendarfx.demo.CalendarFXDateControlSample;
21 | import com.calendarfx.view.DateControl;
22 | import com.calendarfx.view.WeekTimeScaleView;
23 | import javafx.geometry.Pos;
24 | import javafx.scene.Node;
25 | import javafx.scene.effect.Reflection;
26 | import javafx.scene.layout.HBox;
27 | import javafx.scene.layout.StackPane;
28 |
29 | public class HelloWeekTimeScaleView extends CalendarFXDateControlSample {
30 |
31 | @Override
32 | public String getSampleName() {
33 | return "Week Time Scale";
34 | }
35 |
36 | @Override
37 | protected DateControl createControl() {
38 | return new WeekTimeScaleView();
39 | }
40 |
41 | @Override
42 | protected Node wrap(Node node) {
43 | HBox box = new HBox();
44 | box.setStyle("-fx-padding: 100px;");
45 | box.setAlignment(Pos.CENTER);
46 | box.setFillHeight(false);
47 |
48 | StackPane stackPane = new StackPane();
49 | stackPane.setStyle(
50 | "-fx-background-color: white; -fx-border-color: gray; -fx-border-width: .25px; -fx-padding: 0 20 0 20;");
51 | box.getChildren().add(stackPane);
52 |
53 | stackPane.getChildren().add(node);
54 | stackPane.setEffect(new Reflection());
55 |
56 | return box;
57 | }
58 |
59 | @Override
60 | protected Class> getJavaDocClass() {
61 | return WeekTimeScaleView.class;
62 | }
63 |
64 | @Override
65 | public String getSampleDescription() {
66 | return "The scale shows the time of day vertically.";
67 | }
68 |
69 | public static void main(String[] args) {
70 | launch(args);
71 | }
72 | }
73 |
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/java/module-info.java:
--------------------------------------------------------------------------------
1 | open module com.calendarfx.sampler {
2 | requires transitive org.controlsfx.fxsampler;
3 | requires transitive javafx.graphics;
4 |
5 | requires javafx.web;
6 | requires fr.brouillard.oss.cssfx;
7 | requires com.calendarfx.view;
8 |
9 | exports com.calendarfx.demo to org.controlsfx.fxsampler;
10 | exports com.calendarfx.demo.entries to org.controlsfx.fxsampler;
11 | exports com.calendarfx.demo.pages to org.controlsfx.fxsampler;
12 | exports com.calendarfx.demo.performance to org.controlsfx.fxsampler;
13 | exports com.calendarfx.demo.popover to org.controlsfx.fxsampler;
14 | exports com.calendarfx.demo.print to org.controlsfx.fxsampler;
15 | exports com.calendarfx.demo.views to org.controlsfx.fxsampler;
16 |
17 | provides fxsampler.FXSamplerProject with com.calendarfx.demo.CalendarFXSamplerProject;
18 | }
--------------------------------------------------------------------------------
/CalendarFXSampler/src/main/resources/META-INF/services/fxsampler.FXSamplerProject:
--------------------------------------------------------------------------------
1 | com.calendarfx.demo.CalendarFXSamplerProject
--------------------------------------------------------------------------------
/CalendarFXSchedulerApp/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | *.iml
3 |
--------------------------------------------------------------------------------
/CalendarFXSchedulerApp/pom.xml:
--------------------------------------------------------------------------------
1 |
16 |
17 |
19 | 4.0.0
20 | scheduler
21 | CalendarFXScheduler
22 |
23 |
24 | com.calendarfx
25 | calendar
26 | 11.12.7
27 | ../pom.xml
28 |
29 |
30 |
31 | true
32 |
33 |
34 |
35 |
36 | com.calendarfx
37 | view
38 |
39 |
40 | fr.brouillard.oss
41 | cssfx
42 |
43 |
44 |
45 |
46 |
47 |
48 | org.openjfx
49 | javafx-maven-plugin
50 | ${javafx.maven.plugin.version}
51 |
52 | com.calendarfx.scheduler.SchedulerApp
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/CalendarFXSchedulerApp/src/main/java/com/calendarfx/scheduler/SchedulerAppLauncher.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.scheduler;
18 |
19 | public class SchedulerAppLauncher {
20 |
21 | public static void main(String[] args) {
22 | System.setProperty("calendarfx.developer", "true");
23 | SchedulerApp.main(args);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/CalendarFXSchedulerApp/src/main/java/module-info.java:
--------------------------------------------------------------------------------
1 | module com.calendarfx.scheduler {
2 | requires transitive javafx.graphics;
3 | requires fr.brouillard.oss.cssfx;
4 | requires javafx.controls;
5 | requires com.calendarfx.view;
6 |
7 | exports com.calendarfx.scheduler;
8 | }
--------------------------------------------------------------------------------
/CalendarFXView/.gitignore:
--------------------------------------------------------------------------------
1 | /target/
2 | /scenicView.properties
3 | *.iml
4 |
5 |
--------------------------------------------------------------------------------
/CalendarFXView/logging.properties:
--------------------------------------------------------------------------------
1 | # To use this property file add the following command line argument:
2 | # -Djava.util.logging.config.file=${project_loc}/logging.properties
3 |
4 | # Specify the handlers to create in the root logger
5 | # (all loggers are children of the root logger)
6 | # The following creates two handlers
7 | # handlers = java.util.logging.ConsoleHandler, java.util.logging.FileHandler
8 | handlers = java.util.logging.ConsoleHandler
9 |
10 | # Set the default logging level for the root logger
11 | .level = OFF
12 |
13 | # Set the default logging level for new ConsoleHandler instances
14 | java.util.logging.ConsoleHandler.level = FINE
15 |
16 | # Set the default logging level for new FileHandler instances
17 | # java.util.logging.FileHandler.level = ALL
18 |
19 | # Set the default formatter for new ConsoleHandler instances
20 | java.util.logging.ConsoleHandler.formatter = com.calendarfx.util.LoggingFormatter
21 |
22 | # LOG DOMAINS
23 | com.calendarfx.config.level = OFF
24 | com.calendarfx.model.level = OFF
25 | com.calendarfx.events.level = OFF
26 | com.calendarfx.view.level = OFF
27 | com.calendarfx.search.level = OFF
28 | com.calendarfx.editing.level = OFF
29 | com.calendarfx.recurrence.level = OFF
30 | com.calendarfx.printing.level = OFF
31 | com.calendarfx.performance.level = OFF
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/all-day-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/all-day-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/calendar-header-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/calendar-header-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/calendar-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/calendar-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/date-picker.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/date-picker.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/datecontrol.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/datecontrol.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/day-page.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/day-page.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/day-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/day-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/detailed-day-view-agenda.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/detailed-day-view-agenda.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/detailed-week-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/detailed-week-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/developer-console.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/developer-console.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/distribution.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/distribution.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/entry.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/entry.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/hierarchy.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/hierarchy.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/month-page.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/month-page.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/month-sheet-view-aligned.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/month-sheet-view-aligned.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/month-sheet-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/month-sheet-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/month-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/month-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/resources-view-availability.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/resources-view-availability.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/resources-view-dates-over-resources.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/resources-view-dates-over-resources.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/resources-view-resources-over-dates.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/resources-view-resources-over-dates.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/title.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/title.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/week-page.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/week-page.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/week-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/week-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/year-page-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/year-page-2.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/year-page.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/year-page.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/asciidoc/manual-images/year-view.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/dlsc-software-consulting-gmbh/CalendarFX/f5ac9a744d4dd4c6a341790592183834a58acc70/CalendarFXView/src/main/asciidoc/manual-images/year-view.png
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/model/Marker.java:
--------------------------------------------------------------------------------
1 | package com.calendarfx.model;
2 |
3 | import javafx.beans.property.BooleanProperty;
4 | import javafx.beans.property.ObjectProperty;
5 | import javafx.beans.property.SimpleBooleanProperty;
6 | import javafx.beans.property.SimpleObjectProperty;
7 | import javafx.beans.property.SimpleStringProperty;
8 | import javafx.beans.property.StringProperty;
9 | import javafx.collections.FXCollections;
10 | import javafx.collections.ObservableList;
11 |
12 | import java.time.ZonedDateTime;
13 |
14 | public class Marker {
15 |
16 | public Marker() {
17 | }
18 |
19 | private final BooleanProperty movable = new SimpleBooleanProperty(this, "movable", true);
20 |
21 | public final boolean isMovable() {
22 | return movable.get();
23 | }
24 |
25 | public final BooleanProperty movableProperty() {
26 | return movable;
27 | }
28 |
29 | public final void setMovable(boolean movable) {
30 | this.movable.set(movable);
31 | }
32 |
33 | private final ObjectProperty time = new SimpleObjectProperty<>(this, "time", ZonedDateTime.now());
34 |
35 | public ZonedDateTime getTime() {
36 | return time.get();
37 | }
38 |
39 | public ObjectProperty timeProperty() {
40 | return time;
41 | }
42 |
43 | public void setTime(ZonedDateTime time) {
44 | this.time.set(time);
45 | }
46 |
47 | private final StringProperty title = new SimpleStringProperty(this, "title", "Untitled");
48 |
49 | public String getTitle() {
50 | return title.get();
51 | }
52 |
53 | public StringProperty titleProperty() {
54 | return title;
55 | }
56 |
57 | public void setTitle(String title) {
58 | this.title.set(title);
59 | }
60 |
61 | private final StringProperty style = new SimpleStringProperty(this, "style");
62 |
63 | public final String getStyle() {
64 | return style.get();
65 | }
66 |
67 | public final StringProperty styleProperty() {
68 | return style;
69 | }
70 |
71 | public final void setStyle(String style) {
72 | this.style.set(style);
73 | }
74 |
75 | private final ObservableList styleClass = FXCollections.observableArrayList();
76 |
77 | public final ObservableList getStyleClass() {
78 | return styleClass;
79 | }
80 | }
81 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/model/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /**
18 | * Classes for modeling calendars and entries.
19 | */
20 | package com.calendarfx.model;
21 |
22 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/util/CalendarFX.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.util;
18 |
19 | import java.io.IOException;
20 | import java.io.InputStream;
21 | import java.util.Properties;
22 |
23 | /**
24 | * Common superclass for all controls in this framework.
25 | */
26 | public final class CalendarFX {
27 |
28 | private static String version;
29 |
30 | /**
31 | * Returns the CalendarFX version number in the format major.minor.bug
32 | * (1.0.0).
33 | *
34 | * @return the CalendarFX version number
35 | */
36 | public static String getVersion() {
37 | if (version == null) {
38 |
39 | InputStream stream = CalendarFX.class.getResourceAsStream("version.properties");
40 | Properties props = new Properties();
41 | try {
42 | props.load(stream);
43 | } catch (IOException ex) {
44 | LoggingDomain.CONFIG.throwing(CalendarFX.class.getName(), "getVersion()", ex);
45 | }
46 |
47 | version = props.getProperty("calendarfx.version", "1.0.0");
48 |
49 | LoggingDomain.CONFIG.info("CalendarFX Version: " + version);
50 | }
51 | return version;
52 | }
53 | }
54 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/util/LoggingDomain.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.util;
18 |
19 | import java.util.logging.Logger;
20 |
21 | /**
22 | * Globally defined loggers. Alternative approach to using class based loggers.
23 | */
24 | public final class LoggingDomain {
25 |
26 | private static final String PREFIX = "com.calendarfx";
27 |
28 | /**
29 | * Logger used for anything related to the configuration of the calendar.
30 | */
31 | public static final Logger CONFIG = Logger.getLogger(PREFIX + ".config");
32 |
33 | /**
34 | * Logger used for anything related to the creation, fireing, and handling
35 | * of events.
36 | */
37 | public static final Logger EVENTS = Logger.getLogger(PREFIX + ".events");
38 |
39 | /**
40 | * Logger used for anything related to the model, adding / removing entries.
41 | */
42 | public static final Logger MODEL = Logger.getLogger(PREFIX + ".model");
43 |
44 | /**
45 | * Logger used for anything related to the creation of the view.
46 | */
47 | public static final Logger VIEW = Logger.getLogger(PREFIX + ".view");
48 |
49 | /**
50 | * Logger used for the search service.
51 | */
52 | public static final Logger SEARCH = Logger.getLogger(PREFIX + ".search");
53 |
54 | /**
55 | * Logger used for anything related to the editing of entries.
56 | */
57 | public static final Logger EDITING = Logger.getLogger(PREFIX + ".editing");
58 |
59 | /**
60 | * Logger used for anything related to recurrence.
61 | */
62 | public static final Logger RECURRENCE = Logger.getLogger(PREFIX + ".recurrence");
63 |
64 | /**
65 | * Logger used for anything related to printing.
66 | */
67 | public static final Logger PRINTING = Logger.getLogger(PREFIX + ".printing");
68 |
69 | /**
70 | * Logger used for anything related to performance.
71 | */
72 | public static final Logger PERFORMANCE = Logger.getLogger(PREFIX + ".performance");
73 | }
74 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/util/WeakList.java:
--------------------------------------------------------------------------------
1 | package com.calendarfx.util;
2 |
3 | import java.lang.ref.WeakReference;
4 | import java.util.AbstractList;
5 | import java.util.ArrayList;
6 | import java.util.Collection;
7 | import java.util.Iterator;
8 | import java.util.List;
9 |
10 | /**
11 | * A simple list wich holds only weak references to the original objects.
12 | */
13 | public class WeakList extends AbstractList {
14 |
15 | private final ArrayList> items;
16 |
17 | /**
18 | * Creates new WeakList
19 | */
20 | public WeakList() {
21 | items = new ArrayList<>();
22 | }
23 |
24 | public WeakList(Collection c) {
25 | items = new ArrayList();
26 | addAll(0, c);
27 | }
28 |
29 | public void add(int index, Object element) {
30 | items.add(index, new WeakReference(element));
31 | }
32 |
33 | public Iterator iterator() {
34 | return new WeakListIterator();
35 | }
36 |
37 | public int size() {
38 | removeReleased();
39 | return items.size();
40 | }
41 |
42 | public T get(int index) {
43 | return items.get(index).get();
44 | }
45 |
46 | private void removeReleased() {
47 | List> temp = new ArrayList<>(items);
48 | temp.forEach(ref -> {
49 | if (ref.get() == null) {
50 | items.remove(ref);
51 | }
52 | });
53 | }
54 |
55 | private class WeakListIterator implements Iterator {
56 |
57 | private final int n;
58 | private int i;
59 |
60 | public WeakListIterator() {
61 | n = size();
62 | i = 0;
63 | }
64 |
65 | public boolean hasNext() {
66 | return i < n;
67 | }
68 |
69 | public T next() {
70 | return get(i++);
71 | }
72 |
73 | public void remove() {
74 | throw new UnsupportedOperationException();
75 | }
76 |
77 | }
78 | }
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/util/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | /**
18 | * Core classes used for logging, license management.
19 | */
20 | package com.calendarfx.util;
21 |
22 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/view/AllDayEntryView.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.view;
18 |
19 | import com.calendarfx.model.Entry;
20 | import impl.com.calendarfx.view.AllDayEntryViewSkin;
21 | import javafx.scene.control.Skin;
22 |
23 | /**
24 | * An entry view specialized for display in the {@link AllDayView} control.
25 | */
26 | public class AllDayEntryView extends EntryViewBase {
27 |
28 | /**
29 | * Constructs a new entry.
30 | *
31 | * @param entry the entry for which the view will be created
32 | */
33 | public AllDayEntryView(Entry> entry) {
34 | super(entry);
35 | }
36 |
37 | @Override
38 | protected Skin> createDefaultSkin() {
39 | return new AllDayEntryViewSkin(this);
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/CalendarFXView/src/main/java/com/calendarfx/view/ButtonBar.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2017 Dirk Lemmermann Software & Consulting (dlsc.com)
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package com.calendarfx.view;
18 |
19 | import impl.com.calendarfx.view.ButtonBarSkin;
20 | import javafx.collections.FXCollections;
21 | import javafx.collections.ObservableList;
22 | import javafx.scene.control.Button;
23 | import javafx.scene.control.Skin;
24 |
25 | /**
26 | * A segmented button bar control based on the segmented button control
27 | * found in ControlsFX but this one working with regular buttons and not
28 | * toggle buttons.
29 | *
30 | */
31 | public class ButtonBar extends CalendarFXControl {
32 |
33 | private final ObservableList