mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-04-23 14:19:37 +08:00
Apply screenScaleFactor to implicitWidth (and cleanup)
This commit is contained in:
parent
e5c59b1308
commit
618cbffaa7
@ -7,7 +7,7 @@ import QtQuick.Layouts 1.3
|
||||
|
||||
import UM 1.2 as UM
|
||||
|
||||
// The labelBar shows a set of labels that are evenly spaced from oneother.
|
||||
// The labelBar shows a set of labels that are evenly spaced from one another.
|
||||
// The first item is aligned to the left, the last is aligned to the right.
|
||||
// It's intended to be used together with RadioCheckBar. As such, it needs
|
||||
// to know what the used itemSize is, so it can ensure the labels are aligned correctly.
|
||||
|
@ -1,4 +1,4 @@
|
||||
// Copyright (c) 2018 Ultimaker B.V.
|
||||
// Copyright (c) 2019 Ultimaker B.V.
|
||||
// Cura is released under the terms of the LGPLv3 or higher.
|
||||
|
||||
import QtQuick 2.10
|
||||
@ -9,6 +9,7 @@ import QtQuick.Controls.Styles 1.4
|
||||
import UM 1.2 as UM
|
||||
import Cura 1.6 as Cura
|
||||
import ".."
|
||||
|
||||
Item
|
||||
{
|
||||
id: qualityRow
|
||||
|
@ -19,7 +19,7 @@ Item
|
||||
property int barSize: UM.Theme.getSize("slider_groove_radius").height
|
||||
property var isCheckedFunction // Function that accepts the modelItem and returns if the item should be active.
|
||||
|
||||
implicitWidth: 200
|
||||
implicitWidth: 200 * screenScaleFactor
|
||||
implicitHeight: checkboxSize
|
||||
|
||||
property var dataModel: null
|
||||
@ -62,7 +62,7 @@ Item
|
||||
Layout.fillHeight: true
|
||||
// The last item of the repeater needs to be shorter, as we don't need another part to fit
|
||||
// the horizontal bar. The others should essentially not be limited.
|
||||
Layout.maximumWidth: index + 1 === repeater.count ? activeComponent.width: 200000000
|
||||
Layout.maximumWidth: index + 1 === repeater.count ? activeComponent.width : 200000000
|
||||
|
||||
property bool isEnabled: model.available
|
||||
// The horizontal bar between the checkable options.
|
||||
|
Loading…
x
Reference in New Issue
Block a user