From 0ef35c542585539bc7bc7f2f85478fbf02f3878a Mon Sep 17 00:00:00 2001 From: Michael Bohlender Date: Wed, 7 Dec 2016 17:57:20 +0100 Subject: move subject inline with mail sheet and add plaintext/html button --- components/package/contents/ui/SingleMailView.qml | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'components/package/contents') diff --git a/components/package/contents/ui/SingleMailView.qml b/components/package/contents/ui/SingleMailView.qml index d8b39900..a78173d1 100644 --- a/components/package/contents/ui/SingleMailView.qml +++ b/components/package/contents/ui/SingleMailView.qml @@ -18,6 +18,7 @@ import QtQuick 2.4 import QtQuick.Controls 1.3 +import QtQuick.Controls 2 as Controls2 import QtQuick.Layouts 1.1 import org.kde.kirigami 1.0 as Kirigami @@ -45,11 +46,29 @@ Rectangle { color: Kirigami.Theme.backgroundColor - Text { + Kirigami.Heading { anchors.centerIn: parent + width: parent.width - Kirigami.Units.gridUnit * 4.2 + text: "Some subject" color: Kirigami.Theme.textColor + level: 4 + font.italic: true + + } + + Controls2.Button { + anchors { + right: parent.right + rightMargin: Kirigami.Units.gridUnit * 0.2 + verticalCenter: parent.verticalCenter + } + text: "show plaintext" + + onClicked: { + text = text == "show plaintext" ? "show html" : "show plaintext" + } } Rectangle { -- cgit v1.2.3