Version: 1.3 (using KDE 3.2 BRANCH >= 20040204, (testing/unstable)) Compiler: gcc version 3.3.3 20040214 (prerelease) (Debian) OS: Linux (i686) release 2.6.3-1-k7 I am editing a document, and then create a new document from the file new menu. Whilst working on this new document, when ever I call up a dialog box (for instance format page layout) kword brings the older documents window as the highest document window behind the dialog box, so that when the dialog box is dismissed the wrong document is displayed. It is even worse than this. If I call up a dialog box that then calls up a subsidiary dialog box (for instance File/Create Template From Document and then select the "select" button related to the custom picture) when I return from the subsidiary dialog box, the original dialog box is hidden behind the old document window - both giving the impression that both dialogs have been dismissed, but also confusing the user who now can't enter anything into the old document. It is necessary to manually select the new document to get back to the dialog box.
Can you reproduce it on KSpread or KPresenter? It would be important to know if the problem is KWord-specific or if it is in the KOffice libraries? (Custom pictures for templates were broken since recently, so it might be that they are other bugs. Thank you for testing the fixed code.) Have a nice day!
I cannot confirm. I have tried to reproduce it with KWord and also with KPresenter. Both work as expected. The focus return to the correct document after ending the dialog. But perhaps it is a KDE 3.2.x problem (mine is from 2004-02-21.) Have a nice day!
I can reproduce in Word and in KPresenter, but it is not happening with KSpread These are the debian packages put together by Ben Burton (formal debian maintainer), running with the debian kdelibs from the debian experimental release As you can see above these packages are from 20040204
Good, as the bug is not only with KWord but with KPresenter too, I am moving it to KOffice/General. As for the 2004-02-04, it does not tell much, just that the version is from after that date. Have a nice day!
On Sunday 29 February 2004 14:40, alan@chandlerfamily.org.uk wrote: > Whilst working on this new document, when ever I call up a dialog box (for instance format page layout) kword brings the older documents window as the highest document window behind the dialog box, so that when the dialog box is dismissed the wrong document is displayed. This sounds like a KWin bug/misbehavior to me. It doesn't happen here, so I guess it was fixed in KWin. However the cause for this problem is a missing parent widget in the dialog, which I just fixed for the "page layout" dialog. Any other dialog showing the same problem? > It is even worse than this. If I call up a dialog box that then calls up a subsidiary dialog box > (for instance File/Create Template From Document and then select the "select" button related to the custom picture) > when I return from the subsidiary dialog box, the original dialog box is hidden > behind the old document window - both giving the impression that both dialogs > have been dismissed, but also confusing the user who now can't enter anything > into the old document. It is necessary to manually select the new document to get back to the dialog box. That was another missing parent widget - fixed as well. However I'm sure KWin was improved to handle such cases better, since it all works fine here. I suggest a kdelibs/kdebase upgrade...
CVS commit by faure: Pass parent widget to page layout dialog (and to the filedialog from the template-creation dialog). Should fix 76412... but kwin seems to handle such cases better nowadays anyway, doesn't it? CCMAIL: 76412@bugs.kde.org M +4 -4 koPageLayoutDia.cc 1.82 M +2 -3 koPageLayoutDia.h 1.41 M +2 -2 koTemplateCreateDia.cc 1.48 --- koffice/lib/kofficeui/koPageLayoutDia.cc #1.81:1.82 @@ -184,8 +184,8 @@ KoPageLayoutDia::~KoPageLayoutDia() /*======================= show dialog ============================*/ -bool KoPageLayoutDia::pageLayout( KoPageLayout& _layout, KoHeadFoot& _hf, int _tabs, KoUnit::Unit& unit ) +bool KoPageLayoutDia::pageLayout( KoPageLayout& _layout, KoHeadFoot& _hf, int _tabs, KoUnit::Unit& unit, QWidget* parent ) { bool res = false; - KoPageLayoutDia *dlg = new KoPageLayoutDia( 0, "PageLayout", _layout, _hf, _tabs, unit ); + KoPageLayoutDia *dlg = new KoPageLayoutDia( parent, "PageLayout", _layout, _hf, _tabs, unit ); if ( dlg->exec() == QDialog::Accepted ) { @@ -203,8 +203,8 @@ bool KoPageLayoutDia::pageLayout( KoPage /*======================= show dialog ============================*/ bool KoPageLayoutDia::pageLayout( KoPageLayout& _layout, KoHeadFoot& _hf, KoColumns& _cl, - KoKWHeaderFooter &_kwhf, int _tabs, KoUnit::Unit& unit ) + KoKWHeaderFooter &_kwhf, int _tabs, KoUnit::Unit& unit, QWidget* parent ) { bool res = false; - KoPageLayoutDia *dlg = new KoPageLayoutDia( 0, "PageLayout", _layout, _hf, _cl, _kwhf, _tabs, unit ); + KoPageLayoutDia *dlg = new KoPageLayoutDia( parent, "PageLayout", _layout, _hf, _cl, _kwhf, _tabs, unit ); if ( dlg->exec() == QDialog::Accepted ) { --- koffice/lib/kofficeui/koPageLayoutDia.h #1.40:1.41 @@ -137,5 +137,5 @@ public: * See constructor for documentation on the parameters */ - static bool pageLayout( KoPageLayout&, KoHeadFoot&, int tabs, KoUnit::Unit& unit); + static bool pageLayout( KoPageLayout&, KoHeadFoot&, int tabs, KoUnit::Unit& unit, QWidget* parent = 0 ); /** @@ -143,6 +143,5 @@ public: * See constructor for documentation on the parameters */ - static bool pageLayout( KoPageLayout&, KoHeadFoot&, KoColumns&, KoKWHeaderFooter&, int tabs, KoUnit::Unit& unit ); - + static bool pageLayout( KoPageLayout&, KoHeadFoot&, KoColumns&, KoKWHeaderFooter&, int tabs, KoUnit::Unit& unit, QWidget* parent = 0 ); /** * Retrieves a standard page layout. --- koffice/lib/kofficeui/koTemplateCreateDia.cc #1.47:1.48 @@ -330,5 +330,5 @@ void KoTemplateCreateDia::slotSelect() { d->m_custom->setChecked(true); - KFileDialog fd(QString::null, KImageIO::pattern(KImageIO::Reading), 0, 0, true); + KFileDialog fd(QString::null, KImageIO::pattern(KImageIO::Reading), this, 0, true); fd.setCaption(i18n("Select Picture")); KURL url;
First - I am running kde 3.2.1 from the debian unstable package - so I would have assumed kwin is pretty up to date. I have done an exhaustive run through of the top level menus that call up dialog boxes and the following cause me problems in KWORD (not tried KPresented yet). File/Print Preview Insert/Link Insert/Picture Insert/Scan Image Format/Page Layout Frames/Text Background Color Frames/Configure Frame Border/Border Color Tools/Configure Shortcuts Tools/Configure Toolbars Tools/Configure KWord
Now been through KSPREAD - which I reported above did not have probems, but it does Following top level menu dialogs cause this File/Print Preview Insert/Link Tools/Spelling (although I didn't have Ispell installed so I first got an error message) Tools/Protect Document/Protect Sheet Tools/Protect Document/Protect Doc Settings/Configure/Shortcuts Settings/Configure/Toolbars Settings/Configure/Kspread
Now KPresenter - the following top level menus cause the problem File/Print Preview Insert/File Insert/Picture Insert/Scan Image Format/Page Layout Settings/Shortcuts Settings/Toolbars Settings/KPresenter
Now tried KVIVIO Following toplevel menus cause the problem File/Print Preview Edit/Edit Stencil Text Page/Export Page Format/Page Layout Tools/Edit Stencil Text Settings/Configure Shortcuts Settings/Configure Toolbars given the other packages do, suprisingly Settings/Configure Kvivio does not cause a problem
Karbon 14 Following toplevel menus cause the problem File/Import Graphics File/Print Preview All the Plugin Menus Settings/Configure Page Layout Settings/Configure Settings Settings/Configure Toolbars Settings/Configure Karbon14
KChart and KFormula Standard menu items (Print Preview/Configure menus) cause problems in addition KChart Edit/Edit Data
CVS commit by faure: Give parent widget to "configure shortcuts" and "configure toolbars" in all KOffice applications. Although kwin got improved since #76412, this still improves the behavior when having two mainwindows (modal dialogs without parent stay on top of all windows, whereas modal dialogs with a proper parent only stay on top of the correct window). CCMAIL: 76412@bugs.kde.org M +6 -6 koMainWindow.cc 1.324 --- koffice/lib/kofficecore/koMainWindow.cc #1.323:1.324 @@ -1223,5 +1223,5 @@ void KoMainWindow::slotConfigureKeys() return; - KKeyDialog dlg; + KKeyDialog dlg( this ); dlg.insert( actionCollection() ); dlg.insert( view->actionCollection() ); @@ -1235,5 +1235,5 @@ void KoMainWindow::slotConfigureToolbars if (rootDocument()) saveMainWindowSettings( KGlobal::config(), rootDocument()->instance()->instanceName() ); - KEditToolbar edit(factory()); + KEditToolbar edit(factory(), this); connect(&edit,SIGNAL(newToolbarConfig()),this,SLOT(slotNewToolbarConfig())); (void) edit.exec();
CVS commit by faure: parent widget pointer for - insert picture - save picture, change picture (file dialog) - insert file (file dialog) - export to html presentation (file dialog) - configure kpresenter CCMAIL: 76412@bugs.kde.org M +1 -1 kpresenter_dlg_config.cc 1.116 M +22 -22 kpresenter_view.cc 1.1000 --- koffice/kpresenter/kpresenter_dlg_config.cc #1.115:1.116 @@ -69,5 +69,5 @@ KPConfig::KPConfig( KPresenterView* pare : KDialogBase(KDialogBase::IconList,i18n("Configure KPresenter") , KDialogBase::Ok | KDialogBase::Apply | KDialogBase::Cancel| KDialogBase::Default, - KDialogBase::Ok) + KDialogBase::Ok, parent) { --- koffice/kpresenter/kpresenter_view.cc #1.999:1.1000 @@ -645,5 +645,5 @@ void KPresenterView::insertPicture() mimetypes += KoPictureFilePreview::clipartMimeTypes(); - KFileDialog fd( m_pKPresenterDoc->picturePath(), QString::null, 0, 0, true ); + KFileDialog fd( m_pKPresenterDoc->picturePath(), QString::null, this, 0, true ); fd.setCaption( i18n( "Insert Picture" ) ); fd.setMimeFilter( mimetypes ); @@ -697,5 +697,5 @@ void KPresenterView::savePicture( const mimetypes << mimetype; - KFileDialog fd( oldFile, QString::null, 0, 0, TRUE ); + KFileDialog fd( oldFile, QString::null, this, 0, TRUE ); fd.setMimeFilter( mimetypes ); fd.setCaption(i18n("Save Picture")); @@ -1294,5 +1294,5 @@ void KPresenterView::extraWebPres() else if ( ret == KMessageBox::Yes ) { - url = KFileDialog::getOpenURL( QString::null, i18n("*.kpweb|KPresenter HTML Presentation (*.kpweb)") ); + url = KFileDialog::getOpenURL( QString::null, i18n("*.kpweb|KPresenter HTML Presentation (*.kpweb)"), this ); if( url.isEmpty() ) @@ -3739,5 +3739,5 @@ void KPresenterView::changePicture( cons mimetypes += KoPictureFilePreview::clipartMimeTypes(); - KFileDialog fd( filename, QString::null, 0, 0, true ); + KFileDialog fd( filename, QString::null, this, 0, true ); fd.setCaption(i18n("Select New Picture")); fd.setMimeFilter( mimetypes ); @@ -4676,5 +4676,5 @@ void KPresenterView::insertLink() QString link; QString ref; - if(KoInsertLinkDia::createLinkDia(link, ref, QStringList(), false)) + if(KoInsertLinkDia::createLinkDia(link, ref, QStringList(), false, this)) { if(!link.isEmpty() && !ref.isEmpty()) @@ -4695,5 +4695,5 @@ void KPresenterView::changeLink() QString link=oldLinkName; QString ref=oldhref; - if(KoInsertLinkDia::createLinkDia(link, ref, QStringList(), false)) + if(KoInsertLinkDia::createLinkDia(link, ref, QStringList(), false, this)) { if(!link.isEmpty() && !ref.isEmpty()) @@ -6800,5 +6800,5 @@ void KPresenterView::autoSpellCheck() void KPresenterView::insertFile( ) { - KFileDialog fd( QString::null, QString::null, 0, 0, TRUE ); + KFileDialog fd( QString::null, QString::null, this, 0, TRUE ); fd.setMimeFilter( "application/x-kpresenter" ); fd.setCaption(i18n("Insert File"));
Status: > Insert/Scan Image > Tools/Configure Shortcuts > Tools/Configure Toolbars Done once for all apps. > File/Print Preview Requires kdeprint change. > Frames/Text Background Color > Frames/Configure Frame Border/Border Color Need tkcoloractions change. All the other KWord/KPresenter ones have been fixed. Enough for today :) If anyone feels like continuing this job, it's a rather easy one, just go through the rest of the dialogs listed in this BR and pass them a parent widget pointer (usually the view).
All the kivio specific dialogs already have a parent widget.
Let's mark this bug as "junior job" (the first one in KOffice?) Have a nice day!
Created attachment 6778 [details] Patch to solve the problem with this bug and the "edit data" action of kchart This patch fixes the problem with kchart and "edit data". The attached patch applies to the directory koffice/kchart . I believe this is the only place in the kchart directory that has this bug, but the "Configure Shortcuts" still has it, though previous patches have fixed all the other "Configure ..." dialogs.
Attachement #6778 patched to KOffice CVS HEAD
I am not sure what's the exact state of that bug report for koffice next 1.5 in trunk. I could not reproduce the bug but i did not try all koffice apps and all dialogs, just a few reported here. Alan, if you have a newer version (1.4.x), can you point the still buggy dialogs please? Thanks in advance.
On Friday 09 Dec 2005 19:30, Anne-Marie Mahfouf wrote: > I am not sure what's the exact state of that bug report for koffice next > 1.5 in trunk. I could not reproduce the bug but i did not try all koffice > apps and all dialogs, just a few reported here. Alan, if you have a newer > version (1.4.x), can you point the still buggy dialogs please? Thanks in > advance. I am now running Koffice 1.4.2 (Debian Unstable) and the bug as I originally reported it seems to have been fixed. I haven't done an exhaustive test.
I don't think anybody will bother to do it. Let's just call it a day, kthxbye?