33 mMessageOutputCreator = f;
38 return mMessageOutputCreator();
78 mMessage.
replace(
"<br>",
"\n" );
79 mMessage.
replace(
" ",
" " );
static void setMessageOutputCreator(MESSAGE_OUTPUT_CREATOR f)
sets function that will be used to create message output
MessageType
message can be in plain text or in html format
virtual void setTitle(const QString &title)=0
set title for the messages
static QgsMessageOutput * messageOutputConsole_()
static QgsMessageOutput * createMessageOutput()
function that returns new class derived from QgsMessageOutput (don't forget to delete it then if show...
QString tr(const char *sourceText, const char *disambiguation, int n)
QgsMessageOutput *(* MESSAGE_OUTPUT_CREATOR)()
Default implementation of message output interface.
virtual void setMessage(const QString &message, MessageType msgType) override
set message, it won't be displayed until
static void logMessage(const QString &message, const QString &tag=QString::null, MessageLevel level=WARNING)
add a message to the instance (and create it if necessary)
virtual void setMessage(const QString &message, MessageType msgType)=0
set message, it won't be displayed until
virtual void setTitle(const QString &title) override
set title for the messages
virtual void appendMessage(const QString &message) override
message to be appended to the current text
QgsMessageOutputConsole()
virtual void showMessage(bool blocking=true)=0
display the message to the user and deletes itself
QString & replace(int position, int n, QChar after)
Interface for showing messages from QGIS in GUI independent way.
virtual ~QgsMessageOutput()
virtual destructor
void destroyed()
signals that object will be destroyed and shouldn't be used anymore
virtual void showMessage(bool blocking=true) override
sends the message to the standard output