Summary: | tab "Sheet Selection" twice in print dialog | ||
---|---|---|---|
Product: | [Applications] calligrasheets | Reporter: | Burkhard Lück <lueck> |
Component: | general | Assignee: | Calligra Sheets (KSpread) Bugs <calligra-sheets-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | lambdae2, mail, mkruisselbrink |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Burkhard Lück
2006-03-31 15:52:31 UTC
The reason for this bug is, that in lib/kofficecore/KoMainWindow.cpp#1221 in the method "void KoMainWindow::slotFilePrintPreview()" rootView()->print(printer); got called before printer.setup(rootView()); is called. Normaly printer.setup does take care of freeing the with KPrinter::addDialogPage added custom pages. Since it is not called, each time the preview got called a new KPSheetSelectPage got added via the "void View::setupPrinter( KPrinter &prt )" method in kspread/kspread_view.cc. So, the correct solution would be to check via KPrinter.previewOnly() if we are in printpreview-mode and if that's the case, just don't add the custom page. Since we use the custom page at the "void View::print( KPrinter &prt )" method in kspread_view.cc, it's difficult to find a nice patch for that case cause what to do with the selected sheets if the user don't choosed which one should be printed? Just show all sheets in the preview even if the user likes to print/preview only e.g. the first sheet? can't test it as Print preview crashes kspread. bug #174120 this bug no longer seems to be present in kspread trunk |