42 #ifndef QDATETIMEEDIT_H 43 #define QDATETIMEEDIT_H 45 #include <QtCore/qdatetime.h> 46 #include <QtCore/qvariant.h> 47 #include <QtGui/qabstractspinbox.h> 55 #ifndef QT_NO_DATETIMEEDIT 77 Sections displayedSections;
80 int currentSectionIndex;
88 SecondSection = 0x0004,
89 MinuteSection = 0x0008,
92 MonthSection = 0x0200,
94 TimeSections_Mask = AmPmSection|MSecSection|SecondSection|MinuteSection|HourSection,
95 DateSections_Mask = DaySection|MonthSection|YearSection
110 void clearMinimumDateTime();
111 void setMinimumDateTime(
const QDateTime &dt);
114 void clearMaximumDateTime();
115 void setMaximumDateTime(
const QDateTime &dt);
119 QDate minimumDate()
const;
120 void setMinimumDate(
const QDate &min);
121 void clearMinimumDate();
123 QDate maximumDate()
const;
124 void setMaximumDate(
const QDate &max);
125 void clearMaximumDate();
127 void setDateRange(
const QDate &min,
const QDate &max);
129 QTime minimumTime()
const;
130 void setMinimumTime(
const QTime &min);
131 void clearMinimumTime();
133 QTime maximumTime()
const;
134 void setMaximumTime(
const QTime &max);
135 void clearMaximumTime();
137 void setTimeRange(
const QTime &min,
const QTime &max);
139 Sections displayedSections()
const;
140 Section currentSection()
const;
142 void setCurrentSection(
Section section);
144 int currentSectionIndex()
const;
145 void setCurrentSectionIndex(
int index);
150 int sectionCount()
const;
152 void setSelectedSection(
Section section);
159 bool calendarPopup()
const;
160 void setCalendarPopup(
bool enable);
167 virtual void clear();
168 virtual void stepBy(
int steps);
172 void dateTimeChanged(
const QDateTime &date);
173 void timeChanged(
const QTime &date);
174 void dateChanged(
const QDate &date);
177 void setDateTime(
const QDateTime &dateTime);
178 void setDate(
const QDate &date);
179 void setTime(
const QTime &time);
183 #ifndef QT_NO_WHEELEVENT 224 #endif // QT_NO_DATETIMEEDIT 230 #endif // QDATETIMEEDIT_H The QVariant class acts like a union for the most common Qt data types.
void focusInEvent(QFocusEvent *event)
Reimplemented Function
virtual StepEnabled stepEnabled() const
Virtual function that determines whether stepping up and down is legal at any given time...
The QKeyEvent class describes a key event.
virtual void fixup(QString &input) const
This virtual function is called by the QAbstractSpinBox if the input is not validated to QValidator::...
#define QT_END_NAMESPACE
This macro expands to.
void initStyleOption(QStyleOptionSpinBox *option) const
Initialize option with the values from this QSpinBox.
#define Q_DECLARE_FLAGS(Flags, Enum)
The Q_DECLARE_FLAGS() macro expands to.
The QWheelEvent class contains parameters that describe a wheel event.
virtual void stepBy(int steps)
Virtual function that is called whenever the user triggers a step.
The QTimeEdit class provides a widget for editing times based on the QDateTimeEdit widget...
The QDateEdit class provides a widget for editing dates based on the QDateTimeEdit widget...
void keyPressEvent(QKeyEvent *event)
This function handles keyboard input.
void wheelEvent(QWheelEvent *event)
Reimplemented Function
The QDate class provides date functions.
#define Q_DISABLE_COPY(Class)
Disables the use of copy constructors and assignment operators for the given Class.
#define Q_PRIVATE_SLOT(d, signature)
The QString class provides a Unicode character string.
void mousePressEvent(QMouseEvent *event)
Reimplemented Function
The QDateTimeEdit class provides a widget for editing dates and times.
The QTime class provides clock time functions.
#define QT_BEGIN_NAMESPACE
This macro expands to.
#define Q_DECLARE_OPERATORS_FOR_FLAGS(Flags)
The Q_DECLARE_OPERATORS_FOR_FLAGS() macro declares global operator|() functions for Flags...
The QStyleOptionSpinBox class is used to describe the parameters necessary for drawing a spin box...
Type
This enum type defines the types of variable that a QVariant can contain.
The QAbstractSpinBox class provides a spinbox and a line edit to display values.
The QMouseEvent class contains parameters that describe a mouse event.
virtual QValidator::State validate(QString &input, int &pos) const
This virtual function is called by the QAbstractSpinBox to determine whether input is valid...
QSize sizeHint() const
Reimplemented Function
The QDateTime class provides date and time functions.
State
This enum type defines the states in which a validated string can exist.
void paintEvent(QPaintEvent *event)
Reimplemented Function
The QSize class defines the size of a two-dimensional object using integer point precision.
#define Q_DECLARE_PRIVATE(Class)
bool event(QEvent *event)
Reimplemented Function
virtual void clear()
Clears the lineedit of all text but prefix and suffix.
The QPaintEvent class contains event parameters for paint events.
The QEvent class is the base class of all event classes.
The QFocusEvent class contains event parameters for widget focus events.