Changeset View
Changeset View
Standalone View
Standalone View
src/declarativeimports/plasmacomponents3/ComboBox.qml
Show All 37 Lines | 28 | T.ComboBox { | |||
---|---|---|---|---|---|
38 | leftPadding: surfaceNormal.margins.left | 38 | leftPadding: surfaceNormal.margins.left | ||
39 | rightPadding: surfaceNormal.margins.right | 39 | rightPadding: surfaceNormal.margins.right | ||
40 | bottomPadding: surfaceNormal.margins.bottom | 40 | bottomPadding: surfaceNormal.margins.bottom | ||
41 | 41 | | |||
42 | delegate: ItemDelegate { | 42 | delegate: ItemDelegate { | ||
43 | width: control.popup.width | 43 | width: control.popup.width | ||
44 | text: control.textRole ? (Array.isArray(control.model) ? modelData[control.textRole] : model[control.textRole]) : modelData | 44 | text: control.textRole ? (Array.isArray(control.model) ? modelData[control.textRole] : model[control.textRole]) : modelData | ||
45 | highlighted: control.highlightedIndex == index | 45 | highlighted: control.highlightedIndex == index | ||
46 | | ||||
46 | property bool separatorVisible: false | 47 | property bool separatorVisible: false | ||
47 | } | 48 | } | ||
48 | 49 | | |||
49 | indicator: PlasmaCore.SvgItem { | 50 | indicator: PlasmaCore.SvgItem { | ||
50 | implicitWidth: units.iconSizes.small | 51 | implicitWidth: units.iconSizes.small | ||
51 | implicitHeight: implicitWidth | 52 | implicitHeight: implicitWidth | ||
52 | anchors { | 53 | anchors { | ||
53 | right: parent.right | 54 | right: parent.right | ||
▲ Show 20 Lines • Show All 51 Lines • ▼ Show 20 Line(s) | 98 | popup: T.Popup { | |||
105 | contentItem: ListView { | 106 | contentItem: ListView { | ||
106 | id: listview | 107 | id: listview | ||
107 | clip: true | 108 | clip: true | ||
108 | implicitHeight: contentHeight | 109 | implicitHeight: contentHeight | ||
109 | model: control.popup.visible ? control.delegateModel : null | 110 | model: control.popup.visible ? control.delegateModel : null | ||
110 | currentIndex: control.highlightedIndex | 111 | currentIndex: control.highlightedIndex | ||
111 | highlightRangeMode: ListView.ApplyRange | 112 | highlightRangeMode: ListView.ApplyRange | ||
112 | highlightMoveDuration: 0 | 113 | highlightMoveDuration: 0 | ||
114 | LayoutMirroring.enabled: tre | ||||
safaalfulaij: So it is true even for LTR locales? | |||||
yes, mvourlakos: yes,
in my system with these settings the combobox list items are aligned correctly for both… | |||||
115 | LayoutMirroring.childrenInherit: true | ||||
113 | T.ScrollBar.vertical: Controls.ScrollBar { } | 116 | T.ScrollBar.vertical: Controls.ScrollBar { } | ||
114 | } | 117 | } | ||
115 | background: Rectangle { | 118 | background: Rectangle { | ||
116 | anchors { | 119 | anchors { | ||
117 | fill: parent | 120 | fill: parent | ||
118 | margins: -1 | 121 | margins: -1 | ||
119 | } | 122 | } | ||
120 | radius: 2 | 123 | radius: 2 | ||
Show All 15 Lines |
So it is true even for LTR locales?