summaryrefslogtreecommitdiffstats
path: root/src/gui/painting
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/painting')
-rw-r--r--src/gui/painting/qbrush.cpp3
-rw-r--r--src/gui/painting/qcolor.cpp3
-rw-r--r--src/gui/painting/qmatrix.cpp3
-rw-r--r--src/gui/painting/qpagelayout.cpp3
-rw-r--r--src/gui/painting/qpagesize.cpp3
-rw-r--r--src/gui/painting/qpainter.cpp2
-rw-r--r--src/gui/painting/qpen.cpp3
-rw-r--r--src/gui/painting/qpolygon.cpp6
-rw-r--r--src/gui/painting/qtransform.cpp3
9 files changed, 20 insertions, 9 deletions
diff --git a/src/gui/painting/qbrush.cpp b/src/gui/painting/qbrush.cpp
index 27f28f7193..5bf8387400 100644
--- a/src/gui/painting/qbrush.cpp
+++ b/src/gui/painting/qbrush.cpp
@@ -1022,8 +1022,9 @@ QDebug operator<<(QDebug dbg, const QBrush &b)
"TexturePattern" // 24
};
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QBrush(" << b.color() << ',' << BRUSH_STYLES[b.style()] << ')';
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qcolor.cpp b/src/gui/painting/qcolor.cpp
index 806c9362ac..b33d7a74fc 100644
--- a/src/gui/painting/qcolor.cpp
+++ b/src/gui/painting/qcolor.cpp
@@ -2469,6 +2469,7 @@ void QColor::invalidate()
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QColor &c)
{
+ QDebugStateSaver saver(dbg);
if (!c.isValid())
dbg.nospace() << "QColor(Invalid)";
else if (c.spec() == QColor::Rgb)
@@ -2481,7 +2482,7 @@ QDebug operator<<(QDebug dbg, const QColor &c)
else if (c.spec() == QColor::Hsl)
dbg.nospace() << "QColor(AHSL " << c.alphaF() << ", " << c.hslHueF() << ", " << c.hslSaturationF() << ", " << c.lightnessF() << ')';
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qmatrix.cpp b/src/gui/painting/qmatrix.cpp
index 679b5000cb..acedc6a7ba 100644
--- a/src/gui/painting/qmatrix.cpp
+++ b/src/gui/painting/qmatrix.cpp
@@ -1130,6 +1130,7 @@ QDataStream &operator>>(QDataStream &s, QMatrix &m)
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QMatrix &m)
{
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QMatrix("
<< "11=" << m.m11()
<< " 12=" << m.m12()
@@ -1138,7 +1139,7 @@ QDebug operator<<(QDebug dbg, const QMatrix &m)
<< " dx=" << m.dx()
<< " dy=" << m.dy()
<< ')';
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qpagelayout.cpp b/src/gui/painting/qpagelayout.cpp
index c1b23960ad..f443bbd5ac 100644
--- a/src/gui/painting/qpagelayout.cpp
+++ b/src/gui/painting/qpagelayout.cpp
@@ -942,6 +942,7 @@ QRect QPageLayout::paintRectPixels(int resolution) const
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QPageLayout &layout)
{
+ QDebugStateSaver saver(dbg);
if (layout.isValid()) {
QString output = QStringLiteral("QPageLayout(%1, %2, l:%3 r:%4 t:%5 b:%6 %7)");
QString units;
@@ -976,7 +977,7 @@ QDebug operator<<(QDebug dbg, const QPageLayout &layout)
} else {
dbg.nospace() << "QPageLayout()";
}
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qpagesize.cpp b/src/gui/painting/qpagesize.cpp
index fe445c0aec..c0aae603b7 100644
--- a/src/gui/painting/qpagesize.cpp
+++ b/src/gui/painting/qpagesize.cpp
@@ -1854,6 +1854,7 @@ QSize QPageSize::sizePixels(PageSizeId pageSizeId, int resolution)
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QPageSize &pageSize)
{
+ QDebugStateSaver saver(dbg);
if (pageSize.isValid()) {
QString output = QStringLiteral("QPageSize(\"%1\", \"%2\", %3x%4pt, %5)");
output = output.arg(pageSize.name())
@@ -1865,7 +1866,7 @@ QDebug operator<<(QDebug dbg, const QPageSize &pageSize)
} else {
dbg.nospace() << "QPageSize()";
}
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qpainter.cpp b/src/gui/painting/qpainter.cpp
index 6f00abfc5f..973c9da96c 100644
--- a/src/gui/painting/qpainter.cpp
+++ b/src/gui/painting/qpainter.cpp
@@ -7462,6 +7462,7 @@ start_lengthVariant:
range.format.setFontUnderline(true);
underlineFormats.append(range);
}
+#ifdef Q_OS_MAC
} else if (hidemnmemonic && *cin == QLatin1Char('(') && l >= 4 &&
cin[1] == QLatin1Char('&') && cin[2] != QLatin1Char('&') &&
cin[3] == QLatin1Char(')')) {
@@ -7473,6 +7474,7 @@ start_lengthVariant:
length -= n + 4;
l -= 4;
continue;
+#endif //Q_OS_MAC
}
*cout = *cin;
++cout;
diff --git a/src/gui/painting/qpen.cpp b/src/gui/painting/qpen.cpp
index 4796d2c0ad..6263d18b01 100644
--- a/src/gui/painting/qpen.cpp
+++ b/src/gui/painting/qpen.cpp
@@ -1026,12 +1026,13 @@ QDebug operator<<(QDebug dbg, const QPen &p)
"CustomDashLine"
};
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QPen(" << p.width() << ',' << p.brush()
<< ',' << PEN_STYLES[p.style()] << ',' << int(p.capStyle())
<< ',' << int(p.joinStyle()) << ',' << p.dashPattern()
<< ',' << p.dashOffset()
<< ',' << p.miterLimit() << ')';
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qpolygon.cpp b/src/gui/painting/qpolygon.cpp
index 511af49787..efcc8875a5 100644
--- a/src/gui/painting/qpolygon.cpp
+++ b/src/gui/painting/qpolygon.cpp
@@ -461,11 +461,12 @@ QRect QPolygon::boundingRect() const
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QPolygon &a)
{
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QPolygon(";
for (int i = 0; i < a.count(); ++i)
dbg.nospace() << a.at(i);
dbg.nospace() << ')';
- return dbg.space();
+ return dbg;
}
#endif
@@ -802,11 +803,12 @@ QDataStream &operator>>(QDataStream &s, QPolygonF &a)
#ifndef QT_NO_DEBUG_STREAM
QDebug operator<<(QDebug dbg, const QPolygonF &a)
{
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QPolygonF(";
for (int i = 0; i < a.count(); ++i)
dbg.nospace() << a.at(i);
dbg.nospace() << ')';
- return dbg.space();
+ return dbg;
}
#endif
diff --git a/src/gui/painting/qtransform.cpp b/src/gui/painting/qtransform.cpp
index 4c1aff92ae..31d7a2300b 100644
--- a/src/gui/painting/qtransform.cpp
+++ b/src/gui/painting/qtransform.cpp
@@ -1091,6 +1091,7 @@ QDebug operator<<(QDebug dbg, const QTransform &m)
"TxProject"
};
+ QDebugStateSaver saver(dbg);
dbg.nospace() << "QTransform(type=" << typeStr[m.type()] << ','
<< " 11=" << m.m11()
<< " 12=" << m.m12()
@@ -1103,7 +1104,7 @@ QDebug operator<<(QDebug dbg, const QTransform &m)
<< " 33=" << m.m33()
<< ')';
- return dbg.space();
+ return dbg;
}
#endif