summaryrefslogtreecommitdiffstats
path: root/src/datavisualization/engine/surface3drenderer.cpp
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@woboq.com>2018-04-09 23:25:51 +0200
committerLiang Qi <liang.qi@qt.io>2018-04-10 10:23:16 +0000
commitda3c5925d546282e99f13b450a674c7024fde9ed (patch)
treee9a0888d235b8477343167c0fdabe09e464c8401 /src/datavisualization/engine/surface3drenderer.cpp
parent1212170af2f4ade8497fb150c3ae0e5d52236e35 (diff)
Use Qt::Alignment instead of the AlignmentFlag enum to represent flags
Because from Qt 5.12, the the right operator| is found in the Qt namespace instead of in the global namespace. One must still add the 'using' statement so this patch can be integrated using a previous qtbase. But the statement can be removed once qtbase is updated. Task-number: QTBUG-67582 Change-Id: Ib79c4623e858988bb55a87ad4fb0c1e0ceee81cf Reviewed-by: Liang Qi <liang.qi@qt.io>
Diffstat (limited to 'src/datavisualization/engine/surface3drenderer.cpp')
-rw-r--r--src/datavisualization/engine/surface3drenderer.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/datavisualization/engine/surface3drenderer.cpp b/src/datavisualization/engine/surface3drenderer.cpp
index cad9b97c..b6125719 100644
--- a/src/datavisualization/engine/surface3drenderer.cpp
+++ b/src/datavisualization/engine/surface3drenderer.cpp
@@ -1076,7 +1076,7 @@ void Surface3DRenderer::drawSlicedScene()
positionComp, totalRotation, 0, QAbstract3DGraph::SelectionRow,
m_labelShader, m_labelObj, activeCamera,
false, false, Drawer::LabelBelow,
- Qt::AlignmentFlag(Qt::AlignLeft | Qt::AlignTop), true);
+ Qt::AlignLeft | Qt::AlignTop, true);
}
labelNbr++;
}
@@ -1972,7 +1972,7 @@ void Surface3DRenderer::drawLabels(bool drawSelection, const Q3DCamera *activeCa
if (m_radialLabelOffset < 1.0f)
labelYTrans += gridLineOffset + gridLineWidth;
}
- Qt::AlignmentFlag alignment = (m_xFlipped == m_zFlipped) ? Qt::AlignLeft : Qt::AlignRight;
+ Qt::Alignment alignment = (m_xFlipped == m_zFlipped) ? Qt::AlignLeft : Qt::AlignRight;
QVector3D labelRotation;
if (m_xFlipped)
labelXTrans = -labelXTrans;
@@ -2128,7 +2128,7 @@ void Surface3DRenderer::drawLabels(bool drawSelection, const Q3DCamera *activeCa
else
labelZTrans = m_scaleZWithBackground + labelMargin;
- Qt::AlignmentFlag alignment = (m_xFlipped != m_zFlipped) ? Qt::AlignLeft : Qt::AlignRight;
+ Qt::Alignment alignment = (m_xFlipped != m_zFlipped) ? Qt::AlignLeft : Qt::AlignRight;
QVector3D labelRotation;
if (m_zFlipped)
labelZTrans = -labelZTrans;
@@ -2256,7 +2256,7 @@ void Surface3DRenderer::drawLabels(bool drawSelection, const Q3DCamera *activeCa
hAlignment = m_zFlipped ? Qt::AlignLeft : Qt::AlignRight;
if (m_yFlippedForGrid && vAlignment != Qt::AlignCenter)
vAlignment = (vAlignment == Qt::AlignTop) ? Qt::AlignBottom : Qt::AlignTop;
- alignment = Qt::AlignmentFlag(vAlignment | hAlignment);
+ alignment = vAlignment | hAlignment;
} else {
labelTrans.setX(m_axisCacheX.labelPosition(label));
}