Skip to content
Snippets Groups Projects
Commit 7b490c2c authored by Konstantin's avatar Konstantin
Browse files

09/12/2019

parent abee4181
No related branches found
No related tags found
6 merge requests!8Feature 2626,!7Feature 2798,!6Feature 2798,!5Feature 2798,!3Lib feature 2624,!2Bug 2708
This commit is part of merge request !7. Comments created here will be created in the context of that merge request.
import QtQuick 2.0
import QtQuick.Controls 2.5
import QtQuick 2.0
import QtQuick.Controls 2.2
import QtQuick.Controls.Styles 1.4
import QtGraphicalEffects 1.0
///This file will be moved to libdap and removed from here.
///this comboBox used int top panel exchange and statusBar will be deleted in the future
///About property
/// hilightColor - color of the selected item
/// fontSizeComboBox - font size for the entire widget
///widthPopupComboBoxActive and widthPopupComboBoxNormal - width of the combo box
///@hilightColor - color of the selected item
///@fontSizeComboBox - font size for the entire widget
///@widthPopupComboBoxActive and @widthPopupComboBoxNormal - width of the combo box
/// in the active state and in the normal state
///spacingEdgeActive and spacingEdgeNormal - padding width of the combo box in the active state
///@sidePaddingActive and @sidePaddingNormal - padding width of the combo box in the active state
/// and in the normal state
///@sidePaddingActive and @sidePaddingNormal - sets the indent from the edge of the right and left
/// edges of the parent in the active and normal state
///@topIndentActive and @topIndentNormal
///@bottomIndentActive and @bottomIndentNormal
/// - sets the indent from the edge of the upper and lower edges of the parent in the active and normal state
ComboBox {
property string normalColorText: "#070023"
property string hilightColorText: "#FFFFFF"
property string normalColor: "#FFFFFF"
property string hilightColor: "#330F54"
property int fontSizeComboBox: 16*pt
property int widthPopupComboBoxActive: parent.width
property int widthPopupComboBoxNormal: parent.width
property int spacingEdgeActive:16 * pt
property int spacingEdgeNormal:16 * pt
property int sidePaddingActive:16 * pt
property int sidePaddingNormal:16 * pt
property int topIndentActive:12 * pt
property int topIndentNormal:12 * pt
property int bottomIndentActive:14 * pt
property int bottomIndentNormal:14 * pt
id: customComboBox
......@@ -36,7 +51,7 @@ ComboBox {
height: 24 * pt
anchors.verticalCenter: parent.verticalCenter
anchors.right: parent.right
anchors.rightMargin: popup.visible ? spacingEdgeActive : spacingEdgeNormal
anchors.rightMargin: popup.visible ? sidePaddingActive : sidePaddingNormal
}
background: Rectangle {
......@@ -49,8 +64,8 @@ ComboBox {
contentItem: Text {
anchors.fill: parent
anchors.leftMargin: popup.visible ? spacingEdgeActive : spacingEdgeNormal
anchors.topMargin: 12 * pt
anchors.leftMargin: popup.visible ? sidePaddingActive : sidePaddingNormal
anchors.topMargin: popup.visible ? topIndentActive : topIndentNormal
text: parent.displayText
font.family: fontRobotoRegular.name
font.pixelSize: fontSizeComboBox
......
......@@ -12,7 +12,7 @@ ItemDelegate {
id:textDelegateComboBox
anchors.fill: parent
anchors.topMargin: 8 * pt
anchors.leftMargin: popup.visible ? spacingEdgeActive : spacingEdgeNormal
anchors.leftMargin: popup.visible ? sidePaddingActive : sidePaddingNormal
verticalAlignment: Qt.AlignTop
font.family: fontRobotoRegular.name
font.pixelSize: fontSizeComboBox
......
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