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

messageviewer

  • sources
  • kde-4.12
  • kdepim
  • messageviewer
  • findbar
findbarbase.h
Go to the documentation of this file.
1 /* Copyright (C) 2010 Torgny Nyblom <nyblom@kde.org>
2  * Copyright (C) 2010,2011, 2012, 2013 Laurent Montel <montel@kde.org>
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Library General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * Library General Public License for more details.
13  *
14  * You should have received a copy of the GNU Library General Public License
15  * along with this library; see the file COPYING.LIB. If not, write to
16  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17  * Boston, MA 02110-1301, USA.
18  */
19 
20 #ifndef FINDBARBASE_H
21 #define FINDBARBASE_H
22 
23 #include <QWidget>
24 
25 class QAction;
26 class KLineEdit;
27 class QPushButton;
28 class QMenu;
29 
30 namespace MessageViewer
31 {
32 class FindBarBase : public QWidget
33 {
34  Q_OBJECT
35 public:
36  explicit FindBarBase( QWidget * parent = 0 );
37  virtual ~FindBarBase();
38 
39  QString text() const;
40  void setText( const QString&text );
41  void focusAndSetCursor();
42 
43 protected:
44  virtual bool event(QEvent* e);
45  virtual void clearSelections();
46  virtual void updateHighLight(bool);
47  virtual void searchText( bool backward, bool isAutoSearch );
48  virtual void updateSensitivity( bool );
49 
50  void setFoundMatch( bool match );
51  void messageInfo( bool backward, bool isAutoSearch, bool found );
52  QMenu *optionsMenu();
53 
54 public slots:
55  void findNext();
56  void findPrev();
57  void autoSearch( const QString& str );
58  void slotSearchText( bool backward = false, bool isAutoSearch = true );
59  void closeBar();
60 
61 private slots:
62  void caseSensitivityChanged(bool);
63  void slotHighlightAllChanged(bool);
64  void slotClearSearch();
65 
66 protected:
67  QString mPositiveBackground;
68  QString mNegativeBackground;
69  QString mLastSearchStr;
70  KLineEdit *mSearch;
71  QAction *mCaseSensitiveAct;
72 
73  QPushButton *mFindPrevBtn;
74  QPushButton *mFindNextBtn;
75  QMenu *mOptionsMenu;
76 };
77 
78 }
79 
80 #endif /* FINDBARBASE_H */
81 
MessageViewer::FindBarBase::updateSensitivity
virtual void updateSensitivity(bool)
Definition: findbarbase.cpp:199
MessageViewer::FindBarBase::searchText
virtual void searchText(bool backward, bool isAutoSearch)
Definition: findbarbase.cpp:177
MessageViewer::FindBarBase
Definition: findbarbase.h:32
MessageViewer::FindBarBase::clearSelections
virtual void clearSelections()
Definition: findbarbase.cpp:212
MessageViewer::FindBarBase::autoSearch
void autoSearch(const QString &str)
Definition: findbarbase.cpp:127
MessageViewer::FindBarBase::setFoundMatch
void setFoundMatch(bool match)
Definition: findbarbase.cpp:155
MessageViewer::FindBarBase::closeBar
void closeBar()
Definition: findbarbase.cpp:217
MessageViewer::FindBarBase::findPrev
void findPrev()
Definition: findbarbase.cpp:189
MessageViewer::FindBarBase::mLastSearchStr
QString mLastSearchStr
Definition: findbarbase.h:69
QWidget
MessageViewer::FindBarBase::slotSearchText
void slotSearchText(bool backward=false, bool isAutoSearch=true)
Definition: findbarbase.cpp:138
MessageViewer::FindBarBase::messageInfo
void messageInfo(bool backward, bool isAutoSearch, bool found)
Definition: findbarbase.cpp:143
MessageViewer::FindBarBase::event
virtual bool event(QEvent *e)
Definition: findbarbase.cpp:225
MessageViewer::FindBarBase::~FindBarBase
virtual ~FindBarBase()
Definition: findbarbase.cpp:96
MessageViewer::FindBarBase::mNegativeBackground
QString mNegativeBackground
Definition: findbarbase.h:68
MessageViewer::FindBarBase::FindBarBase
FindBarBase(QWidget *parent=0)
Definition: findbarbase.cpp:39
MessageViewer::FindBarBase::mFindPrevBtn
QPushButton * mFindPrevBtn
Definition: findbarbase.h:73
MessageViewer::FindBarBase::mPositiveBackground
QString mPositiveBackground
Definition: findbarbase.h:67
MessageViewer::FindBarBase::mFindNextBtn
QPushButton * mFindNextBtn
Definition: findbarbase.h:74
MessageViewer::FindBarBase::setText
void setText(const QString &text)
Definition: findbarbase.cpp:110
MessageViewer::FindBarBase::mOptionsMenu
QMenu * mOptionsMenu
Definition: findbarbase.h:75
MessageViewer::FindBarBase::mCaseSensitiveAct
QAction * mCaseSensitiveAct
Definition: findbarbase.h:71
MessageViewer::FindBarBase::mSearch
KLineEdit * mSearch
Definition: findbarbase.h:70
MessageViewer::FindBarBase::findNext
void findNext()
Definition: findbarbase.cpp:184
MessageViewer::FindBarBase::optionsMenu
QMenu * optionsMenu()
Definition: findbarbase.cpp:100
MessageViewer::FindBarBase::focusAndSetCursor
void focusAndSetCursor()
Definition: findbarbase.cpp:115
MessageViewer::FindBarBase::text
QString text() const
Definition: findbarbase.cpp:105
MessageViewer::FindBarBase::updateHighLight
virtual void updateHighLight(bool)
Definition: findbarbase.cpp:208
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:57 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

messageviewer

Skip menu "messageviewer"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

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