Bug 361995

Summary: [Qt4-UI] screenshots empty
Product: [openSUSE] openSUSE 11.0 Reporter: Andreas Vetter <vetter>
Component: YaST2Assignee: Stefan Hundhammer <shundhammer>
Status: RESOLVED FIXED QA Contact: Jiri Srain <jsrain>
Severity: Normal    
Priority: P5 - None CC: asklein, bugz57, dmacvicar, mmarek
Version: Alpha 2   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: broken screenshot

Description Andreas Vetter 2008-02-14 22:41:13 UTC
When I press Shift + PrtScreen, an empty png is saved. Well, it has the right size, but everything is white.
Comment 1 Andreas Vetter 2008-02-14 22:42:15 UTC
Created attachment 195025 [details]
broken screenshot
Comment 2 Jozef Uhliarik 2008-02-22 14:21:36 UTC
It seems to be problem of yast2-qt
Comment 3 Stefan Hundhammer 2008-03-07 12:35:48 UTC
*** Bug 368161 has been marked as a duplicate of this bug. ***
Comment 4 Stefan Hundhammer 2008-03-17 14:39:21 UTC
It also happens with normal YaST2 screen shots during installation.
(Tested with 11.0-Alpha2+).
Comment 5 Duncan Mac-Vicar 2008-03-19 01:45:55 UTC
I tried replacing the current dialog by using the winId of QApplication::desktop() and I did got the screenshot of the whole desktop.

However, if I add debug to the winId the UI gets from

QWidget * dialog = (QWidget *) YDialog::currentDialog()->widgetRep();
std::cout << std::hex << dialog->winId() << std::endl;

I get:
52007c7

while xwininfo says:
xwininfo: Window id: 0x5200001 "YaST2"

mod-ui bug?
Comment 6 Stefan Hundhammer 2008-03-19 10:17:43 UTC
xwininfo very likely displays the window ID of the WM window around the Qt window.

Plus, YQMainDialog windows are typically swallowed by the YQMainWinDock (which in turn has a WM window around it).

QWidget::topLevelWidget() might help here.
Comment 7 Duncan Mac-Vicar 2008-03-19 14:24:26 UTC
Yes, that helps, fixed in svn. Please submit later when we accumulate some bugfixes.
Comment 8 Thomas Göttlicher 2008-04-02 09:12:57 UTC
*** Bug 375170 has been marked as a duplicate of this bug. ***