aboutsummaryrefslogtreecommitdiffstats
path: root/qml
diff options
context:
space:
mode:
Diffstat (limited to 'qml')
-rw-r--r--qml/KeyInfoRow.qml24
-rw-r--r--qml/keydetails.qml49
2 files changed, 45 insertions, 28 deletions
diff --git a/qml/KeyInfoRow.qml b/qml/KeyInfoRow.qml
new file mode 100644
index 0000000..a1108dd
--- /dev/null
+++ b/qml/KeyInfoRow.qml
@@ -0,0 +1,24 @@
+import QtQuick 1.1
+
+Rectangle {
+
+ id: keyinforow
+
+ width: 200
+ height: 23
+
+ property variant key
+ property variant value
+
+ Text {
+ id: keyText
+ text: key
+ }
+
+ Text {
+ id: valueText
+ x: 50
+ y: 0
+ text: value
+ }
+}
diff --git a/qml/keydetails.qml b/qml/keydetails.qml
index e8a354c..141904f 100644
--- a/qml/keydetails.qml
+++ b/qml/keydetails.qml
@@ -15,6 +15,10 @@ Rectangle {
property alias tf1Text: tf1.text
property alias tf2Text: tf2.text
+// property keyid : ""
+// property email : ""
+// property name : ""
+
//color: "red"
Rectangle {
id: rectangle2
@@ -34,44 +38,33 @@ Rectangle {
color: "#978c79"
}
- Text {
- // qsTr() for internationalisation, like tr()
- x: 118
- y: 54
- text: qsTr("id:")
- }
- Text {
- x: 172
+ KeyInfoRow {
+ x: 119
y: 54
- text: id
- }
-
- Text {
- id: text1
- x: 118
- y: 75
- text: qsTr("email:")
+ // qsTr() for internationalisation, like tr()
+ key: qsTr("id:")
+ value: id
}
- Text {
- id: text2
- x: 172
+ KeyInfoRow {
+ x: 119
y: 75
- text: email
+ key: qsTr("email:")
+ value: email
}
- Text {
- id: text3
+ KeyInfoRow {
x: 119
y: 96
- text: qsTr("name:")
+ key: qsTr("name:")
+ value: name
}
- Text {
- id: text4
- x: 172
- y: 96
- text: name
+ KeyInfoRow {
+ x: 119
+ y: 117
+ key: qsTr("keysize")
+ value: key.size() / key.encyptionSize()
}