typedef QValueList<QDate> ZeCalendar::holidayMap [protected] |
A list of QDates that shall be marked as holiday.
typedef QMap<QString, QColor> ZeCalendar::colorMap [protected] |
Colors are stored in a map because this makes loading of themes easier.
typedef QMap<QString, QFont> ZeCalendar::fontMap [protected] |
Fonts are stored in a map because this makes loading of themes easier.
| ZeCalendar::ZeCalendar | ( | QWidget * | parent = 0, |
|
| const char * | name = 0 | |||
| ) |
| ZeCalendar::~ZeCalendar | ( | ) |
| void ZeCalendar::dateChange | ( | int | amount, | |
| QString | period | |||
| ) | [protected, virtual, slot] |
Slot called when relative date changes shall take place. Has to be connected to a signal emmiting a QString as period (currently supported are 'm' for month and 'y' for year) and the amount (int).
| void ZeCalendar::redraw | ( | ) |
This function will be called on resize or whenever a property is changed (if autoUpdate == true).
Does all of the drawing of the complete calendar.
| void ZeCalendar::setDate | ( | QDate | date | ) |
Should be used to set the date you want so show - the approriate month will be shown by ZeCalendar
| void ZeCalendar::setAutoUpdate | ( | bool | au | ) |
autoUpdate is on by default. That means that changing a property will result in an immediate redraw of the calendar. You might want to turn it off when setting a bunch of properties and then redraw in one go.
e.g.:
zecalendar->setAutoUpdate(false);
zecalendar->setXXX(..);
....
zecalendar->setAutoUpdate(true);
zecalendar->redraw();
| void ZeCalendar::setHeaderColFontColor | ( | QColor | hfc | ) |
Set the headerColFontColor.
This color is used for the text on the colums (abbreviations of day names).
| QColor ZeCalendar::getHeaderColFontColor | ( | ) | const |
| void ZeCalendar::setHeaderColColor | ( | QColor | hbc | ) |
Set the headerColColor.
This color is used to draw the background of the header.
| QColor ZeCalendar::getHeaderColColor | ( | ) | const |
| void ZeCalendar::setHeaderColBorderColor | ( | QColor | hbc | ) |
Set the headerColBorderColor.
This color is used to draw the borders of the header columns.
| QColor ZeCalendar::getHeaderColBorderColor | ( | ) | const |
| void ZeCalendar::setActiveDayFontColor | ( | QColor | afc | ) |
Set the activeDayFontColor.
This color is used for the text of the active day (when moving with the mouse over it).
| QColor ZeCalendar::getActiveDayFontColor | ( | ) | const |
| void ZeCalendar::setActiveDayColor | ( | QColor | abc | ) |
Set the activeDayColor.
This color is used to draw the background of the active day (when moving with the mouse over it).
| QColor ZeCalendar::getActiveDayColor | ( | ) | const |
| void ZeCalendar::setActiveDayBorderColor | ( | QColor | abc | ) |
Set the activeDayBorderColor.
This color is used to draw the border of the active day (when moving with the mouse over it).
| QColor ZeCalendar::getActiveDayBorderColor | ( | ) | const |
| void ZeCalendar::setWeekDayFontColor | ( | QColor | wfc | ) |
Set the weekDayFontColor.
This color is used to draw the text of a weekday.
| QColor ZeCalendar::getWeekDayFontColor | ( | ) | const |
| void ZeCalendar::setWeekDayColor | ( | QColor | wbc | ) |
Set the weekDayColor.
This color is used to draw the background of a weekday.
| QColor ZeCalendar::getWeekDayColor | ( | ) | const |
| void ZeCalendar::setSaturdayFontColor | ( | QColor | sfc | ) |
Set the saturdayFontColor.
This color is used to draw the text of a day if saturday.
| QColor ZeCalendar::getSaturdayFontColor | ( | ) | const |
| void ZeCalendar::setSaturdayColor | ( | QColor | sbc | ) |
Set the saturdayColor.
This color is used to draw the background of a day if saturday.
| QColor ZeCalendar::getSaturdayColor | ( | ) | const |
| void ZeCalendar::setSundayFontColor | ( | QColor | sfc | ) |
Set the sundayFontColor.
This color is used to draw the text of a day if sunday.
| QColor ZeCalendar::getSundayFontColor | ( | ) | const |
| void ZeCalendar::setSundayColor | ( | QColor | sbc | ) |
Set the sundayColor.
This color is used to draw the background of a day if sunday.
| QColor ZeCalendar::getSundayColor | ( | ) | const |
| void ZeCalendar::setHeaderRowFontColor | ( | QColor | wfc | ) |
Set the headerRowFontColor.
This color is used to draw the weeknumber.
| QColor ZeCalendar::getHeaderRowFontColor | ( | ) | const |
| void ZeCalendar::setHeaderRowColor | ( | QColor | wbc | ) |
Set the headerRowColor.
This color is used to draw the background of the leftmost column showing the weeknumbers.
| QColor ZeCalendar::getHeaderRowColor | ( | ) | const |
| void ZeCalendar::setHeaderRowBorderColor | ( | QColor | wbc | ) |
Set the headerRowBorderColor.
This color is used to draw the border of the cells of the leftmost column showing the weeknumbers.
| QColor ZeCalendar::getHeaderRowBorderColor | ( | ) | const |
| void ZeCalendar::setGridColor | ( | QColor | lc | ) |
Set the gridColor.
This color is used to draw the grid of the calendar (separates the days).
| QColor ZeCalendar::getGridColor | ( | ) | const |
| void ZeCalendar::setOutsideDayFontColor | ( | QColor | oc | ) |
Set the activeDayColor.
This color is used to draw the text of a day if not in the current month.
| QColor ZeCalendar::getOutsideDayFontColor | ( | ) | const |
| void ZeCalendar::setOutsideDayColor | ( | QColor | oc | ) |
Set the outsideDayColor.
This color is used to draw the text of a day if not in the current month.
| QColor ZeCalendar::getOutsideDayColor | ( | ) | const |
| void ZeCalendar::setOutsideWeekendDayColor | ( | QColor | oc | ) |
Set the outsideWeekendDayColor.
This color is used to draw the text of a day if not in the current month and if saturday or sunday.
| QColor ZeCalendar::getOutsideWeekendDayColor | ( | ) | const |
| void ZeCalendar::setHolidayColor | ( | QColor | hc | ) |
Set the hoildayColor.
This color is used to draw the text of a day if holiday.
| QColor ZeCalendar::getHolidayColor | ( | ) | const |
| void ZeCalendar::setTodayColor | ( | QColor | tc | ) |
Set the todayColor.
This color is used to draw the background of a day if it is the current day.
| QColor ZeCalendar::getTodayColor | ( | ) | const |
| void ZeCalendar::setTodayBorder | ( | QColor | tb | ) |
Set the todayBorderColor.
This color is used to draw the border of a day if it is the current day.
| QColor ZeCalendar::getTodayBorder | ( | ) | const |
| void ZeCalendar::setTodayFontColor | ( | QColor | tfc | ) |
Set the todayFontColor.
This color is used to draw the text of a day if it is the current day.
| QColor ZeCalendar::getTodayFontColor | ( | ) | const |
| void ZeCalendar::setNaviChooseColor | ( | QColor | nc | ) |
Set the naviChooseColor.
This color is used to draw the background of the selection buttons and the date label on top of the calendar.
| QColor ZeCalendar::getNaviChooseColor | ( | ) | const |
| void ZeCalendar::setNaviChooseFontColor | ( | QColor | nfc | ) |
Set the naviChooseFontColor.
This color is used to draw the text of the selection buttons and the date label on top of the calendar.
| QColor ZeCalendar::getNaviChooseFontColor | ( | ) | const |
| void ZeCalendar::setNaviChooseBorder | ( | QColor | ncb | ) |
Set the naviChooseBorder.
This color is used to draw the border of the selection buttons and the date label on top of the calendar.
| QColor ZeCalendar::getNaviChooseBorder | ( | ) | const |
| void ZeCalendar::setActiveDayFont | ( | QFont | adf | ) |
Set the activeDayFont.
This font is used when drawing the text of the moving activeDayBox.
| QFont ZeCalendar::getActiveDayFont | ( | ) | const |
| void ZeCalendar::setTodayFont | ( | QFont | tdf | ) |
Set the todayFont.
This font is used when drawing the text of the current day.
| QFont ZeCalendar::getTodayFont | ( | ) | const |
| void ZeCalendar::setDayFont | ( | QFont | df | ) |
Set the dayFont.
This font is used when drawing the text of a day.
| QFont ZeCalendar::getDayFont | ( | ) | const |
| void ZeCalendar::setHeaderRowFont | ( | QFont | wf | ) |
Set the headerRowFont.
This font is used when drawing the text of the headers (day names).
| QFont ZeCalendar::getHeaderRowFont | ( | ) | const |
| void ZeCalendar::setHeaderColFont | ( | QFont | hf | ) |
Set the headerColFont.
This font is used when drawing the text of the columns (week numbers).
| QFont ZeCalendar::getHeaderColFont | ( | ) | const |
| void ZeCalendar::setNaviChooseFont | ( | QFont | ncf | ) |
Set the naviChooseFont.
This font is used when drawing the text of the navigation buttons on top of the calendar.
| QFont ZeCalendar::getNaviChooseFont | ( | ) | const |
| void ZeCalendar::setShowButtons | ( | bool | s | ) |
Show the navigation button on top of the calndar.
| bool ZeCalendar::getShowButtons | ( | ) | const |
| void ZeCalendar::setSingleClickSelect | ( | bool | ) |
| bool ZeCalendar::getSingleClickSelect | ( | ) | const |
| void ZeCalendar::setDoubleClickSelect | ( | bool | ) |
| bool ZeCalendar::getDoubleClickSelect | ( | ) | const |
| void ZeCalendar::addHoliday | ( | QDate | d, | |
| bool | r | |||
| ) |
Allows to set holidays which will be shown differently according to the settings.
If r == true then the day and month part of the date will be evaluated as holiday for every year; if r == false then only this day will be shown as holiday.
e.g.:
addHoliday(QDate(2007,1,1), true); //the 1st January is a holiday every year
addHoliday(QDate(2006,4,29), false); //easter monday is different each year
| void ZeCalendar::loadTheme | ( | QString | themeFile | ) |
Can be used to load color and font properties from a file. Just call
zecalendar->setTheme(filename);
In a theme file each property has to be on one single line having the following syntax:
Colors
colorproperty name;red value,green value,blue value
Fonts
fontproperty name;font family,point size[,weight]
Please keep in mind that this is very strict - e.g. no additional whitespaces are supported.
| void ZeCalendar::dateSelected | ( | QDate | ) | [signal] |
Will be emitted when a user clicks or double clicks on a day depending on if singleClickSelect and/or doubleClickSelect is true.
| void ZeCalendar::weekSelected | ( | QDate | ) | [signal] |
Will be emitted when a user clicks on the leftmost columns showing the weeknumbers.
| void ZeCalendar::dateChangeClicked | ( | int | , | |
| QString | ||||
| ) | [signal] |
| void ZeCalendar::contentsMousePressEvent | ( | QMouseEvent * | event | ) | [private] |
| void ZeCalendar::contentsMouseDoubleClickEvent | ( | QMouseEvent * | event | ) | [private] |
| void ZeCalendar::contentsMouseMoveEvent | ( | QMouseEvent * | event | ) | [private] |
| void ZeCalendar::resizeEvent | ( | QResizeEvent * | e | ) | [private] |
| void ZeCalendar::leaveEvent | ( | QEvent * | e | ) | [private] |
int ZeCalendar::width [protected] |
int ZeCalendar::height [protected] |
int ZeCalendar::ws [protected] |
int ZeCalendar::ys [protected] |
int ZeCalendar::breite [protected] |
int ZeCalendar::hoehe [protected] |
int ZeCalendar::naviHeight [protected] |
holidayMap ZeCalendar::hm [protected] |
colorMap ZeCalendar::cM [protected] |
fontMap ZeCalendar::fM [protected] |
QStringList ZeCalendar::rhm [protected] |
QStringList ZeCalendar::dayNames [protected] |
QCanvas* ZeCalendar::canvas [protected] |
QDate ZeCalendar::actDate [protected] |
QPtrList<CalHeaderBox> ZeCalendar::headerList [protected] |
QPtrList<CalendarDayBox> ZeCalendar::dayBoxList [protected] |
QPtrList<CalWeekBox> ZeCalendar::weekBoxList [protected] |
QPtrList<CalLine> ZeCalendar::lineList [protected] |
QPtrList<PseudoButton> ZeCalendar::buttonList [protected] |
ActiveDayBox* ZeCalendar::activeDayBox [protected] |
bool ZeCalendar::autoUpdate [protected] |
QColor ZeCalendar::headerColFontColor [read, write] |
QColor ZeCalendar::headerColColor [read, write] |
QColor ZeCalendar::headerColBorderColor [read, write] |
QColor ZeCalendar::activeDayFontColor [read, write] |
QColor ZeCalendar::activeDayColor [read, write] |
QColor ZeCalendar::activeDayBorderColor [read, write] |
QColor ZeCalendar::weekDayFontColor [read, write] |
QColor ZeCalendar::weekDayColor [read, write] |
QColor ZeCalendar::saturdayFontColor [read, write] |
QColor ZeCalendar::saturdayColor [read, write] |
QColor ZeCalendar::sundayFontColor [read, write] |
QColor ZeCalendar::sundayColor [read, write] |
QColor ZeCalendar::headerRowFontColor [read, write] |
QColor ZeCalendar::headerRowColor [read, write] |
QColor ZeCalendar::headerRowBorderColor [read, write] |
QColor ZeCalendar::gridColor [read, write] |
QColor ZeCalendar::outsideDayFontColor [read, write] |
QColor ZeCalendar::outsideDayColor [read, write] |
QColor ZeCalendar::outsideWeekendDayColor [read, write] |
QColor ZeCalendar::holidayColor [read, write] |
QColor ZeCalendar::todayColor [read, write] |
QColor ZeCalendar::todayBorder [read, write] |
QColor ZeCalendar::naviChooseColor [read, write] |
QColor ZeCalendar::naviChooseFontColor [read, write] |
QColor ZeCalendar::naviChooseBorder [read, write] |
QColor ZeCalendar::todayFontColor [read, write] |
QFont ZeCalendar::todayFont [read, write] |
QFont ZeCalendar::activeDayFont [read, write] |
QFont ZeCalendar::dayFont [read, write] |
QFont ZeCalendar::headerRowFont [read, write] |
QFont ZeCalendar::headerColFont [read, write] |
QFont ZeCalendar::naviChooseFont [read, write] |
bool ZeCalendar::showButtons [read, write] |
Determines whether the navigationbuttons on top of the calendar shall be shown. You might want to provide other buttons for navigating - then simply call setShowButtons(false).
bool ZeCalendar::singleClickSelect [read, write] |
The signals dateSelected(QDate) or weekSelected(QDate) can be emitted on a double click (if doubleClickSelect == true) or single click (if singleClickSelect == true).
bool ZeCalendar::doubleClickSelect [read, write] |
1.5.1