mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-23 06:33:55 -06:00
Merge branch '3.2'
Lots of conflicts due to rounding vs. flooring of text element positions for weirdness with the font aliasing.
This commit is contained in:
commit
ee9de1f11b
48 changed files with 999 additions and 875 deletions
|
@ -64,11 +64,11 @@ Rectangle
|
|||
|
||||
function getPrettyTime(time)
|
||||
{
|
||||
var hours = Math.floor(time / 3600)
|
||||
var hours = Math.round(time / 3600)
|
||||
time -= hours * 3600
|
||||
var minutes = Math.floor(time / 60);
|
||||
var minutes = Math.round(time / 60);
|
||||
time -= minutes * 60
|
||||
var seconds = Math.floor(time);
|
||||
var seconds = Math.round(time);
|
||||
|
||||
var finalTime = strPadLeft(hours, "0", 2) + ':' + strPadLeft(minutes,'0',2)+ ':' + strPadLeft(seconds,'0',2);
|
||||
return finalTime;
|
||||
|
@ -130,7 +130,7 @@ Rectangle
|
|||
anchors.leftMargin: UM.Theme.getSize("sidebar_margin").width
|
||||
anchors.top: hideSettings ? machineSelection.bottom : headerSeparator.bottom
|
||||
anchors.topMargin: UM.Theme.getSize("sidebar_margin").height
|
||||
width: Math.floor(parent.width * 0.45)
|
||||
width: Math.round(parent.width * 0.45)
|
||||
font: UM.Theme.getFont("large")
|
||||
color: UM.Theme.getColor("text")
|
||||
visible: !monitoringPrint && !hideView
|
||||
|
@ -142,7 +142,7 @@ Rectangle
|
|||
id: settingsModeSelection
|
||||
color: "transparent"
|
||||
|
||||
width: Math.floor(parent.width * 0.55)
|
||||
width: Math.round(parent.width * 0.55)
|
||||
height: UM.Theme.getSize("sidebar_header_mode_toggle").height
|
||||
|
||||
anchors.right: parent.right
|
||||
|
@ -171,10 +171,10 @@ Rectangle
|
|||
id: control
|
||||
|
||||
height: settingsModeSelection.height
|
||||
width: Math.floor(parent.width / 2)
|
||||
width: Math.round(parent.width / 2)
|
||||
|
||||
anchors.left: parent.left
|
||||
anchors.leftMargin: model.index * Math.floor(settingsModeSelection.width / 2)
|
||||
anchors.leftMargin: model.index * Math.round(settingsModeSelection.width / 2)
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
ButtonGroup.group: modeMenuGroup
|
||||
|
@ -329,7 +329,7 @@ Rectangle
|
|||
height: UM.Theme.getSize("sidebar_lining").height
|
||||
color: UM.Theme.getColor("sidebar_lining")
|
||||
anchors.bottom: printSpecs.top
|
||||
anchors.bottomMargin: Math.floor(UM.Theme.getSize("sidebar_margin").height * 2 + UM.Theme.getSize("progressbar").height + UM.Theme.getFont("default_bold").pixelSize)
|
||||
anchors.bottomMargin: Math.round(UM.Theme.getSize("sidebar_margin").height * 2 + UM.Theme.getSize("progressbar").height + UM.Theme.getFont("default_bold").pixelSize)
|
||||
}
|
||||
|
||||
Item
|
||||
|
@ -429,7 +429,7 @@ Rectangle
|
|||
{
|
||||
names.push(base.printMaterialNames[index]);
|
||||
lengths.push(base.printMaterialLengths[index].toFixed(2));
|
||||
weights.push(String(Math.floor(base.printMaterialWeights[index])));
|
||||
weights.push(String(Math.round(base.printMaterialWeights[index])));
|
||||
var cost = base.printMaterialCosts[index] == undefined ? 0 : base.printMaterialCosts[index].toFixed(2);
|
||||
costs.push(cost);
|
||||
if(cost > 0)
|
||||
|
@ -495,7 +495,7 @@ Rectangle
|
|||
if(base.printMaterialLengths[index] > 0)
|
||||
{
|
||||
lengths.push(base.printMaterialLengths[index].toFixed(2));
|
||||
weights.push(String(Math.floor(base.printMaterialWeights[index])));
|
||||
weights.push(String(Math.round(base.printMaterialWeights[index])));
|
||||
var cost = base.printMaterialCosts[index] == undefined ? 0 : base.printMaterialCosts[index].toFixed(2);
|
||||
costs.push(cost);
|
||||
if(cost > 0)
|
||||
|
@ -610,7 +610,7 @@ Rectangle
|
|||
})
|
||||
sidebarContents.replace(modesListModel.get(base.currentModeIndex).item, { "immediate": true })
|
||||
|
||||
var index = Math.floor(UM.Preferences.getValue("cura/active_mode"))
|
||||
var index = Math.round(UM.Preferences.getValue("cura/active_mode"))
|
||||
if(index)
|
||||
{
|
||||
currentModeIndex = index;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue