digiKam
Digikam::DDatePickerPopup Class Reference

This menu helps the user to select a date quickly. More...

+ Inheritance diagram for Digikam::DDatePickerPopup:

Public Types

enum  ItemFlag { NoDate = 1 , DatePicker = 2 , Words = 4 }
 

Signals

void dateChanged (const QDate &)
 

Public Member Functions

DDatePickerdatePicker () const
 
 DDatePickerPopup (Items items, const QDate &date=QDate::currentDate(), QWidget *const parent=nullptr)
 
int items () const
 
void setDate (const QDate &date)
 
 ~DDatePickerPopup () override
 

Protected Slots

void slotDateChanged (const QDate &)
 
void slotNextMonth ()
 
void slotNextWeek ()
 
void slotNoDate ()
 
void slotPrevFriday ()
 
void slotPrevMonday ()
 
void slotPrevMonth ()
 
void slotPrevWeek ()
 
void slotToday ()
 
void slotTomorrow ()
 
void slotYesterday ()
 

Detailed Description

This menu helps the user to select a date quickly.

This menu helps the user to select a date quickly. It offers various ways of selecting, e.g. with a DDatePicker or with words like "Tomorrow".

The available items are:

  • NoDate: A menu-item with "No Date". If chosen, the datepicker will emit a null QDate.
  • DatePicker: Show a DDatePicker-widget.
  • Words: Show items like "Today", "Tomorrow" or "Next Week".

When supplying multiple items, separate each item with a bitwise OR.

Member Enumeration Documentation

◆ ItemFlag

Enumerator
NoDate 
DatePicker 
Words 

Constructor & Destructor Documentation

◆ DDatePickerPopup()

Digikam::DDatePickerPopup::DDatePickerPopup ( Items  items,
const QDate &  date = QDate::currentDate(),
QWidget *const  parent = nullptr 
)
explicit

A constructor for the DDatePickerPopup.

Parameters
itemsList of all desirable items, separated with a bitwise OR.
dateInitial date of datepicker-widget.
parentThe object's parent.

References Digikam::DDatePicker::dateEntered(), Digikam::DDatePicker::dateSelected(), items(), and slotDateChanged().

◆ ~DDatePickerPopup()

Digikam::DDatePickerPopup::~DDatePickerPopup ( )
override

Member Function Documentation

◆ dateChanged

void Digikam::DDatePickerPopup::dateChanged ( const QDate &  )
signal

This signal emits the new date (selected with datepicker or other menu-items).

Referenced by slotDateChanged(), slotNextMonth(), slotNextWeek(), slotNoDate(), slotPrevFriday(), slotPrevMonday(), slotPrevMonth(), slotPrevWeek(), slotToday(), slotTomorrow(), and slotYesterday().

◆ datePicker()

DDatePicker * Digikam::DDatePickerPopup::datePicker ( ) const
Returns
A pointer to the private variable mDatePicker, an instance of DDatePicker.

◆ items()

int Digikam::DDatePickerPopup::items ( ) const
Returns
Returns the bitwise result of the active items in the popup.

Referenced by DDatePickerPopup().

◆ setDate()

void Digikam::DDatePickerPopup::setDate ( const QDate &  date)

◆ slotDateChanged

void Digikam::DDatePickerPopup::slotDateChanged ( const QDate &  date)
protectedslot

References dateChanged().

Referenced by DDatePickerPopup().

◆ slotNextMonth

void Digikam::DDatePickerPopup::slotNextMonth ( )
protectedslot

References dateChanged().

◆ slotNextWeek

void Digikam::DDatePickerPopup::slotNextWeek ( )
protectedslot

References dateChanged().

◆ slotNoDate

void Digikam::DDatePickerPopup::slotNoDate ( )
protectedslot

References dateChanged().

◆ slotPrevFriday

void Digikam::DDatePickerPopup::slotPrevFriday ( )
protectedslot

References dateChanged().

◆ slotPrevMonday

void Digikam::DDatePickerPopup::slotPrevMonday ( )
protectedslot

References dateChanged().

◆ slotPrevMonth

void Digikam::DDatePickerPopup::slotPrevMonth ( )
protectedslot

References dateChanged().

◆ slotPrevWeek

void Digikam::DDatePickerPopup::slotPrevWeek ( )
protectedslot

References dateChanged().

◆ slotToday

void Digikam::DDatePickerPopup::slotToday ( )
protectedslot

References dateChanged().

◆ slotTomorrow

void Digikam::DDatePickerPopup::slotTomorrow ( )
protectedslot

References dateChanged().

◆ slotYesterday

void Digikam::DDatePickerPopup::slotYesterday ( )
protectedslot

References dateChanged().


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