From a1c76f4df2447cf7ea1e316437f2ef342f6080a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sat, 12 Jan 2013 09:54:24 +0100 Subject: [PATCH] Gather support information about screens Adds a section about screens to supportInformation containing: * whether multi-head is used * in case of multi-head the screen number * the number of screens * geometry per screen That should hopefully end the two often asked questions about the user's screen setup, especially if they say they use multi-head. REVIEW: 108363 --- workspace.cpp | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/workspace.cpp b/workspace.cpp index c42f420a8d..dccc41fa3b 100644 --- a/workspace.cpp +++ b/workspace.cpp @@ -82,6 +82,7 @@ namespace KWin { extern int screen_number; +extern bool is_multihead; static const int KWIN_MAX_NUMBER_DESKTOPS = 20; #ifdef KWIN_BUILD_KAPPMENU @@ -2196,6 +2197,25 @@ QString Workspace::supportInformation() const } support.append(QLatin1String(property.name()) % ": " % options->property(property.name()).toString() % '\n'); } + support.append("\nScreens\n"); + support.append( "=======\n"); + support.append("Multi-Head: "); + if (is_multihead) { + support.append("yes\n"); + support.append(QString("Head: %1\n").arg(screen_number)); + } else { + support.append("no\n"); + } + support.append(QString("Number of Screens: %1\n").arg(QApplication::desktop()->screenCount())); + for (int i=0; iscreenCount(); ++i) { + const QRect geo = QApplication::desktop()->screenGeometry(i); + support.append(QString("Screen %1 Geometry: %2,%3,%4x%5\n") + .arg(i) + .arg(geo.x()) + .arg(geo.y()) + .arg(geo.width()) + .arg(geo.height())); + } support.append("\nCompositing\n"); support.append( "===========\n"); support.append("Qt Graphics System: ");