29 #include <libkcal/incidencebase.h>
34 #include <tqtooltip.h>
37 class TQDragEnterEvent;
38 class TQDragMoveEvent;
39 class TQDragLeaveEvent;
73 void maybeTip(
const TQPoint &pos );
125 static TQPair<TQDate,TQDate> matrixLimits(
const TQDate &month );
140 void updateView(
const TQDate &actdate );
151 const TQDate& getDate(
int offset );
156 TQString getHolidayLabel(
int offset );
161 void addSelectedDaysTo( DateList & );
167 void setSelectedDaysFrom(
const TQDate &start,
const TQDate &end );
172 void clearSelection();
186 bool isEndOfMonth()
const {
return mToday >= 27; }
189 void calendarIncidenceAdded(
Incidence *incidence );
190 void calendarIncidenceChanged(
Incidence *incidence );
191 void calendarIncidenceDeleted(
Incidence *incidence );
193 void setUpdateNeeded();
205 void recalculateToday();
210 void resourcesChanged();
234 void paintEvent( TQPaintEvent *ev );
236 void mousePressEvent( TQMouseEvent *e );
238 void mouseReleaseEvent( TQMouseEvent *e );
240 void mouseMoveEvent( TQMouseEvent *e );
242 void dragEnterEvent( TQDragEnterEvent * );
244 void dragMoveEvent( TQDragMoveEvent * );
246 void dragLeaveEvent( TQDragLeaveEvent * );
248 void dropEvent( TQDropEvent * );
250 void resizeEvent( TQResizeEvent * );
258 int getDayIndexFrom(
int x,
int y );
265 TQColor getShadedColor(
const TQColor &color );
269 static const int NUMDAYS;
278 TQString *mDayLabels;
290 TQMap<int,TQString> mHolidays;
301 static const int NOSELECTION;
313 int mTodayMarginWidth;
323 bool mPendingChanges;
small helper class to dynamically show tooltips inside the day matrix.
Replacement for kdpdatebuton.cpp that used 42 widgets for the day matrix to be displayed.
void selected(const KCal::DateList &daylist)
emitted if the user selects a block of days with the mouse by dragging a rectangle inside the matrix
void incidenceDropped(Incidence *incidence, const TQDate &dt)
emitted if the user has dropped an incidence (event or todo) inside the matrix
bool isTodayVisible() const
Is today visible in the view? Keep this in sync with the values today (below) can take.
void incidenceDroppedMove(Incidence *oldincidence, const TQDate &dt)
emitted if the user has dropped an event inside the matrix and chose to move it instead of copy
bool isBeginningOfMonth() const
If today is visible, then we can find out if today is near the beginning or the end of the month.