• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

libkdepim

  • sources
  • kde-4.12
  • kdepim
  • libkdepim
  • addressline
kmailcompletion.h
Go to the documentation of this file.
1 /*
2  This file is part of libkdepim.
3 
4  Copyright (c) 2006 Christian Schaarschmidt <schaarsc@gmx.de>
5 
6  This library is free software; you can redistribute it and/or
7  modify it under the terms of the GNU Library General Public
8  License as published by the Free Software Foundation; either
9  version 2 of the License, or (at your option) any later version.
10 
11  This library is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  Library General Public License for more details.
15 
16  You should have received a copy of the GNU Library General Public License
17  along with this library; see the file COPYING.LIB. If not, write to
18  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19  Boston, MA 02110-1301, USA.
20 */
21 
22 #ifndef KDEPIM_KMAILCOMPLETION_H
23 #define KDEPIM_KMAILCOMPLETION_H
24 
25 #include <KCompletion>
26 
27 #include <QMap>
28 #include <QString>
29 #include <QStringList>
30 
31 namespace KPIM {
32 
39 class KMailCompletion : public KCompletion
40 {
41  Q_OBJECT
42 
43  public:
44  KMailCompletion();
45 
49  virtual void clear();
50 
57  QString makeCompletion( const QString &string );
58 
68  void addItemWithKeys( const QString &email, int weight, const QStringList *keyWords );
69 
74  virtual void postProcessMatches( QStringList *pMatches ) const;
75 
76  // We are not using allWeightedMatches() anywhere, therefore we don't need
77  // to override the other postProcessMatches() function
78  using KCompletion::postProcessMatches;
79 
80  private:
81  QMap< QString, QStringList > m_keyMap;
82 };
83 
84 }
85 
86 #endif
KPIM::KMailCompletion::addItemWithKeys
void addItemWithKeys(const QString &email, int weight, const QStringList *keyWords)
specify keywords for email.
Definition: kmailcompletion.cpp:79
KPIM::KMailCompletion::clear
virtual void clear()
clears internal keyword map and calls KCompletion::clear.
Definition: kmailcompletion.cpp:33
KCompletion
KPIM::KMailCompletion::postProcessMatches
virtual void postProcessMatches(QStringList *pMatches) const
use internal map to replace all keywords in pMatches with corresponding email addresses.
Definition: kmailcompletion.cpp:93
KPIM::KMailCompletion
KMailCompletion allows lookup of email addresses by keyword.
Definition: kmailcompletion.h:39
KPIM::KMailCompletion::makeCompletion
QString makeCompletion(const QString &string)
uses KCompletion::makeCompletion to find email addresses which starts with string.
Definition: kmailcompletion.cpp:39
KPIM::KMailCompletion::KMailCompletion
KMailCompletion()
Definition: kmailcompletion.cpp:28
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:58:03 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

libkdepim

Skip menu "libkdepim"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal