Bug 172894

Summary: Okular does not use the full screen in presentation mode
Product: [Applications] okular Reporter: Andreas Goeb <agoeb>
Component: generalAssignee: Okular developers <okular-devel>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: jithin1987, mathieutournier, mbarabas, mgraesslin, michael, rara
Priority: NOR    
Version: 0.7.2   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Screenshot showing the problem

Description Andreas Goeb 2008-10-15 21:44:33 UTC
Version:           0.7.2 (using 4.1.2 (KDE 4.1.2), Kubuntu packages)
Compiler:          cc
OS:                Linux (x86_64) release 2.6.27-7-generic

When I try to use presentation mode in Okular, it does not fit the whole screen, but only 750x560 pixels from the top left corner, as if this area was the whole screen.

I use KDE 4.1.2 with Okular 0.7.2 on a MacBook running Kubuntu 8.10 beta release (including all updates until October 15th).
Comment 1 Pino Toscano 2008-10-15 21:50:00 UTC
Cannot reproduce here, Okular uses what Qt reports as screen size.
What does `xrandr` say in a terminal? Any particular setup (two monitors, xinerama/dual-head)?
Comment 2 Andreas Goeb 2008-10-16 08:56:37 UTC
xrandr reports this:
Screen 0: minimum 320 x 200, current 1280 x 800, maximum 2960 x 1050
VGA disconnected (normal left inverted right x axis y axis)
LVDS connected 1280x800+0+0 (normal left inverted right x axis y axis) 286mm x 179mm
   1280x800       59.9*+
   1024x768       60.0
   800x600        60.3
   640x480        59.9
TMDS-1 disconnected (normal left inverted right x axis y axis)
TV disconnected (normal left inverted right x axis y axis)

My graphics driver is "intel", I use X.org 7.4.
The problem occurs independently of my monitor setup. I tested in single monitor mode (see the xrandr output). When I disable LVDS and enable TMDS-1, the same behaviour is shown on the external monitor (even if the screen resolution is different).
Comment 3 Marius 2008-10-18 13:44:58 UTC
I can confirm this for kubuntu 8.10, all updates until october 17th. I didn't count the window size, but presentation mode only covers the upper left part of the screen. I'm on a hp notebook with a screen resolution of 1280x800, which is reported correctly by xrandr:

Screen 0: minimum 320 x 200, current 1280 x 800, maximum 1280 x 1280
VGA disconnected (normal left inverted right x axis y axis)
LVDS connected 1280x800+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
   1280x800       60.1*+
   1024x768       85.0     75.0     70.1     60.0
   832x624        74.6
   800x600        85.1     72.2     75.0     60.3     56.2
   640x480        85.0     72.8     75.0     59.9
   720x400        85.0
   640x400        85.1
   640x350        85.1
TV disconnected (normal left inverted right x axis y axis)

The problem occurs with both the "intel" and the "vesa" driver.
Comment 4 Jithin Emmanuel 2008-10-23 06:07:29 UTC
I can confirm this I use kubuntu 8.10. I use hp compaq 6910p.
Comment 5 Jithin Emmanuel 2008-10-23 06:08:19 UTC
output of xrandr

Screen 0: minimum 320 x 200, current 1280 x 800, maximum 1280 x 1280
VGA disconnected (normal left inverted right x axis y axis)
LVDS connected 1280x800+0+0 (normal left inverted right x axis y axis) 304mm x 190mm
   1280x800       60.0*+
   1024x768       60.0
   800x600        60.3
   640x480        59.9
TMDS-1 disconnected (normal left inverted right x axis y axis)
TV disconnected (normal left inverted right x axis y axis)
Comment 6 Orestes Mas 2008-11-25 12:51:42 UTC
Created attachment 28812 [details]
Screenshot showing the problem
Comment 7 Orestes Mas 2008-11-25 12:53:02 UTC
Comment on attachment 28812 [details]
Screenshot showing the problem

I can confirm this bug too, for Kubuntu 8.10 up-to-date
Comment 8 Martin Flöser 2008-11-25 17:51:17 UTC
I'm experiencing the same bug also in trunk (rev: 888947). I'm currently using an nVidia Twin View setup but the problem also occurrs if I am only using one screen. Surprisingly the presentation is always shown on the primary screen (laptop monitor), although that is the right monitor.

I don't post my xrandr output as it's useless due to using TwinView :-(

If you need any more input on it, please ask. I hope this bug can be fixed as it makes okular kind of useless. I'll try different pdf viewers.
Comment 9 Albert Astals Cid 2008-11-25 20:57:42 UTC
It's nice how you decided to blame okular when it works fine for so many other people instead of blaming KWin or XOrg or your drivers or etc.
Comment 10 Martin Flöser 2008-11-25 21:09:59 UTC
I do not want to blame anybody. I will dig into it myself when I find time to (I don't know okular source code yet) as this is a really big problem for me. I think we can't blame drivers as intel and nvidia are used.

And I know that it normaly works. On my old system it works and on my new laptop it does not. They both use the same distribution and the same graphics driver.

Btw fullscreen mode works fine.
Comment 11 Martin Flöser 2008-11-25 21:44:37 UTC
ok I just tested a little bit more: it works with Compiz.

So it could be a problem in the interaction with KWin.
Comment 12 Pino Toscano 2008-11-25 21:50:49 UTC
I am the author of the presentation mode improvements that got into KDE 4.1.

The code uses basically what Qt offers as API and results of the available screen configurations, so I'm not totally sure the fault is in Okular.
And what more strange: so far (so basing on what I read until now) the only reports about this problem came from kubuntu 8.10 users. (Might mean nothing though.)
Comment 13 Martin Flöser 2008-11-25 22:03:51 UTC
Pino, I just tried a little bit more and know I am really confused.

I open the presentation mode and it results in an unusable small portion of the screen. Then I switch to the second screen (via the toolbar), Okular switches to the second screen and everything is fine. Now I switch back to the first screen and everything is fine as well, although it did not work before. It's a good enough workaround for myself, but we should find the bug.

As you say you use Qt Api, I think we should investigate it and try to find out if it is an upstream bug (Qt) or a bug in KWin. Tomorrow I have some free time and I'll take a look in the code (btw I only discovered that I can switch the screen by looking at the code ;-) )
Comment 14 Pino Toscano 2008-11-26 22:10:56 UTC
General question to everyone that reported his idea so far (and not only):
does the problem happen anytime, or only when you have at least another monitor attached?
Comment 15 Jithin Emmanuel 2008-11-27 05:29:31 UTC
(In reply to comment #14)
> General question to everyone that reported his idea so far (and not only):
> does the problem happen anytime, or only when you have at least another monitor
> attached?
> 

I have this problem all time. I use kubuntu 8.10 with kde 4.1.3. Because of this I am using adobe reader now, although I like okular more
Comment 16 Andreas Goeb 2008-11-27 11:37:34 UTC
(In reply to comment #14)

Same thing here: The problem does not depend on a second screen. In addition to former comments, I also only tested it with kwin. And afaik Ubuntu 8.10 is one of the few distributions already using X.org 7.4. Maybe this is also important to reproduce the problem.
Comment 17 Jithin Emmanuel 2008-12-09 09:12:10 UTC
This is a kubuntu settings problem. See last comment 
https://bugs.launchpad.net/ubuntu/+source/kdegraphics/+bug/292098

By "Wu Chung Yi"
There is a solution. First go to system settings.
And go to "Window Behavior" in the 'general' page , then click Window-Specific.
And then delete "Okular initial default size", done!!!!!!!

That fixed my okular presentation view problem.
Comment 18 Martin Flöser 2008-12-09 09:17:03 UTC
thanks a lot. I can confirm that this solves the problem. So Pino your guess with kubuntu was right.

I mark this bug as downstream
Comment 19 Michael Ummels 2009-01-07 17:03:13 UTC
I disagree that this bug is Kubuntu-specfic. Clearly, even if the user sets a default size for Okular, this should not apply to fullscreen mode.
Comment 20 Pino Toscano 2009-01-16 22:09:01 UTC
*** Bug 181016 has been marked as a duplicate of this bug. ***
Comment 21 Mathieu Tournier 2009-01-16 22:24:31 UTC
>By "Wu Chung Yi"
>There is a solution. First go to system settings.
>And go to "Window Behavior" in the 'general' page , then click Window-Specific.
>And then delete "Okular initial default size", done!!!!!!!

>That fixed my okular presentation view problem.

It fixed the problem for me too :-)