From 0b946401283cdbe36f8fbda47d39b36f1a12817a Mon Sep 17 00:00:00 2001 From: Abdullah Tahiri Date: Sat, 18 Mar 2023 08:19:19 +0100 Subject: [PATCH] Notifications: Extend translated notification to include caption =============================================================== For translated notifications now the caption is included in the message, as the translation is already done, and this improves the semantics of existing messages. --- src/Gui/Notifications.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Gui/Notifications.h b/src/Gui/Notifications.h index d805f38bf0..8c55d514bf 100644 --- a/src/Gui/Notifications.h +++ b/src/Gui/Notifications.h @@ -153,7 +153,7 @@ inline void Gui::Notify(TNotifier && notifier, TCaption && caption, TMessage && if constexpr( type == Base::LogStyle::TranslatedNotification) { // trailing newline is necessary as this may be shown too in a console requiring them (depending on the configuration). - auto msg = message.append(QStringLiteral("\n")); // QString + auto msg = QStringLiteral("%1. %2\n").arg(caption).arg(message); // QString if constexpr( std::is_base_of_v::type>> ) { Base::Console().Send(notifier->getFullLabel(), msg.toUtf8());