#include <ktimezonewidget.h>
Public Member Functions | |
KTimezoneWidget (TQWidget *parent=0, const char *name=0, KTimezones *db=0) | |
virtual | ~KTimezoneWidget () |
TQStringList | selection () const |
void | setSelected (const TQString &zone, bool selected) |
Public Member Functions inherited from TDEListView | |
TDEListView (TQWidget *parent=0, const char *name=0) | |
virtual | ~TDEListView () |
virtual void | setAcceptDrops (bool) |
virtual bool | isExecuteArea (const TQPoint &point) |
bool | isExecuteArea (int x) |
TQPtrList< TQListViewItem > | selectedItems () const |
TQPtrList< TQListViewItem > | selectedItems (bool includeHiddenItems) const |
void | moveItem (TQListViewItem *item, TQListViewItem *parent, TQListViewItem *after) |
TQListViewItem * | lastItem () const |
TQListViewItem * | lastChild () const |
KLineEdit * | renameLineEdit () const |
bool | itemsMovable () const |
bool | itemsRenameable () const |
bool | dragEnabled () const |
bool | autoOpen () const |
bool | isRenameable (int column) const |
bool | dropVisualizer () const |
int | tooltipColumn () const |
bool | createChildren () const TDE_DEPRECATED |
bool | dropHighlighter () const |
int | dropVisualizerWidth () const |
SelectionModeExt | selectionModeExt () const |
int | itemIndex (const TQListViewItem *item) const |
TQListViewItem * | itemAtIndex (int index) |
void | setFullWidth () TDE_DEPRECATED |
void | setFullWidth (bool fullWidth) |
bool | fullWidth () const |
virtual int | addColumn (const TQString &label, int width=-1) |
virtual int | addColumn (const TQIconSet &iconset, const TQString &label, int width=-1) |
virtual void | removeColumn (int index) |
void | setAlternateBackground (const TQColor &c) |
const TQColor & | alternateBackground () const |
void | saveLayout (TDEConfig *config, const TQString &group) const |
void | restoreLayout (TDEConfig *config, const TQString &group) |
virtual void | setSorting (int column, bool ascending=true) |
int | columnSorted (void) const |
bool | ascendingSort (void) const |
virtual void | takeItem (TQListViewItem *i) |
void | setShadeSortColumn (bool shadeSortColumn) |
bool | shadeSortColumn (void) const |
void | setUseSmallExecuteArea (bool enable) |
bool | useSmallExecuteArea () const |
void | setRenameSettings (const TDEListViewRenameSettings &renSett) |
Static Public Member Functions | |
static TQString | displayName (const KTimezone *zone) |
Additional Inherited Members | |
Public Types inherited from TDEListView | |
enum | SelectionModeExt { Single = TQListView::Single , Multi = TQListView::Multi , Extended = TQListView::Extended , NoSelection = TQListView::NoSelection , FileManager } |
Public Slots inherited from TDEListView | |
virtual void | rename (TQListViewItem *item, int c) |
void | setRenameable (int column, bool yesno=true) |
virtual void | setItemsMovable (bool b) |
virtual void | setItemsRenameable (bool b) |
virtual void | setDragEnabled (bool b) |
virtual void | setAutoOpen (bool b) |
virtual void | setDropVisualizer (bool b) |
void | setDropVisualizerWidth (int w) |
virtual void | setTooltipColumn (int column) |
virtual void | setDropHighlighter (bool b) |
virtual void | setCreateChildren (bool b) TDE_DEPRECATED |
void | setSelectionModeExt (SelectionModeExt mode) |
void | setTabOrderedRenaming (bool b) |
bool | tabOrderedRenaming () const |
virtual void | selectAll (bool select) |
Signals inherited from TDEListView | |
void | executed (TQListViewItem *item) |
void | executed (TQListViewItem *item, const TQPoint &pos, int c) |
void | dropped (TQDropEvent *e, TQListViewItem *after) |
void | dropped (TDEListView *list, TQDropEvent *e, TQListViewItem *after) |
void | dropped (TDEListView *list, TQDropEvent *e, TQListViewItem *parent, TQListViewItem *after) |
void | dropped (TQDropEvent *e, TQListViewItem *parent, TQListViewItem *after) |
void | moved () |
void | aboutToMove () |
void | moved (TQListViewItem *item, TQListViewItem *afterFirst, TQListViewItem *afterNow) |
void | moved (TQPtrList< TQListViewItem > &items, TQPtrList< TQListViewItem > &afterFirst, TQPtrList< TQListViewItem > &afterNow) |
void | itemRenamed (TQListViewItem *item, const TQString &str, int col) |
void | itemRenamed (TQListViewItem *item) |
void | menuShortCutPressed (TDEListView *list, TQListViewItem *item) |
void | contextMenu (TDEListView *l, TQListViewItem *i, const TQPoint &p) |
void | itemAdded (TQListViewItem *item) |
void | itemRemoved (TQListViewItem *item) |
void | renameNext (TQListViewItem *item, int col) |
void | renamePrev (TQListViewItem *item, int col) |
Protected Slots inherited from TDEListView | |
void | slotSettingsChanged (int) |
void | slotMouseButtonClicked (int btn, TQListViewItem *item, const TQPoint &pos, int c) |
void | doneEditing (TQListViewItem *item, int row) |
void | renameNextProxy (TQListViewItem *item, int col) |
void | renamePrevProxy (TQListViewItem *item, int col) |
void | cleanDropVisualizer () |
void | cleanItemHighlighter () |
void | emitContextMenu (TQListViewItem *, const TQPoint &, int) |
void | emitContextMenu (TDEListView *, TQListViewItem *) |
void | slotOnItem (TQListViewItem *item) |
void | slotOnViewport () |
void | slotAutoSelect () |
void | slotDragExpand () |
void | slotHeaderChanged () |
Protected Member Functions inherited from TDEListView | |
bool | below (const TQRect &rect, const TQPoint &p) |
bool | below (TQListViewItem *i, const TQPoint &p) |
virtual bool | event (TQEvent *) |
void | emitExecute (TQListViewItem *item, const TQPoint &pos, int c) |
virtual void | focusInEvent (TQFocusEvent *fe) |
virtual void | focusOutEvent (TQFocusEvent *fe) |
virtual void | leaveEvent (TQEvent *e) |
virtual TQString | tooltip (TQListViewItem *item, int column) const |
virtual bool | showTooltip (TQListViewItem *item, const TQPoint &pos, int column) const |
virtual void | contentsDragMoveEvent (TQDragMoveEvent *event) |
virtual void | contentsMousePressEvent (TQMouseEvent *e) |
virtual void | contentsMouseMoveEvent (TQMouseEvent *e) |
virtual void | contentsMouseDoubleClickEvent (TQMouseEvent *e) |
virtual void | contentsDragLeaveEvent (TQDragLeaveEvent *event) |
virtual void | contentsMouseReleaseEvent (TQMouseEvent *) |
virtual void | contentsDropEvent (TQDropEvent *) |
virtual void | contentsDragEnterEvent (TQDragEnterEvent *) |
virtual TQDragObject * | dragObject () |
virtual bool | acceptDrag (TQDropEvent *event) const |
virtual TQRect | drawDropVisualizer (TQPainter *p, TQListViewItem *parent, TQListViewItem *after) |
virtual TQRect | drawItemHighlighter (TQPainter *painter, TQListViewItem *item) |
virtual void | startDrag () |
virtual void | keyPressEvent (TQKeyEvent *) |
virtual void | viewportPaintEvent (TQPaintEvent *) |
void | activateAutomaticSelection () |
void | deactivateAutomaticSelection () |
bool | automaticSelection () const |
virtual void | viewportResizeEvent (TQResizeEvent *e) |
void | disableAutoSelection () |
void | resetAutoSelection () |
void | resetKeyboardSelectionOperation () |
void | setActiveMultiSelectItem (TQListViewItem *item) |
void | doubleClicked (TQListViewItem *item, const TQPoint &pos, int c) |
virtual void | movableDropEvent (TQListViewItem *parent, TQListViewItem *afterme) |
virtual void | findDrop (const TQPoint &pos, TQListViewItem *&parent, TQListViewItem *&after) |
void | fileManagerKeyPressEvent (TQKeyEvent *) |
int | depthToPixels (int depth) |
virtual void | virtual_hook (int id, void *data) |
Detailed Description
A timezone selection widget.
Detail:
This class provides for selection of one or more timezones.
Example:
To use the class to implement a system timezone selection feature:
To use the class to implement a multiple-choice custom timezone selector:
- Since
- 3.5
Definition at line 59 of file ktimezonewidget.h.
Constructor & Destructor Documentation
◆ KTimezoneWidget()
KTimezoneWidget::KTimezoneWidget | ( | TQWidget * | parent = 0 , |
const char * | name = 0 , |
||
KTimezones * | db = 0 |
||
) |
Constructs a timezone selection widget.
- Parameters
-
parent The parent widget. name The name of this widget. db The timezone database to use. If 0, the system timezone database is used.
Definition at line 36 of file ktimezonewidget.cpp.
◆ ~KTimezoneWidget()
|
virtual |
Destroys the timezone selection widget.
Definition at line 80 of file ktimezonewidget.cpp.
Member Function Documentation
◆ displayName()
|
static |
Format a timezone name in a standardised manner.
The returned value is transformed via an i18n lookup, so the caller should previously have set the timezone catalogue:
- Returns
- formatted timezone name.
Definition at line 86 of file ktimezonewidget.cpp.
◆ selection()
TQStringList KTimezoneWidget::selection | ( | ) | const |
Returns the currently selected timezones.
See TQListView::selectionChanged().
- Returns
- a list of timezone names, in the format used by the database supplied to the KTimezoneWidget() constructor.
Definition at line 91 of file ktimezonewidget.cpp.
◆ setSelected()
void KTimezoneWidget::setSelected | ( | const TQString & | zone, |
bool | selected | ||
) |
Select/deselect the named timezone.
- Parameters
-
zone The timezone name to be selected. Ignored if not recognised! selected The new selection state.
Definition at line 108 of file ktimezonewidget.cpp.
The documentation for this class was generated from the following files: