KDEUI
#include <kdatewidget.h>

Signals | |
void | changed (const QDate &date) |
Public Member Functions | |
KDateWidget (const QDate &date, QWidget *parent=0) | |
KDateWidget (QWidget *parent=0) | |
virtual | ~KDateWidget () |
const KCalendarSystem * | calendar () const |
const QDate & | date () const |
bool | setCalendar (const QString &calendarType) |
bool | setCalendar (KCalendarSystem *calendar=0) |
bool | setCalendarSystem (KLocale::CalendarSystem calendarSystem) |
bool | setDate (const QDate &date) |
Protected Slots | |
void | slotDateChanged () |
Protected Member Functions | |
void | init (const QDate &date) |
Properties | |
QDate | date |
Detailed Description
A date selection widget.
This widget can be used to display or allow user selection of a date.

- See also
- KDatePicker
Definition at line 44 of file kdatewidget.h.
Constructor & Destructor Documentation
◆ KDateWidget() [1/2]
|
explicit |
Constructs a date selection widget.
Definition at line 59 of file kdatewidget.cpp.
◆ KDateWidget() [2/2]
|
explicit |
Constructs a date selection widget with the initial date set to date
.
Definition at line 64 of file kdatewidget.cpp.
◆ ~KDateWidget()
|
virtual |
Destructs the date selection widget.
Definition at line 99 of file kdatewidget.cpp.
Member Function Documentation
◆ calendar()
const KCalendarSystem * KDateWidget::calendar | ( | ) | const |
Returns the currently selected calendar system.
- Returns
- a KCalendarSystem object
Definition at line 162 of file kdatewidget.cpp.
◆ changed
|
signal |
Emitted whenever the date of the widget is changed, either with setDate() or via user selection.
◆ date()
const QDate & KDateWidget::date | ( | ) | const |
Returns the currently selected date.
Definition at line 136 of file kdatewidget.cpp.
◆ init()
|
protected |
Definition at line 70 of file kdatewidget.cpp.
◆ setCalendar() [1/2]
bool KDateWidget::setCalendar | ( | const QString & | calendarType | ) |
Changes the calendar system to use.
Will always use global locale.
- Parameters
-
calendarType the calendar system type to use
- Returns
true
if the calendar system was successfully set,false
otherwise
Definition at line 174 of file kdatewidget.cpp.
◆ setCalendar() [2/2]
bool KDateWidget::setCalendar | ( | KCalendarSystem * | calendar = 0 | ) |
Changes the calendar system to use.
Can use its own local locale if set.
- Parameters
-
calendar the calendar system object to use, defaults to global
- Returns
true
if the calendar system was successfully set,false
otherwise
Definition at line 167 of file kdatewidget.cpp.
◆ setCalendarSystem()
bool KDateWidget::setCalendarSystem | ( | KLocale::CalendarSystem | calendarSystem | ) |
- Since
- 4.6
Changes the calendar system to use. Will always use global locale.
- Parameters
-
calendarSystem the calendar system to use
- Returns
true
if the calendar system was successfully set,false
otherwise
Definition at line 179 of file kdatewidget.cpp.
◆ setDate()
bool KDateWidget::setDate | ( | const QDate & | date | ) |
Changes the selected date to date
.
- Returns
true
if the date was successfully set,false
otherwise
Definition at line 104 of file kdatewidget.cpp.
◆ slotDateChanged
|
protectedslot |
Definition at line 141 of file kdatewidget.cpp.
Property Documentation
◆ date
|
readwrite |
Definition at line 1 of file kdatewidget.h.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Feb 20 2023 00:00:00 by doxygen 1.9.6 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.