summaryrefslogtreecommitdiffstats
path: root/tests/arthur/common/paintcommands.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/arthur/common/paintcommands.cpp')
-rw-r--r--tests/arthur/common/paintcommands.cpp19
1 files changed, 1 insertions, 18 deletions
diff --git a/tests/arthur/common/paintcommands.cpp b/tests/arthur/common/paintcommands.cpp
index 5de4a6b487..6c3d26be0a 100644
--- a/tests/arthur/common/paintcommands.cpp
+++ b/tests/arthur/common/paintcommands.cpp
@@ -1887,7 +1887,6 @@ void PaintCommands::command_setBrushOrigin(QRegExp re)
/***************************************************************************************************/
void PaintCommands::command_brushTranslate(QRegExp re)
{
-#if QT_VERSION > 0x040200
QStringList caps = re.capturedTexts();
double dx = convertToDouble(caps.at(1));
double dy = convertToDouble(caps.at(2));
@@ -1900,13 +1899,11 @@ void PaintCommands::command_brushTranslate(QRegExp re)
brush_matrix.translate(dx, dy);
new_brush.setTransform(brush_matrix);
m_painter->setBrush(new_brush);
-#endif
}
/***************************************************************************************************/
void PaintCommands::command_brushScale(QRegExp re)
{
-#if QT_VERSION > 0x040200
QStringList caps = re.capturedTexts();
double sx = convertToDouble(caps.at(1));
double sy = convertToDouble(caps.at(2));
@@ -1919,13 +1916,11 @@ void PaintCommands::command_brushScale(QRegExp re)
brush_matrix.scale(sx, sy);
new_brush.setTransform(brush_matrix);
m_painter->setBrush(new_brush);
-#endif
}
/***************************************************************************************************/
void PaintCommands::command_brushRotate(QRegExp re)
{
-#if QT_VERSION > 0x040200
QStringList caps = re.capturedTexts();
double rot = convertToDouble(caps.at(1));
@@ -1937,13 +1932,11 @@ void PaintCommands::command_brushRotate(QRegExp re)
brush_matrix.rotate(rot);
new_brush.setTransform(brush_matrix);
m_painter->setBrush(new_brush);
-#endif
}
/***************************************************************************************************/
void PaintCommands::command_brushShear(QRegExp re)
{
-#if QT_VERSION > 0x040200
QStringList caps = re.capturedTexts();
double sx = convertToDouble(caps.at(1));
double sy = convertToDouble(caps.at(2));
@@ -1956,7 +1949,6 @@ void PaintCommands::command_brushShear(QRegExp re)
brush_matrix.shear(sx, sy);
new_brush.setTransform(brush_matrix);
m_painter->setBrush(new_brush);
-#endif
}
/***************************************************************************************************/
@@ -2327,10 +2319,8 @@ void PaintCommands::command_gradient_setLinear(QRegExp re)
lg.setSpread(m_gradientSpread);
lg.setCoordinateMode(m_gradientCoordinate);
QBrush brush(lg);
-#if QT_VERSION > 0x040200
QTransform brush_matrix = m_painter->brush().transform();
brush.setTransform(brush_matrix);
-#endif
m_painter->setBrush(brush);
}
@@ -2376,10 +2366,8 @@ void PaintCommands::command_gradient_setRadial(QRegExp re)
rg.setSpread(m_gradientSpread);
rg.setCoordinateMode(m_gradientCoordinate);
QBrush brush(rg);
-#if QT_VERSION > 0x040200
QTransform brush_matrix = m_painter->brush().transform();
brush.setTransform(brush_matrix);
-#endif
m_painter->setBrush(brush);
}
@@ -2401,10 +2389,8 @@ void PaintCommands::command_gradient_setConical(QRegExp re)
cg.setSpread(m_gradientSpread);
cg.setCoordinateMode(m_gradientCoordinate);
QBrush brush(cg);
-#if QT_VERSION > 0x040200
QTransform brush_matrix = m_painter->brush().transform();
brush.setTransform(brush_matrix);
-#endif
m_painter->setBrush(brush);
}
@@ -2449,7 +2435,6 @@ void PaintCommands::command_surface_begin(QRegExp re)
m_surface_painter = m_painter;
-#if QT_VERSION > 0x040200
if (m_type == OpenGLType || m_type == OpenGLPBufferType) {
#ifndef QT_NO_OPENGL
m_surface_pbuffer = new QGLPixelBuffer(qRound(w), qRound(h));
@@ -2462,9 +2447,7 @@ void PaintCommands::command_surface_begin(QRegExp re)
m_surface_pixmap.fill(Qt::transparent);
m_painter = new QPainter(&m_surface_pixmap);
#endif
- } else
-#endif
- {
+ } else {
m_surface_image = QImage(qRound(w), qRound(h), QImage::Format_ARGB32_Premultiplied);
m_surface_image.fill(0);
m_painter = new QPainter(&m_surface_image);