From 3bed8f40b299bb082ea2db6cec4964f31e3e5765 Mon Sep 17 00:00:00 2001 From: Alexander Lohnau Date: Sat, 25 Dec 2021 18:52:47 +0100 Subject: [PATCH] Show timezone keyword as part of runner syntax Relates to https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/1102 See https://i.imgur.com/SkP1oC8.png for how it will be displayed --- runners/datetime/datetimerunner.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/runners/datetime/datetimerunner.cpp b/runners/datetime/datetimerunner.cpp index e76dba3f3..64a49f87c 100644 --- a/runners/datetime/datetimerunner.cpp +++ b/runners/datetime/datetimerunner.cpp @@ -23,9 +23,11 @@ DateTimeRunner::DateTimeRunner(QObject *parent, const KPluginMetaData &metaData, setObjectName(QLatin1String("DataTimeRunner")); addSyntax(Plasma::RunnerSyntax(dateWord, i18n("Displays the current date"))); - addSyntax(Plasma::RunnerSyntax(dateWord + QLatin1String(" :q:"), i18n("Displays the current date in a given timezone"))); addSyntax(Plasma::RunnerSyntax(timeWord, i18n("Displays the current time"))); - addSyntax(Plasma::RunnerSyntax(timeWord + QLatin1String(" :q:"), i18n("Displays the current time in a given timezone"))); + addSyntax(Plasma::RunnerSyntax(dateWord + i18nc("The <> and space are part of the example query", " "), + i18n("Displays the current date in a given timezone"))); + addSyntax(Plasma::RunnerSyntax(timeWord + i18nc("The <> and space are part of the example query", " "), + i18n("Displays the current time in a given timezone"))); setTriggerWords({timeWord, dateWord}); } -- GitLab