kdatepicker.cpp
89 if ( year != calendar->year(day) ) week += "*"; // show that this is a week from a different year
94 if(day < lastDay && day.daysTo(lastDay) < 7 && calendar->weekNumber(day) != calendar->weekNumber(lastDay))
248 kdDebug(298) << "KDatePicker::dateChangedSlot: date changed (" << date.year() << "/" << date.month() << "/" << date.day() << ")." << endl;
256 // calculate the item num in the week combo box; normalize selected day so as if 1.1. is the first day of the week
259 d->selectWeek->setCurrentItem((calendar->dayOfYear(date) + calendar->dayOfWeek(firstDay) - 2) / 7/*calendar->daysInWeek()*/);
349 date = calendar->addDays(date, week * 7/*calendar->daysOfWeek()*/ -calendar->dayOfWeek(date) + 1);
369 if ( (month = popup.exec(selectMonth->mapToGlobal(TQPoint(0, 0)), calendar->month(date) - 1)) == -1 ) return; // canceled
virtual bool setYMD(TQDate &date, int y, int m, int d) const=0
const TQDate & getDate() const KDE_DEPRECATED
Returns the selected date.
Definition: kdatepicker.cpp:274
virtual TQString yearString(const TQDate &pDate, bool bShort) const
KDatePicker(TQWidget *parent=0, TQDate=TQDate::currentDate(), const char *name=0)
The usual constructor.
Definition: kdatepicker.cpp:99
virtual int dayOfWeek(const TQDate &date) const=0
virtual int weekNumber(const TQDate &date, int *yearNum=0) const=0
virtual int dayOfYear(const TQDate &date) const=0
virtual TQDate addDays(const TQDate &date, int ndays) const=0
kndbgstream & endl(kndbgstream &s)
const KCalendarSystem * calendar() const
static TQFont generalFont()
virtual int day(const TQDate &date) const=0
virtual int month(const TQDate &date) const=0
kdbgstream kdDebug(int area=0)
virtual int monthsInYear(const TQDate &date) const=0
virtual TQDate addMonths(const TQDate &date, int nmonths) const=0
void dateSelected(TQDate)
This signal is emitted each time a day has been selected by clicking on the table (hitting a day in t...
virtual TQString monthName(int month, int year, bool shortName=false) const=0
virtual bool eventFilter(TQObject *o, TQEvent *e)
to catch move keyEvents when TQLineEdit has keyFocus
Definition: kdatepicker.cpp:221
void dateChanged(TQDate)
This signal is emitted each time the selected date is changed.
static int spacingHint()
Return the number of pixels you shall use between widgets inside a dialog according to the KDE standa...
Definition: kdialog.cpp:110
void dateEntered(TQDate)
This signal is emitted when enter is pressed and a VALID date has been entered before into the line e...
static TDELocale * locale()
virtual TQDate addYears(const TQDate &date, int nyears) const=0
void setCloseButton(bool enable)
By calling this method with enable = true, KDatePicker will show a little close-button in the upper b...
Definition: kdatepicker.cpp:519
virtual int daysInMonth(const TQDate &date) const=0
void tableClicked()
This signal is emitted when the day has been selected by clicking on it in the table.
virtual int year(const TQDate &date) const=0
void beep(const TQString &reason=TQString::null)