Bug 162748 - Calc page layout changes to portrait upon switching printer
Summary: Calc page layout changes to portrait upon switching printer
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 165686 (view as bug list)
Depends on:
Blocks: Print-Dialog
  Show dependency treegraph
 
Reported: 2024-09-02 13:49 UTC by Gabor Kelemen (allotropia)
Modified: 2025-03-17 14:50 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
Example Calc document set to landscape orientation (11.65 KB, application/vnd.oasis.opendocument.spreadsheet)
2024-09-02 13:49 UTC, Gabor Kelemen (allotropia)
Details
The documents preview in the Print dialog before change (64.83 KB, image/png)
2024-09-02 13:59 UTC, Gabor Kelemen (allotropia)
Details
The documents preview in the Print dialog after the printer change (62.74 KB, image/png)
2024-09-02 14:00 UTC, Gabor Kelemen (allotropia)
Details
Single sheet divided into 4 pages with a month on each (22.51 KB, application/vnd.oasis.opendocument.spreadsheet)
2024-12-12 04:38 UTC, Alistair Saywell
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2024-09-02 13:49:04 UTC
Created attachment 196181 [details]
Example Calc document set to landscape orientation

This is split from bug 155218 comment#27

When a landscape style sheet is printed, and the printer is changed in the Print dialog, the content is refitted to a portrait page.

1. Open attached document
2. Open the Print dialog. Notice the preview shows a landscape document.
3. Change the printer from the default one to any other
-> the preview is rerendered and the content is fitted with Portrait orientation.

Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: c52f139b4f7140033144dde29f70a39ebedb6aa0
CPU threads: 14; OS: Windows 10 X86_64 (10.0 build 19045); UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: default

Seems to have started in 6.3 with the rework of the Print dialog. So while this report is pretty similar to bug 146056 (a regression from 7.4) this is not the same.
Comment 1 Gabor Kelemen (allotropia) 2024-09-02 13:59:58 UTC
Created attachment 196182 [details]
The documents preview in the Print dialog before change
Comment 2 Gabor Kelemen (allotropia) 2024-09-02 14:00:22 UTC
Created attachment 196183 [details]
The documents preview in the Print dialog after the printer change
Comment 3 Buovjaga 2024-11-14 18:01:14 UTC
Not reproduced, but I only have a printer that is no longer present and Microsoft PDF printer.

Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: deaa5dc2a4d5446cdd120236615608702598e365
CPU threads: 2; OS: Windows 11 X86_64 (10.0 build 22621); UI render: Skia/Raster; VCL: win
Locale: en-US (en_US); UI: en-GB
Calc: threaded
Comment 4 Alistair Saywell 2024-12-12 04:38:51 UTC
Created attachment 198076 [details]
Single sheet divided into 4 pages with a month on each

It arose again today in question https://ask.libreoffice.org/t/print-page-number-changes-the-size-zoom-of-the-print-area/114841

 In the attached ods if I select a different printer I can see immediately in the print dialogue that the page count goes from 4 to 8 even though page 1 remains showing as landscape. Previewing the next page in the print dialogue shows it has reverted to portrait.
The entire document is printed in portrait, including page 1 which previewed as Landscape

I see the effect in 24.8.3.2 but not in 24.2.4.2. 

Version: 24.8.3.2 (X86_64) / LibreOffice Community
Build ID: 48a6bac9e7e268aeb4c3483fcf825c94556d9f92
CPU threads: 8; OS: Windows 11 X86_64 (10.0 build 22631); UI render: Skia/Raster; VCL: win
Locale: en-NZ (en_NZ); UI: en-GB
Calc: CL threaded
Comment 5 Buovjaga 2024-12-12 08:19:05 UTC
(In reply to Alistair Saywell from comment #4)
> I see the effect in 24.8.3.2 but not in 24.2.4.2. 

That contradicts what Gábor said in comment 0, that it started with 6.3 (as a side-effct of print dialog rework?). Let's set to new anyway, but Alistair: it would be good, if you did a bibisect with the win64-24.8 repository https://wiki.documentfoundation.org/QA/Bibisect/Windows

Here is my tutorial: https://wiki.documentfoundation.org/QA/Bibisect/Bibisecting_tutorial

Let me know, if you need guidance.
Comment 6 V Stuart Foote 2025-03-17 14:45:28 UTC
*** Bug 165686 has been marked as a duplicate of this bug. ***
Comment 7 V Stuart Foote 2025-03-17 14:48:30 UTC
from dupe bug 165686

Confirmed.

(In reply to henning.witte bug 165686#c4)

OK, so if I understand correctly, the issue occurs within in the Print... dialog.

Where, if making a change in printer selection from the list box of available printers, the printer mode does not follow the Page... format defined for the document and in parsing an 'Automatic' mode it ends up in Portrait mode rather than Landscape.

The page properties for the document, sc Calc sheets in this case, should be read and update the Print dialog and Print preview panels with layout correct for the document pages--and that the 'Automatic' detection is not functioning as needed when changing printer selection.

=-testing-=

Version: 25.2.1.2 (X86_64) / LibreOffice Community
Build ID: d3abf4aee5fd705e4a92bba33a32f40bc4e56f49
CPU threads: 28; OS: Windows 11 X86_64 (10.0 build 26100); UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded

Version: 25.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: f8a08b2515342e6ef9d91865bb5262640f81703f
CPU threads: 28; OS: Windows 11 X86_64 (build 26100); UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded