Dear Sirs and Madams!
I have following simple QML Combobox in file UeStaffSelector.qml:
import QtQuick 2.0
import QtQuick.Controls 1.4
import QtQuick.Controls.Styles 1.4
import si.mikroelektronika 1.0
Item
{
id: ueStaffSelector
width: 256
height: 96
ComboBox
{
editable: false
activeFocusOnPress: false
selectByMouse: false
anchors.fill: parent
model: [ "Banana", "Apple", "Coconut" ]
style: ComboBoxStyle
{
label: Image
{
source: "qrc:///ueIcons/icons/ueUserLogError.png"
} // label
background: Rectangle
{
width: parent.width
height: parent.height
color: "black"
} // background
} // style
} // ComboBox
} // Item
import QtQuick 2.0
import QtQuick.Controls 1.4
import QtQuick.Controls.Styles 1.4
import si.mikroelektronika 1.0
Item
{
id: ueStaffSelector
width: 256
height: 96
ComboBox
{
editable: false
activeFocusOnPress: false
selectByMouse: false
anchors.fill: parent
model: [ "Banana", "Apple", "Coconut" ]
style: ComboBoxStyle
{
label: Image
{
source: "qrc:///ueIcons/icons/ueUserLogError.png"
} // label
background: Rectangle
{
width: parent.width
height: parent.height
color: "black"
} // background
} // style
} // ComboBox
} // Item
To copy to clipboard, switch view to plain text mode
It produces ComboBox as seen in screenshot:
QMLComboboxOrientationCropped.png
Now, this ComboBox resides in QML's app StatusBar and as you can see, test items are listed, that is ok. But, how do I reformat this item listing so it will reside on a top of ComboBox, as you can see from the screenshot?
Sincerely,
Marko
Bookmarks