Skip to content
Snippets Groups Projects
Unverified Commit b09536c4 authored by mpuchner's avatar mpuchner Committed by GitHub
Browse files

Merge pull request #1140 from mpuchner/issue-2510-Unreadable_text_in_error_dialogs

fix for issue 2510 "GUI: Unreadable text in error dialogs"
parents 931eeec9 76cde3d2
No related branches found
No related tags found
No related merge requests found
...@@ -45,7 +45,7 @@ namespace GUIHelpers { ...@@ -45,7 +45,7 @@ namespace GUIHelpers {
Error::~Error() noexcept = default; Error::~Error() noexcept = default;
const char* Error::what() const noexcept { const char* Error::what() const noexcept {
return message.toLatin1().data(); return m_messageAsLatin1.data();
} }
void information(QWidget* parent, const QString& title, const QString& text, void information(QWidget* parent, const QString& title, const QString& text,
......
...@@ -26,7 +26,7 @@ class RealDataItem; ...@@ -26,7 +26,7 @@ class RealDataItem;
namespace GUIHelpers { namespace GUIHelpers {
class Error : public std::exception { class Error : public std::exception {
public: public:
explicit Error(const QString& message) noexcept : message(message) {} explicit Error(const QString& message) noexcept : m_messageAsLatin1(message.toLatin1()) {}
virtual ~Error() noexcept; virtual ~Error() noexcept;
Error(const Error&) = default; Error(const Error&) = default;
...@@ -37,7 +37,7 @@ public: ...@@ -37,7 +37,7 @@ public:
const char* what() const noexcept override; const char* what() const noexcept override;
private: private:
QString message; QByteArray m_messageAsLatin1;
}; };
void information(QWidget* parent, const QString& title, const QString& text, void information(QWidget* parent, const QString& title, const QString& text,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment