QGIS API Documentation  2.6.0-Brighton
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Protected Member Functions | Properties | List of all members
QgsDateTimeEdit Class Reference

The QgsDateTimeEdit class is a QDateTimeEdit with the capability of setting/reading null date/times. More...

#include <qgsdatetimeedit.h>

Public Member Functions

 QgsDateTimeEdit (QWidget *parent=0)
void setAllowNull (bool allowNull)
 determines if the widget allows setting null date/time.
bool allowNull () const
void setDateTime (const QDateTime &dateTime)
 setDateTime set the date time in the widget and handles null date times.
QDateTime dateTime () const
 dateTime returns the date time which can eventually be a null date/time
virtual void clear ()
 Set the current date as NULL.

Protected Member Functions

virtual void resizeEvent (QResizeEvent *event)
void mousePressEvent (QMouseEvent *event)

Properties

bool allowNull

Detailed Description

The QgsDateTimeEdit class is a QDateTimeEdit with the capability of setting/reading null date/times.

Constructor & Destructor Documentation

QgsDateTimeEdit::QgsDateTimeEdit ( QWidget *  parent = 0)
explicit

Member Function Documentation

bool QgsDateTimeEdit::allowNull ( ) const
inline
void QgsDateTimeEdit::clear ( )
virtual

Set the current date as NULL.

Note
if the widget is not configured to accept NULL dates, this will have no effect
QDateTime QgsDateTimeEdit::dateTime ( ) const

dateTime returns the date time which can eventually be a null date/time

Note
since QDateTimeEdit::dateTime() is not virtual, dateTime must be called for QgsDateTimeEdit.
void QgsDateTimeEdit::mousePressEvent ( QMouseEvent *  event)
protected
void QgsDateTimeEdit::resizeEvent ( QResizeEvent *  event)
protectedvirtual
void QgsDateTimeEdit::setAllowNull ( bool  allowNull)

determines if the widget allows setting null date/time.

void QgsDateTimeEdit::setDateTime ( const QDateTime &  dateTime)

setDateTime set the date time in the widget and handles null date times.

Note
since QDateTimeEdit::setDateTime() is not virtual, setDateTime must be called for QgsDateTimeEdit.

Property Documentation

bool QgsDateTimeEdit::allowNull
readwrite

The documentation for this class was generated from the following files: