diff options
author | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-04-01 12:25:42 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-04-01 13:49:32 +0000 |
commit | 85f94782278113c97f87a53c14fc5b732548d376 (patch) | |
tree | e024fb03b0f1d2011c9090ca516d493cd9f99898 /src/widgets/kernel/qlayoutitem.cpp | |
parent | 8299e408df73f085744cec8b9cae3af4171035f8 (diff) |
Fix debug stream operators.
- Use QDebugStateSaver to restore space setting in stream operators
instead of returning dbg.space() which breaks formatting on streams
that already have nospace() set.
- Fix some single character string constants.
Change-Id: I0fe86bb1adbdd4a76ab6d2f8c19e063b45ddcf3b
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Diffstat (limited to 'src/widgets/kernel/qlayoutitem.cpp')
-rw-r--r-- | src/widgets/kernel/qlayoutitem.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/widgets/kernel/qlayoutitem.cpp b/src/widgets/kernel/qlayoutitem.cpp index 0e69bbc8ae..b21925e1d4 100644 --- a/src/widgets/kernel/qlayoutitem.cpp +++ b/src/widgets/kernel/qlayoutitem.cpp @@ -850,9 +850,10 @@ int QWidgetItemV2::heightForWidth(int width) const #ifndef QT_NO_DEBUG_STREAM QDebug operator<<(QDebug dbg, const QSizePolicy &p) { + QDebugStateSaver saver(dbg); dbg.nospace() << "QSizePolicy(horizontalPolicy = " << p.horizontalPolicy() << ", verticalPolicy = " << p.verticalPolicy() << ')'; - return dbg.space(); + return dbg; } #endif |