libkdepim Library API Documentation

klistviewsearchline_pimcopy.h

00001 /* This file is part of the KDE libraries 00002 Copyright (c) 2003 Scott Wheeler <wheeler@kde.org> 00003 00004 This library is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU Library General Public 00006 License version 2 as published by the Free Software Foundation. 00007 00008 This library is distributed in the hope that it will be useful, 00009 but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 Library General Public License for more details. 00012 00013 You should have received a copy of the GNU Library General Public License 00014 along with this library; see the file COPYING.LIB. If not, write to 00015 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00016 Boston, MA 02111-1307, USA. 00017 */ 00018 00019 #ifndef KLISTVIEWSEARCHLINE_H 00020 #define KLISTVIEWSEARCHLINE_H 00021 00022 #include <klineedit.h> 00023 00024 class KListView; 00025 class QListViewItem; 00026 00027 namespace KPIM { 00028 00037 class KListViewSearchLine : public KLineEdit 00038 { 00039 Q_OBJECT 00040 00041 public: 00042 00050 KListViewSearchLine(QWidget *parent = 0, KListView *listView = 0, const char *name = 0); 00051 00055 virtual ~KListViewSearchLine(); 00056 00062 bool caseSensitive() const; 00063 00070 QValueList<int> searchColumns() const; 00071 00078 bool keepParentsVisible() const; 00079 00085 KListView *listView() const; 00086 00087 public slots: 00092 virtual void updateSearch(const QString &s = QString::null); 00093 00099 void setCaseSensitive(bool cs); 00100 00111 void setKeepParentsVisible(bool v); 00112 00119 void setSearchColumns(const QValueList<int> &columns); 00120 00127 void setListView(KListView *lv); 00128 00129 protected: 00130 00136 virtual bool itemMatches(const QListViewItem *item, const QString &s) const; 00137 00143 virtual QPopupMenu *createPopupMenu(); 00144 00145 protected slots: 00146 void queueSearch(const QString &search); 00147 void activateSearch(); 00148 00149 private: 00150 00155 void checkItemParentsNotVisible(); 00156 00162 bool checkItemParentsVisible(QListViewItem *item); 00163 00164 private slots: 00165 void itemAdded(QListViewItem *item) const; 00166 void listViewDeleted(); 00167 void searchColumnsMenuActivated(int); 00168 00169 private: 00170 class KListViewSearchLinePrivate; 00171 KListViewSearchLinePrivate *d; 00172 }; 00173 } 00174 00175 #endif
KDE Logo
This file is part of the documentation for libkdepim Library Version 3.3.0.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Thu Oct 21 19:46:29 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003