Skip to content
Snippets Groups Projects
Commit 581e48fe authored by andrey.daragan's avatar andrey.daragan
Browse files

[*] Сhanged the toolbar design of the main application window.

parent e1f88da0
No related branches found
No related tags found
No related merge requests found
...@@ -6,24 +6,35 @@ import QtQuick.Controls.Styles 1.4 ...@@ -6,24 +6,35 @@ import QtQuick.Controls.Styles 1.4
Page { Page {
id: dapUiQmlScreenDashboard id: dapUiQmlScreenDashboard
title: qsTr("General") title: qsTr("General")
Rectangle {
id: rectangleTabs
anchors.top: parent.top
anchors.bottom: parent.bottom
anchors.left: parent.left
width: 70
color: "#353841"
ListView { ListView {
id: listViewTabs id: listViewTabs
anchors.top: parent.top anchors.fill: parent
anchors.bottom: parent.bottom
anchors.left: parent.left
width: dapUiQmlScreenDashboard.width/5
model: listModelTabs model: listModelTabs
ListModel { ListModel {
id: listModelTabs id: listModelTabs
ListElement { ListElement {
name: qsTr("Dashboard") name: qsTr("Home")
page: "DapUiQmlScreenDialog.qml" page: "DapUiQmlScreenDialog.qml"
source: "qrc:/Resources/Icons/home.png"
}
ListElement {
name: qsTr("Settings")
page: "DapQmlScreenAbout.qml"
source: "qrc:/Resources/Icons/settings.png"
} }
ListElement { ListElement {
name: qsTr("About") name: qsTr("About")
page: "DapQmlScreenAbout.qml" page: "DapQmlScreenAbout.qml"
source: "qrc:/Resources/Icons/about.png"
} }
} }
...@@ -33,22 +44,25 @@ Page { ...@@ -33,22 +44,25 @@ Page {
Component { Component {
id: componentTab id: componentTab
Item { Item {
id: componentItem
width: listViewTabs.width width: listViewTabs.width
height: textTab.height + 10 height: 64
Rectangle { Column
id: canvas {
border.color: "whitesmoke" anchors.centerIn: parent
color: "Transparent" Image
anchors.fill: parent {
Row { id: imageMenu
anchors.margins: 5 source: model.source
anchors.fill: parent height: 36
width: 36
Text anchors.horizontalCenter: parent.horizontalCenter
{ }
id: textTab Text
text: qsTr(name) {
} text: qsTr(name)
color: "#BBBEBF"
anchors.horizontalCenter: parent.horizontalCenter
} }
} }
...@@ -63,11 +77,26 @@ Page { ...@@ -63,11 +77,26 @@ Page {
} }
} }
highlight: Rectangle { color: "aliceblue"; radius: 1 } // highlight: Rectangle { color: "aliceblue"; radius: 1 }
highlight:
Component
{
Rectangle {
id: rectangleMenu
color: "#121B28"
Rectangle
{
height: rectangleMenu.height
width: 4
color: "#EE5321"
}
}
}
focus: true focus: true
} }
}
Rectangle { Rectangle {
anchors.left: listViewTabs.right anchors.left: rectangleTabs.right
anchors.top: parent.top anchors.top: parent.top
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.right: parent.right anchors.right: parent.right
......
import QtQuick 2.11 import QtQuick 2.11
import QtQuick.Controls 1.4 import QtQuick.Controls 1.4
import QtQuick.Controls 2.2 import QtQuick.Controls 2.2
import KelvinDashboard 1.0
Page { Page {
id: dapUiQmlWidgetChainNodeLogs id: dapUiQmlWidgetChainNodeLogs
title: "Logs" title: "Logs"
TableView {
id: tableViewLogs ListModel {
anchors.top: parent.top id: dataModel
anchors.bottom: parent.bottom
anchors.left: parent.left ListElement {
anchors.right: parent.right name: "Apple"
cost: 2.45
// type: ":/Resources/Icons/dialogquestion.png"
TableViewColumn { }
id: columnDate ListElement {
role: "date" name: "Orange"
title: "Date" cost: 3.25
} // type: ":/Resources/Icons/dialogwarning.png"
TableViewColumn { }
id: columnTime ListElement {
role: "time" name: "Banana"
title: "Time" cost: 1.95
} // type: ":/Resources/Icons/dialoinformation.png"
TableViewColumn { }
id: columnFile
role: "file"
title: "File"
}
TableViewColumn {
id: columnMessage
role: "Message"
title: "Message"
} }
}
TabView
{
id: tabViewLogs
anchors.top: parent.top
anchors.bottom: parent.bottom
anchors.left: parent.left
anchors.right: parent.right
Repeater {
anchors.fill: parent
model: dapUiQmlWidgetModel
delegate:
Tab{
title: qsTr(name)
TableView {
id: tableViewLogs
model: dataModel
clip: true
TableViewColumn {
id: columnType
role: "type"
title: "Type"
delegate:
Item
{
height: parent.height
width: parent.height
Rectangle {
anchors.fill: parent
color: "transparent"
Image {
id: names
height: parent.height
width: parent.height
// source: model.type
anchors.centerIn: parent
}
}
}
}
TableViewColumn {
id: columnDate
role: "name"
title: "Date"
}
TableViewColumn {
id: columnTime
role: "cost"
title: "Time"
}
TableViewColumn {
id: columnFile
role: "file"
title: "File"
}
TableViewColumn {
id: columnMessage
role: "Message"
title: "Message"
}
itemDelegate: Item {
Text {
anchors.centerIn: parent
renderType: Text.NativeRendering
text: styleData.value
}
}
headerDelegate: Rectangle {
height: 20
color: "#29333f"
Text {
text: styleData.value
color: "#FFF"
width: parent.width
height: parent.height
font.pointSize: 24
minimumPointSize: 3
font.family: "Roboto"
fontSizeMode: Text.Fit
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
}
}
}
}
}
}
} }
...@@ -91,3 +91,5 @@ include (../DapRPCProtocol/DapRPCProtocol.pri) ...@@ -91,3 +91,5 @@ include (../DapRPCProtocol/DapRPCProtocol.pri)
INCLUDEPATH += $$_PRO_FILE_PWD_/../libKelvinDashboardCommon/ INCLUDEPATH += $$_PRO_FILE_PWD_/../libKelvinDashboardCommon/
$$_PRO_FILE_PWD_/../DapRPCProtocol/ $$_PRO_FILE_PWD_/../DapRPCProtocol/
$$_PRO_FILE_PWD_/../libdap-qt/ $$_PRO_FILE_PWD_/../libdap-qt/
DISTFILES +=
KelvinDashboardGUI/Resources/Icons/about.png

1.36 KiB

KelvinDashboardGUI/Resources/Icons/home.png

344 B

KelvinDashboardGUI/Resources/Icons/settings.png

1.3 KiB

...@@ -74,7 +74,7 @@ ApplicationWindow { ...@@ -74,7 +74,7 @@ ApplicationWindow {
scale: 0.7 scale: 0.7
visible: false visible: false
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.right: labelBalance.left anchors.right: imageDollars.left
} }
Image { Image {
...@@ -83,12 +83,23 @@ ApplicationWindow { ...@@ -83,12 +83,23 @@ ApplicationWindow {
scale: 0.7 scale: 0.7
visible: true visible: true
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.right: labelBalance.left anchors.right: imageDollars.left
}
Image {
id: imageDollars
source: "qrc:/Resources/Icons/dollar.png"
scale: 0.7
visible: true
anchors.verticalCenter: parent.verticalCenter
anchors.right: labelBalance.right
anchors.leftMargin: 5
anchors.rightMargin: 5
} }
Text { Text {
id: labelBalance id: labelBalance
text: "$0" text: "0"
font.pointSize: 16 font.pointSize: 16
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.right: parent.right anchors.right: parent.right
......
...@@ -22,5 +22,8 @@ ...@@ -22,5 +22,8 @@
<file>DapUiQmlWidgetChainNodeLogs.ui.qml</file> <file>DapUiQmlWidgetChainNodeLogs.ui.qml</file>
<file>Resources/Icons/add.png</file> <file>Resources/Icons/add.png</file>
<file>Resources/Icons/icon.ico</file> <file>Resources/Icons/icon.ico</file>
<file>Resources/Icons/about.png</file>
<file>Resources/Icons/home.png</file>
<file>Resources/Icons/settings.png</file>
</qresource> </qresource>
</RCC> </RCC>
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