# Calendar

<div align="left"><img src="https://963067965-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIJW5nbmYRaSNWePAac%2F-MIxu2KP4MClY9gv_q2W%2F-MIxukRW4MCg4cZG6CFR%2FProperty-Calendar.png?alt=media&#x26;token=2394bf9c-7358-46e7-a7eb-eea12647cae2" alt=""></div>

| Property             | Function                                                                                                                                                                                                                                |          |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
| Date format          | <p>Sets date fromat to use for the formatted date property<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Date format</code><br><strong>Code:</strong><br><code>widget.content.formatDate</code></p> | `string` |
| Started date         | <p>Sets the calendar start date<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Started date</code><br><strong>Code:</strong><br><code>widget.content.startedDate</code></p>                          | `string` |
| Ended date           | <p>Sets the calendar end date<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Ended date</code><br><strong>Code:</strong><br><code>widget.content.endedDate</code></p>                                | `string` |
| Allow interval       | <p>Enable to select the date interval<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Allow interval</code><br><strong>Code:</strong><br><code>widget.content.allowInterval</code></p>                | `bool`   |
| Calendar orientation | <p>Sets calendar orientation<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Calendar orientation</code><br><strong>Code:</strong><br><code>widget.content.calendarOrientation</code></p>             | `enum`   |
| Grid                 | <p>Display calendar grid<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Grid</code><br><strong>Code:</strong><br><code>widget.content.gridVisible</code></p>                                         | `bool`   |
| Month                | <p>Display month bar<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Month</code><br><strong>Code:</strong><br><code>widget.content.showSelectMonth</code></p>                                        | `bool`   |
| Week                 | <p>Display week numbers<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Week</code><br><strong>Code:</strong><br><code>widget.content.weekNumbersVisible</code></p>                                   | `bool`   |
| Day of week          | <p>Display day of week<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Day of week</code><br><strong>Code:</strong><br><code>widget.content.dayOfWeek</code></p>                                      | `bool`   |
| Round labels         | <p>Display round labels<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Settings > Round labels</code><br><strong>Code:</strong><br><code>widget.content.roundRect</code></p>                                    | `bool`   |

## Colors

<div align="left"><img src="https://963067965-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIJW5nbmYRaSNWePAac%2F-MIxu2KP4MClY9gv_q2W%2F-MIxukRXIgFEzRzPyv5T%2FProperty-Calendar-Colors.png?alt=media&#x26;token=297e92b9-e24d-4d8b-aa36-853f3d408173" alt=""></div>

| Property            | Function                                                                                                                                                                                                                | Type    |
| ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- |
| Grid color          | <p>Color of grid lines<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Grid color</code><br><strong>Code:</strong><br><code>widget.content.gridColor</code></p>                         | `color` |
| Color               | <p>Color of day<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Color</code><br><strong>Code:</strong><br><code>widget.content.color</code></p>                                         | `color` |
| Selected color      | <p>Color of selected day<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Selected color</code><br><strong>Code:</strong><br><code>widget.content.selectedColor</code></p>               | `color` |
| Selected font color | <p>Font color of selected day<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Selected font color</code><br><strong>Code:</strong><br><code>widget.content.selectedFontColor</code></p> | `color` |
| Event color         | <p>Color of day with event<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Event color</code><br><strong>Code:</strong><br><code>widget.content.eventColor</code></p>                   | `color` |
| Event font color    | <p>Font color of day with event<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Event font color</code><br><strong>Code:</strong><br><code>widget.content.eventFontColor</code></p>     | `color` |
| Inactive color      | <p>Color of day of another month<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Colors > Inactive color</code><br><strong>Code:</strong><br><code>widget.content.inactiveColor</code></p>       | `color` |

## Variables

| Property             | Function                                                                                                                                                                                                                     | Type     |
| -------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
| Selected date        | <p>Gets selected date, YYYY-MM-DD<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Selected date</code><br><strong>Code:</strong><br><code>widget.content.selectedDate</code></p>                      | `string` |
| Selected date start  | <p>Gets selected date start, YYYY-MM-DD<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Selected date start</code><br><strong>Code:</strong><br><code>widget.content.selectedDateStart</code></p>     | `string` |
| Selected date end    | <p>Gets selected date end, YYYY-MM-DD<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Selected date end</code><br><strong>Code:</strong><br><code>widget.content.selectedDateEnd</code></p>           | `string` |
| Is date selected     | <p>Gets true if date is selected<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Is date selected</code><br><strong>Code:</strong><br><code>widget.content.isDateSelected</code></p>                  | `bool`   |
| Is interval selected | <p>Gets true if date interval is selected<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > Is interval selected</code><br><strong>Code:</strong><br><code>widget.content.isIntervalSelected</code></p> | `bool`   |

## Formatted date

| Property        | Function                                                                                                                                                                                                                | Type     |
| --------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
| Formatted date  | <p>Gets selected formatted date<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Formatted date</code><br><strong>Code:</strong><br><code>widget.content.formattedDate</code></p> | `string` |
| Selected year   | <p>Gets selected year<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Selected year</code><br><strong>Code:</strong><br><code>widget.content.selectedYear</code></p>             | `string` |
| Selected month  | <p>Gets selected month<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Selected month</code><br><strong>Code:</strong><br><code>widget.content.selectedMonth</code></p>          | `string` |
| Selected day    | <p>Gets selected day<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Selected day</code><br><strong>Code:</strong><br><code>widget.content.selectedDay</code></p>                | `string` |
| Selected hour   | <p>Gets selected hour<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Selected hour</code><br><strong>Code:</strong><br><code>widget.content.selectedHour</code></p>             | `string` |
| Selected minute | <p>Gets selected minute<br><br><strong>Actions editor:</strong><br><code>Property > Calendar > FormattedDate > Selected minute</code><br><strong>Code:</strong><br><code>widget.content.selectedMinute</code></p>       | `string` |

## Actions

| Property             | Function                                                                                                                                                                                                                                                                  |
| -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Select date          | <p>Select date, YYYY-MM-DD, i.e. 2018-09-27<br><br><strong>Actions editor:</strong><br><code>Actions > Common > Select date</code><br><strong>Code:</strong><br><code>widget.content.script.actionSelectDate(QString date)</code></p>                                     |
| Select date interval | <p>Select date interval, YYYY-MM-DD, i.e. 2018-09-27<br><br><strong>Actions editor:</strong><br><code>Actions > Common > Select date interval</code><br><strong>Code:</strong><br><code>widget.content.script.actionSelectInterval(QString start, QString end)</code></p> |
| Clear selected date  | <p><strong>Actions editor:</strong><br><code>Actions > Common > Clear selected date</code><br><strong>Code:</strong><br><code>widget.content.script.actionClearDate()</code></p>                                                                                          |
| Show date            | <p>Show calendar for date, YYYY-MM-DD, i.e. 2018-09-27<br><br><strong>Actions editor:</strong><br><code>Actions > Common > Show date</code><br><strong>Code:</strong><br><code>widget.content.script.actionShowDate(QString date)</code></p>                              |
| Show year            | <p>Show calendar for year, i.e. 2017<br><br><strong>Actions editor:</strong><br><code>Actions > Common > Show year</code><br><strong>Code:</strong><br><code>widget.content.script.actionShowYear(QString year)</code></p>                                                |
| Show month           | <p>Show calendar for month, 1 to 12<br><br><strong>Actions editor:</strong><br><code>Actions > Common > Show month</code><br><strong>Code:</strong><br><code>widget.content.script.actionShowMonth(QString month)</code></p>                                              |

## Events

| Property                       | Function                                                                                                                                                                                                                                      |
| ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Selected date changed          | <p>Event when selected date is changed<br><br><strong>Actions editor:</strong><br><code>Event > Selected date changed</code><br><strong>Code:</strong><br><code>widget.content.script.eventDateChanged()</code></p>                           |
| Selected date interval changed | <p>Event when selected date interval is changed<br><br><strong>Actions editor:</strong><br><code>Event > Selected date interval changed</code><br><strong>Code:</strong><br><code>widget.content.script.eventDateIntervalChanged()</code></p> |
