Version: 0.4 (using KDE KDE 3.3.91) Installed from: Compiled From Sources Compiler: gcc 3.3 OS: Linux I've two screens side by side (Xinerama? - don't know the exact term) and therefore a resolution of 2560*1024 (more or less). Viewing a document in full screen mode, the left half is displayed on the left screen, the right half is not displayed at all (at least not on the right screen, I'm currently typing there, the left is occupied by the "full"-screen kpdf =)
Created attachment 9153 [details] screenshot, the situation described before Version: kpdf 0.4, KDE 3.3.91, CVS 050113
full screen mode or presentation mode?
Presentation Mode: View -> Presentation [F9]
*** Bug 97413 has been marked as a duplicate of this bug. ***
What would the correct behaviour for you? - Having the presentation cover both screens - Having the presentation on only one of the screens - Something else
Having the presentation covering only the current screen has other KDE apps do when using fullscreen
Would any of you be able of testing a patch against CVS version?
I would agree to #6 - might be a nice thing to have it configureable, though. I can test your patch, just let me know the exact command how/where to apply it (seems I can't get the hang of diff/patch *cough*)
Created attachment 9234 [details] A try to fix the problem Just download the patch to kdegraphics/kpdf name it xinerama.patch while saving, go there with a shell and do patch -p0 < xinerama.patch
Applied the patch and it works as a charm - thnx! =)
CVS commit by aacid: Fix presentation placement on xinerama BUG: 97347 M +3 -3 presentationwidget.cpp 1.16 --- kdegraphics/kpdf/ui/presentationwidget.cpp #1.15:1.16 @@ -53,7 +53,7 @@ PresentationWidget::PresentationWidget( // set look and geometry setBackgroundMode( Qt::NoBackground ); - QDesktopWidget * d = QApplication::desktop(); - m_width = d->width(); - m_height = d->height(); + QRect d = KGlobalSettings::desktopGeometry(this); + m_width = d.width(); + m_height = d.height(); // create top toolbar
Does not work here, position is ok, but size of presentation is taken from the other (first) screen. First screen: 1400x1050, second screen 1280x1024, presentation is shown on second display but right (and bottom) part is missing. Can we reopen the bug or should i create a new report?
Reopening the bug as seems it still has issues, thanks for reporting.
Hi Olaf, can you please download that executable and run it on you PC. Try starting it from a konsole in your first screen, and the on your second screen and please paste here the text that is outputted in both cases to the konsole. Test program: http://usuarios.lycos.es/tsdgeos/test If you have problems getting the executable to run download the source from http://usuarios.lycos.es/tsdgeos/test.cpp
Sorry for the delay, but i cannot run your program. Without xinerama no problem, but with two displays i allways got a segmentation fault. Binary or compiled from source, same error. KDE version 3.3.92-1 (rpms for SuSE from ftp://ftp.gwdg.de/pub/linux/suse/apt/SuSE/9.2-i386/RPMS.kde-unstable) Starting program: /home/bono/Documents/test [Thread debugging using libthread_db enabled] [New Thread 1096357376 (LWP 30576)] Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1096357376 (LWP 30576)] 0x40190fa7 in KInstance::config () from /opt/kde3/lib/libkdecore.so.4 (gdb) bt #0 0x40190fa7 in KInstance::config () from /opt/kde3/lib/libkdecore.so.4 #1 0x40191872 in KGlobal::config () from /opt/kde3/lib/libkdecore.so.4 #2 0x401afad5 in KGlobalSettings::desktopGeometry () from /opt/kde3/lib/libkdecore.so.4 #3 0x0804b448 in myWindow (this=0x8133ac0) at test.cpp:10 #4 0x0804b371 in main (argc=1, argv=0xbfffda24) at test.cpp:28
Sorry, i've updated the source of the test(not the binary because i don't have a suitable PC here) can you please retest.
First display (size 1400x1050): Creator size 1400 1050 Paint Event size 1400 1050 Second display (size 1280x1024 right of display 1) Creator size 1400 1050 Paint Event size 1280 1024
Created attachment 9628 [details] A try to fix the new problem Can you try if that patch solves the problem? If you don't know how to apply a patch read Comment #9
I've checked out kdegraphics and apply your patch. First display ok, but if i start presentation mode on the second display i got a segfault. I haven't updated kdelibs etc., still using precompiled binary labeled 3.3.92_2005021408, qt-3.3.4 Using host libthread_db library "/lib/tls/libthread_db.so.1". [Thread debugging using libthread_db enabled] [New Thread 1096002848 (LWP 1746)] [KCrash handler] #3 0x417efd21 in PresentationWidget::mouseMoveEvent (this=0x83c7b78, e=0xbfffe9a0) at qwidget.h:860 #4 0x40c758da in QWidget::event () from /usr/lib/qt3/lib/libqt-mt.so.3 #5 0x40bdcbaf in QApplication::internalNotify () from /usr/lib/qt3/lib/libqt-mt.so.3 #6 0x40bdef56 in QApplication::notify () from /usr/lib/qt3/lib/libqt-mt.so.3 #7 0x408465e1 in KApplication::notify () from /opt/kde3/lib/libkdecore.so.4 #8 0x40b7a25e in QETWidget::translateMouseEvent () from /usr/lib/qt3/lib/libqt-mt.so.3 #9 0x40b79116 in QApplication::x11ProcessEvent () from /usr/lib/qt3/lib/libqt-mt.so.3 #10 0x40b89b08 in QEventLoop::processEvents () from /usr/lib/qt3/lib/libqt-mt.so.3 #11 0x40bf4b41 in QEventLoop::enterLoop () from /usr/lib/qt3/lib/libqt-mt.so.3 #12 0x40bf4986 in QEventLoop::exec () from /usr/lib/qt3/lib/libqt-mt.so.3 #13 0x40bde63f in QApplication::exec () from /usr/lib/qt3/lib/libqt-mt.so.3 #14 0x0804f577 in main (argc=1, argv=0xbffff104) at main.cpp:80
Created attachment 9649 [details] A new try to fix the problem with screens with different resolutions Ok Olaf, here is a new try, revert the previous patch (patch -R -p0 < xinerama.patch) and then apply the new one. By the way, thanks a lot for the testing.
Ok, works perfectly on both display. Thank you for the bugfix and your great work! Now i do not need to start windows for presentations :-) I'm developing distributed parallel programs (linux,cray,...), so i know the need of testers for different environments.
CVS commit by aacid: Delay the calculation of m_width and m_height (and all its associated things) until first time the widget is shown (paintEvent), doing KGlobalSettings::desktopGeometry(this); in PresentationWidget::PresentationWidget always returns the geometry of the first screen, so it must be done in paintEvent (for example), where the widget has already been shown and KGlobalSettings::desktopGeometry(this); returns the geometry of the correct screen. Thanks to Olaf Bonorden for the patch testing BUGS: 97347 M +39 -29 presentationwidget.cpp 1.21 --- kdegraphics/kpdf/ui/presentationwidget.cpp #1.20:1.21 @@ -53,23 +53,9 @@ PresentationWidget::PresentationWidget( // set look and geometry setBackgroundMode( Qt::NoBackground ); - QRect d = KGlobalSettings::desktopGeometry(this); - m_width = d.width(); - m_height = d.height(); - // create top toolbar - m_topBar = new KToolBar( this, "presentationBar" ); - m_topBar->setIconSize( 32 ); - m_topBar->setMovingEnabled( false ); - m_topBar->insertButton( "1leftarrow", 2, SIGNAL( clicked() ), this, SLOT( slotPrevPage() ) ); - m_topBar->insertButton( "1rightarrow", 3, SIGNAL( clicked() ), this, SLOT( slotNextPage() ) ); - m_topBar->insertButton( "exit", 1, SIGNAL( clicked() ), this, SLOT( close() ) ); - m_topBar->setGeometry( 0, 0, m_width, 32 + 10 ); - m_topBar->alignItemRight( 1 ); - m_topBar->hide(); - // change topbar background color - QPalette p = m_topBar->palette(); - p.setColor( QPalette::Active, QColorGroup::Button, Qt::gray ); - p.setColor( QPalette::Active, QColorGroup::Background, Qt::darkGray ); - m_topBar->setPalette( p ); + m_width = -1; + + // show widget and take control + showFullScreen(); // misc stuff @@ -80,7 +66,4 @@ PresentationWidget::PresentationWidget( connect( m_overlayHideTimer, SIGNAL( timeout() ), this, SLOT( slotHideOverlay() ) ); - // show widget and take control - showFullScreen(); - // handle cursor appearance as specified in configuration if ( Settings::slidesCursor() == Settings::EnumSlidesCursor::HiddenDelay ) @@ -93,11 +76,4 @@ PresentationWidget::PresentationWidget( setCursor( KCursor::blankCursor() ); } - - // register this observer in document. events will come immediately - m_document->addObserver( this ); - - // show summary if requested - if ( Settings::slidesShowSummary() ) - generatePage(); } @@ -195,4 +171,6 @@ bool PresentationWidget::canUnloadPixmap void PresentationWidget::keyPressEvent( QKeyEvent * e ) { + if (m_width == -1) return; + if ( e->key() == Key_Left || e->key() == Key_Backspace ) slotPrevPage(); @@ -245,4 +223,6 @@ void PresentationWidget::mousePressEvent void PresentationWidget::mouseMoveEvent( QMouseEvent * e ) { + if (m_width == -1) return; + // hide a shown bar when exiting the area if ( m_topBar->isShown() ) @@ -261,4 +241,34 @@ void PresentationWidget::mouseMoveEvent( void PresentationWidget::paintEvent( QPaintEvent * pe ) { + if (m_width == -1) + { + QRect d = KGlobalSettings::desktopGeometry(this); + m_width = d.width(); + m_height = d.height(); + + // create top toolbar + m_topBar = new KToolBar( this, "presentationBar" ); + m_topBar->setIconSize( 32 ); + m_topBar->setMovingEnabled( false ); + m_topBar->insertButton( "1leftarrow", 2, SIGNAL( clicked() ), this, SLOT( slotPrevPage() ) ); + m_topBar->insertButton( "1rightarrow", 3, SIGNAL( clicked() ), this, SLOT( slotNextPage() ) ); + m_topBar->insertButton( "exit", 1, SIGNAL( clicked() ), this, SLOT( close() ) ); + m_topBar->setGeometry( 0, 0, m_width, 32 + 10 ); + m_topBar->alignItemRight( 1 ); + m_topBar->hide(); + // change topbar background color + QPalette p = m_topBar->palette(); + p.setColor( QPalette::Active, QColorGroup::Button, Qt::gray ); + p.setColor( QPalette::Active, QColorGroup::Background, Qt::darkGray ); + m_topBar->setPalette( p ); + + // register this observer in document. events will come immediately + m_document->addObserver( this ); + + // show summary if requested + if ( Settings::slidesShowSummary() ) + generatePage(); + } + // check painting rect consistancy QRect r = pe->rect().intersect( geometry() );
Hi there, I'm getting the same problem with my current version of kpdf as described by this 3 year old bug. The screenshot supplied by the original reporter corresponds perfectly with what I'm seeing. I'm not using Xinerama but xrandr to configure my second screen, which I guess might be why it's happening again. Debian testing, kpdf 0.5.8, powerpc. Peace, Brendon
Reopening, unfortunately i don't know how to further debug the problem though
Thank you for your bug report or feature suggestion. The "KPDF" application is no longer maintained, and all tickets are now closed. We recommend to switch to the "Okular" application. Due to the high number of bugs/suggestions in "KPDF" we are not able to go through all of them and verify if they are still valid in "Okular". That's why are we asking you to help us by checking if your bug/suggestion is still valid in Okular and if it still is opening a new bug/suggestion against it. Thank you for your effort in making KDE better :) (This is an automatic message from the KDE bug triaging team)