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

KDECore

  • sources
  • kde-4.12
  • kdelibs
  • kdecore
  • io
kmessage.h
Go to the documentation of this file.
1 /* This file is part of the KDE libraries
2  Copyright (C) 2006 MichaĆ«l Larouche <michael.larouche@kdemail.net>
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; version 2
7  of the License.
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 #ifndef KDECORE_KMESSAGE_H
20 #define KDECORE_KMESSAGE_H
21 
22 #include <kdecore_export.h>
23 
24 #include <QtCore/QString>
25 
26 class KMessageHandler;
49 namespace KMessage
50 {
51  enum MessageType
52  {
57  Error,
62  Information,
67  Warning,
72  Sorry,
77  Fatal
78  };
79 
88  KDECORE_EXPORT void message(KMessage::MessageType messageType, const QString &text, const QString &caption = QString());
89 
99  KDECORE_EXPORT void setMessageHandler(KMessageHandler *handler);
100 }
101 
113 class KDECORE_EXPORT KMessageHandler
114 {
115 public:
116  virtual ~KMessageHandler() {}
125  virtual void message(KMessage::MessageType type, const QString &text, const QString &caption) = 0;
126 };
127 
128 #endif
129 // kate: space-indent on; indent-width 4; encoding utf-8; replace-tabs on;
KMessage::message
void message(KMessage::MessageType messageType, const QString &text, const QString &caption=QString())
Display a long message of a certain type.
Definition: kmessage.cpp:92
KGlobal::caption
QString caption()
Returns a text for the window caption.
Definition: kglobal.cpp:291
KMessage::Information
Information message.
Definition: kmessage.h:62
kdecore_export.h
QString
KMessage::setMessageHandler
void setMessageHandler(KMessageHandler *handler)
Set the current KMessageHandler Note that this method takes ownership of the KMessageHandler.
Definition: kmessage.cpp:86
KMessage::Error
Error message.
Definition: kmessage.h:57
KMessage::Sorry
Sorry message.
Definition: kmessage.h:72
KMessage::MessageType
MessageType
Definition: kmessage.h:51
KMessage::Warning
Warning message.
Definition: kmessage.h:67
KMessageHandler
Abstract class for KMessage handler.
Definition: kmessage.h:113
KMessageHandler::~KMessageHandler
virtual ~KMessageHandler()
Definition: kmessage.h:116
KMessage::Fatal
Fatal message.
Definition: kmessage.h:77
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:47:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KDECore

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

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  • kjsembed
  •   WTF
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Nepomuk-Core
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

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