KMHeaders Class Reference
The widget that shows the contents of folders. More...
#include <kmheaders.h>
Collaboration diagram for KMHeaders:

Public Slots | |
void | selectMessage (QListViewItem *) |
void | highlightMessage (QListViewItem *) |
void | slotRMB () |
void | msgHeaderChanged (KMFolder *folder, int msgId) |
void | msgChanged () |
void | folderCleared () |
void | msgAdded (int) |
void | msgRemoved (int, QString, QString) |
void | nextMessage () |
void | selectNextMessage () |
void | prevMessage () |
void | selectPrevMessage () |
bool | nextUnreadMessage (bool acceptCurrent=false) |
bool | prevUnreadMessage () |
void | slotNoDrag () |
void | resetCurrentTime () |
void | slotExpandOrCollapseThread (bool expand) |
void | slotExpandOrCollapseAllThreads (bool expand) |
virtual void | ensureCurrentItemVisible () |
virtual void | setSelected (QListViewItem *item, bool selected) |
void | setSelectedByIndex (QValueList< int > items, bool selected) |
void | slotToggleColumn (int id, int mode=-1) |
void | setFolderInfoStatus () |
Signals | |
void | selected (KMMessage *) |
void | activated (KMMessage *) |
void | maybeDeleting () |
void | messageListUpdated () |
void | msgAddedToListView (QListViewItem *) |
Public Member Functions | |
KMHeaders (KMMainWidget *owner, QWidget *parent=0, const char *name=0) | |
virtual void | setFolder (KMFolder *, bool forceJumpToUnread=false) |
KMFolder * | folder (void) |
void | refreshNestedState (void) |
virtual void | setCurrentMsg (int msgId) |
QPtrList< QListViewItem > | currentThread () const |
virtual void | setThreadStatus (KMMsgStatus status, bool toggle=false) |
virtual void | setMsgRead (int msgId) |
virtual void | setMsgStatus (KMMsgStatus status, bool toggle=false) |
virtual void | deleteMsg () |
virtual void | applyFiltersOnMsg () |
virtual void | undo () |
virtual bool | canUndo () const |
virtual KMHeaderItem * | prepareMove (int *contentX, int *contentY) |
virtual void | finalizeMove (KMHeaderItem *item, int contentX, int contentY) |
virtual void | moveMsgToFolder (KMFolder *destination, bool askForConfirmation=true) |
virtual void | copyMsgToFolder (KMFolder *destination, KMMessage *aMsg=0) |
virtual void | clearSelectableAndAboutToBeDeleted (Q_UINT32 serNum) |
virtual KMMessageList * | selectedMsgs (bool toBeDeleted=false) |
QValueList< int > | selectedItems () |
int | indexOfGetMsg (void) const |
KMMainWidget * | owner (void) const |
const KPaintInfo * | paintInfo (void) const |
virtual void | readConfig (void) |
virtual void | readColorConfig (void) |
virtual void | reset (void) |
void | showNewMail () |
virtual KMMessage * | currentMsg () |
virtual KMHeaderItem * | currentHeaderItem () |
virtual int | currentItemIndex () |
virtual void | setCurrentItemByIndex (int msgIdx) |
void | setCurrentItemBySerialNum (unsigned long serialNum) |
virtual int | topItemIndex () |
virtual void | setTopItemByIndex (int aMsgIdx) |
virtual void | setNestedOverride (bool override) |
virtual void | setSubjectThreading (bool subjThreading) |
virtual void | setOpen (QListViewItem *, bool) |
NestingPolicy | getNestingPolicy () const |
bool | isThreaded () const |
virtual int | findUnread (bool findNext, int startAt=-1, bool onlyNew=false, bool acceptCurrent=false) |
void | highlightMessage (QListViewItem *, bool markitread) |
bool | eventFilter (QObject *o, QEvent *e) |
const KMMsgBase * | getMsgBaseForItem (const QListViewItem *item) const |
Static Public Member Functions | |
static QString | fancyDate (time_t otime) |
Public Attributes | |
QFont | dateFont |
bool | noRepaint |
Protected Slots | |
virtual void | moveSelectedToFolder (int menuId) |
virtual void | copySelectedToFolder (int menuId) |
virtual int | slotFilterMsg (KMMessage *) |
void | dirtySortOrder (int) |
void | rightButtonPressed (QListViewItem *, const QPoint &, int) |
Protected Member Functions | |
virtual bool | event (QEvent *e) |
virtual void | paintEmptyArea (QPainter *p, const QRect &rect) |
void | makeHeaderVisible () |
void | findUnreadAux (KMHeaderItem *&, bool &, bool, bool) |
virtual int | firstSelectedMsg () const |
virtual void | readFolderConfig (void) |
virtual void | writeFolderConfig (void) |
virtual void | writeConfig (void) |
virtual void | contentsMousePressEvent (QMouseEvent *) |
virtual void | contentsMouseReleaseEvent (QMouseEvent *e) |
virtual void | keyPressEvent (QKeyEvent *e) |
virtual void | setSorting (int column, bool ascending=true) |
void | contentsMouseMoveEvent (QMouseEvent *e) |
void | styleChange (QStyle &oldStyle) |
void | setStyleDependantFrameWidth () |
Static Protected Attributes | |
static QPixmap * | pixNew = 0 |
static QPixmap * | pixUns = 0 |
static QPixmap * | pixDel = 0 |
static QPixmap * | pixRead = 0 |
static QPixmap * | pixRep = 0 |
static QPixmap * | pixSent = 0 |
static QPixmap * | pixQueued = 0 |
static QPixmap * | pixFwd = 0 |
static QPixmap * | pixFlag = 0 |
static QPixmap * | pixWatched = 0 |
static QPixmap * | pixIgnored = 0 |
static QPixmap * | pixSpam = 0 |
static QPixmap * | pixHam = 0 |
static QPixmap * | pixFullySigned = 0 |
static QPixmap * | pixPartiallySigned = 0 |
static QPixmap * | pixUndefinedSigned = 0 |
static QPixmap * | pixFullyEncrypted = 0 |
static QPixmap * | pixPartiallyEncrypted = 0 |
static QPixmap * | pixUndefinedEncrypted = 0 |
static QPixmap * | pixFiller |
static QPixmap * | pixEncryptionProblematic = 0 |
static QPixmap * | pixSignatureProblematic = 0 |
static QPixmap * | pixAttachment = 0 |
static QPixmap * | pixReadFwd = 0 |
static QPixmap * | pixReadReplied = 0 |
static QPixmap * | pixReadFwdReplied = 0 |
static QPixmap * | pixTodo = 0 |
Friends | |
class | KMHeaderItem |
Detailed Description
The widget that shows the contents of folders.
Definition at line 38 of file kmheaders.h.
Member Function Documentation
|
A new folder has been selected update the list of headers shown To override the global settings for jumping to the first unread msg use
Definition at line 1220 of file kmheaders.cpp. References currentItemIndex(), folderCleared(), isThreaded(), makeHeaderVisible(), msgAdded(), msgChanged(), msgHeaderChanged(), msgRemoved(), readFolderConfig(), setCurrentMsg(), setFolderInfoStatus(), setTopItemByIndex(), topItemIndex(), and writeFolderConfig(). |
|
Return the folder whose message headers are being displayed.
Definition at line 55 of file kmheaders.h. |
|
read the config file and update nested state if necessary
Definition at line 1131 of file kmheaders.cpp. References isThreaded(), and reset(). |
|
Set current message. If id<0 then the first message is shown, if id>count() the last message is shown. Definition at line 2140 of file kmheaders.cpp. References makeHeaderVisible(), setFolderInfoStatus(), and setSelected(). Referenced by msgChanged(), nextUnreadMessage(), prevUnreadMessage(), reset(), setFolder(), and slotExpandOrCollapseThread(). |
|
Get a list of all items in the current thread.
Definition at line 1736 of file kmheaders.cpp. |
|
Set all messages in the current thread to status
Definition at line 1758 of file kmheaders.cpp. |
|
The following methods processes all selected messages.
Definition at line 1719 of file kmheaders.cpp. |
|
If destination is 0 then the messages are deleted, otherwise they are moved to this folder. The second parameter is usefull when the user has already confirmed the move/deletion. Definition at line 2023 of file kmheaders.cpp. References selectedMsgs(). Referenced by moveSelectedToFolder(). |
|
Messages are duplicated and added to given folder. If aMsg is set this one will be written to the destination folder. Definition at line 2122 of file kmheaders.cpp. References selectedMsgs(). Referenced by copySelectedToFolder(). |
|
Resets toBeDeleted and selectable status of all selected items.
Definition at line 2186 of file kmheaders.cpp. |
|
Returns list of selected messages. Mark the corresponding header items to be deleted, if specified. Definition at line 2203 of file kmheaders.cpp. Referenced by copyMsgToFolder(), and moveMsgToFolder(). |
|
Returns the index values of currently selected items.
Definition at line 2224 of file kmheaders.cpp. Referenced by msgChanged(). |
|
Returns index of message returned by last getMsg() call.
Definition at line 104 of file kmheaders.h. |
|
Returns pointer to owning main window.
Definition at line 107 of file kmheaders.h. |
|
PaintInfo pointer.
Definition at line 110 of file kmheaders.h. |
|
Read config options.
Definition at line 1030 of file kmheaders.cpp. References readColorConfig(), and slotToggleColumn(). |
|
Read color options and set palette.
Definition at line 991 of file kmheaders.cpp. Referenced by readConfig(). |
|
Refresh the list of message headers shown.
Definition at line 1112 of file kmheaders.cpp. References currentItemIndex(), setCurrentMsg(), setTopItemByIndex(), and topItemIndex(). Referenced by refreshNestedState(). |
|
Scroll to show new mail.
Definition at line 2903 of file kmheaders.cpp. References currentItemIndex(), and setTopItemByIndex(). |
|
Return the current message.
Definition at line 2852 of file kmheaders.cpp. References currentHeaderItem(). |
|
Return the current list view item.
Definition at line 2862 of file kmheaders.cpp. Referenced by currentItemIndex(), currentMsg(), findUnread(), msgRemoved(), and writeFolderConfig(). |
|
Return the index of the message corresponding to the current item.
Definition at line 2868 of file kmheaders.cpp. References currentHeaderItem(). Referenced by msgChanged(), reset(), setFolder(), showNewMail(), and writeFolderConfig(). |
|
Set the current item to the one corresponding to the given msg id.
Definition at line 2878 of file kmheaders.cpp. References setSelected(). |
|
Set the current item to the one corresponding to the given serial number (slow!).
Definition at line 3770 of file kmheaders.cpp. References setSelected(). |
|
Return the message id of the top most visible item.
Definition at line 2892 of file kmheaders.cpp. Referenced by msgChanged(), reset(), setFolder(), and writeFolderConfig(). |
|
Make the item corresponding to the message with the given id the top most visible item.
Definition at line 2916 of file kmheaders.cpp. Referenced by msgChanged(), reset(), setFolder(), and showNewMail(). |
|
Double force items to always be open.
Definition at line 2950 of file kmheaders.cpp. |
|
Returns true if the current header list is threaded.
Definition at line 146 of file kmheaders.h. Referenced by msgAdded(), msgRemoved(), readFolderConfig(), refreshNestedState(), setFolder(), setSelected(), and slotExpandOrCollapseThread(). |
|
Find next/prev unread message. Starts at currentItem() if startAt is unset. Definition at line 2360 of file kmheaders.cpp. References currentHeaderItem(), and findUnreadAux(). Referenced by nextUnreadMessage(), and prevUnreadMessage(). |
|
return a string relativ to the current time
|
|
gets the message represented by the item as a KMMsgBase.
Definition at line 2957 of file kmheaders.cpp. |
|
emitted when the list view item corresponding to this message has been selected
Referenced by msgChanged(). |
|
emitted when the list view item corresponding to this message has been double clicked
Referenced by selectMessage(). |
|
emitted when we might be about to delete messages
Referenced by msgRemoved(). |
|
emitted when the list of messages has been completely rebuilt
|
|
emitted after a new item has been fully built and added to the list view. We can't use KListView::itemAdded, as that is emitted from the ctor of the item, at which point the building of the item is not yet far enough along to update the quick search, which is what is connected to this signal. Referenced by msgAdded(). |
|
For when a list view item has been double clicked.
Definition at line 2549 of file kmheaders.cpp. References activated(). |
|
For when a list view item has been selected.
Definition at line 2771 of file kmheaders.cpp. |
|
For when righ mouse button is pressed.
Definition at line 2777 of file kmheaders.cpp. Referenced by rightButtonPressed(). |
|
Refresh list view item corresponding to the messae with the given id.
Definition at line 1707 of file kmheaders.cpp. Referenced by msgAdded(), and setFolder(). |
|
For when the list of messages in a folder has changed.
Definition at line 1351 of file kmheaders.cpp. References currentItemIndex(), selected(), selectedItems(), setCurrentMsg(), setSelectedByIndex(), setTopItemByIndex(), and topItemIndex(). Referenced by setFolder(). |
|
For when the folder has been cleared.
Definition at line 3037 of file kmheaders.cpp. Referenced by msgRemoved(), and setFolder(). |
|
For when the message with the given message id has been added to a folder.
Definition at line 1406 of file kmheaders.cpp. References dirtySortOrder(), isThreaded(), makeHeaderVisible(), msgAddedToListView(), msgHeaderChanged(), and setSelected(). Referenced by setFolder(). |
|
For when the message with the given id has been removed for a folder.
Definition at line 1591 of file kmheaders.cpp. References currentHeaderItem(), dirtySortOrder(), folderCleared(), isThreaded(), and maybeDeleting(). Referenced by setFolder(). |
|
Make the next header visible scrolling if necessary.
Definition at line 2252 of file kmheaders.cpp. References selectNextMessage(), and setSelected(). |
|
Same as nextMessage() but don't clear the current selection.
Definition at line 2264 of file kmheaders.cpp. Referenced by nextMessage(). |
|
Make the previous header visible scrolling if necessary.
Definition at line 2286 of file kmheaders.cpp. References selectPrevMessage(), and setSelected(). |
|
Same as prevMessage() but don't clear the current selection.
Definition at line 2298 of file kmheaders.cpp. Referenced by prevMessage(). |
|
Make the nextUnread message header visible scrolling if necessary, returning true if an unread message is found.
Definition at line 2437 of file kmheaders.cpp. References findUnread(), and setCurrentMsg(). |
|
Make the previous message header visible scrolling if necessary, returning true if an unread message is found.
Definition at line 2463 of file kmheaders.cpp. References findUnread(), and setCurrentMsg(). |
|
Don't show a drag cursor.
Definition at line 2483 of file kmheaders.cpp. |
|
timer function to set the current time regularly
Definition at line 2542 of file kmheaders.cpp. |
|
Expands (
Definition at line 1800 of file kmheaders.cpp. References isThreaded(), and setCurrentMsg(). |
|
Expands (
Definition at line 1817 of file kmheaders.cpp. |
|
Select an item and if it is the parent of a closed thread, also recursively select its children.
Definition at line 2155 of file kmheaders.cpp. References isThreaded(). Referenced by contentsMousePressEvent(), msgAdded(), nextMessage(), prevMessage(), rightButtonPressed(), setCurrentItemByIndex(), setCurrentItemBySerialNum(), and setCurrentMsg(). |
|
Select several items by message index and if they are the parent of a closed thread, also recursively select their children.
Definition at line 2175 of file kmheaders.cpp. Referenced by msgChanged(). |
|
switch a column with the given id (see KPaintInfo enum) 1 for activate, 0 for deactivate, -1 for toggle
Definition at line 852 of file kmheaders.cpp. References writeConfig(). Referenced by readConfig(). |
|
Provide information about number of messages in a folder.
Definition at line 1864 of file kmheaders.cpp. Referenced by setCurrentMsg(), and setFolder(). |
|
Look for color changes.
Definition at line 979 of file kmheaders.cpp. |
|
Overridden to support backing pixmap.
Definition at line 968 of file kmheaders.cpp. |
|
Ensure the current item is visible.
Definition at line 2490 of file kmheaders.cpp. Referenced by msgAdded(), setCurrentMsg(), and setFolder(). |
|
Auxillary method to findUnread.
Definition at line 2321 of file kmheaders.cpp. Referenced by findUnread(). |
|
Returns message index of first selected message of the messages where the message with the given id is in. This for finding the correct message that shall be the current message after move/delete of multiple messages. Definition at line 2239 of file kmheaders.cpp. |
|
Read per-folder config options and apply them.
Definition at line 1150 of file kmheaders.cpp. References isThreaded(). Referenced by setFolder(). |
|
Write per-folder config options.
Definition at line 1180 of file kmheaders.cpp. References currentHeaderItem(), currentItemIndex(), and topItemIndex(). Referenced by setFolder(), and setSorting(). |
|
Write global config options.
Definition at line 1202 of file kmheaders.cpp. Referenced by slotToggleColumn(). |
|
Handle shift and control selection.
Definition at line 2659 of file kmheaders.cpp. References setSelected(). |
|
Called when a header is clicked.
Definition at line 2964 of file kmheaders.cpp. References dirtySortOrder(), and writeFolderConfig(). |
|
To initiate a drag operation.
Definition at line 2733 of file kmheaders.cpp. |
|
reimplemented in order to update the frame width in case of a changed GUI style
Definition at line 1857 of file kmheaders.cpp. References setStyleDependantFrameWidth(). |
|
Set the width of the frame to a reasonable value for the current GUI style.
Definition at line 1842 of file kmheaders.cpp. Referenced by styleChange(). |
|
Move messages corresponding to the selected items to the folder corresponding to the given menuId.
Definition at line 1968 of file kmheaders.cpp. References moveMsgToFolder(). |
|
Same thing but copy.
Definition at line 2114 of file kmheaders.cpp. References copyMsgToFolder(). |
|
Apply the filter Rules to a single message.
Definition at line 1778 of file kmheaders.cpp. References KMFolder::unGetMsg(). |
|
dirties the sort order
Definition at line 3200 of file kmheaders.cpp. Referenced by msgAdded(), msgRemoved(), and setSorting(). |
|
show context menu
Definition at line 2646 of file kmheaders.cpp. References setSelected(), and slotRMB(). |
The documentation for this class was generated from the following files: