Bug 154959 - Brother QL500 / QL570 / QL700 label printers no longer rotate to landscape (Arch / Manjaro)
Summary: Brother QL500 / QL570 / QL700 label printers no longer rotate to landscape (A...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
7.5.0.3 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:25.2.0 target:24.8.1
Keywords: bibisected, bisected, regression
: 157213 158614 160996 161130 (view as bug list)
Depends on:
Blocks: Print
  Show dependency treegraph
 
Reported: 2023-04-21 17:55 UTC by basd1
Modified: 2024-08-19 17:19 UTC (History)
9 users (show)

See Also:
Crash report or crash signature:


Attachments
File dialog on Ubuntu 23.10. Expected behavior and prints correctly. (deleted)
2024-01-18 20:38 UTC, rudderduck
Details
File dialog on Ubuntu 23.10. Expected behavior and prints correctly. (73.93 KB, image/png)
2024-01-18 20:39 UTC, rudderduck
Details
File dialog on Archlinux. Unexpected behavior and prints according to incorrect preview (66.62 KB, image/png)
2024-01-18 20:53 UTC, rudderduck
Details
example document (10.70 KB, application/vnd.oasis.opendocument.text)
2024-08-03 20:40 UTC, Caolán McNamara
Details
Brother QL500 PPD with which I could reproduce (20.24 KB, application/vnd.cups-ppd)
2024-08-03 20:41 UTC, Caolán McNamara
Details

Note You need to log in before you can comment on or make changes to this bug.
Description basd1 2023-04-21 17:55:10 UTC
I have been printing labels to my Brother QL700 via LibreOffice for some time. It no longer will "rotate" to landscape and therefore I cannot print labels. This seems to have started with version 7.5.2.1. I am updated to 7.5.2.2, the latest available from OpenSuse Tumbleweed. I have verified the problem is not in the ppd file, as I can print labels to the printer via a Gnome program called "glabel". For some time, my LibreOffice label files have "saved" the necessary parameters and simply typing a new label has worked fine. Now, the same files will not print correctly, the label displays in "portrait" no matter what settings I change. I have tried "use only paper settings from printer preferences", "Printer language type > Postscript (Level from Driver)" and changing to "landscape" under both printer properties and the general print dialog tab. The correct label size displays in the print dialog, but it is in portrait instead of landscape, while the text is correctly in landscape (but only partially on the label). I have tried additional paper sizes, but the only paper dimensions are given for a portrait label and not a landscape one. The labels continue to display correctly in the wordprocessing/editing function, the errors are all in the print dialog. I tried printing in the hope that only the preview is wrong, but I cannot print a valid label.
Comment 1 Stéphane Guillou (stragu) 2023-05-30 22:51:27 UTC
- Can you please test in safe mode with Help > Restart in Safe Mode, to see if the issue persists?
- Do you know which is the last LO version that worked as expected?

To be clear:
- your document page style is in landscape orientation
- the orientation setting in the print dialog is landscape
- however, the preview in the print dialog remains in portrait orientation (with contents not fitting on the page)
- the paper print comes out just like on the preview

Is that correct?
Comment 2 Stéphane Guillou (stragu) 2023-09-27 17:16:24 UTC
*** Bug 157213 has been marked as a duplicate of this bug. ***
Comment 3 Stéphane Guillou (stragu) 2023-09-27 17:19:04 UTC
Confirming via duplicate bug 157213, same issue with a Brother QL500 in LO 7.5.6.2 and 7.6.0.3.
Comment 4 rudderduck 2024-01-18 20:38:11 UTC Comment hidden (obsolete)
Comment 5 rudderduck 2024-01-18 20:39:36 UTC
Created attachment 192046 [details]
File dialog on Ubuntu 23.10. Expected behavior and prints correctly.
Comment 6 rudderduck 2024-01-18 20:53:33 UTC
Created attachment 192048 [details]
File dialog on Archlinux. Unexpected behavior and prints according to incorrect preview

The error seems not related to the version of LO. Rather it seems to depend on the used Linux distribution. Both screenshots are taken with LO 7.6.4.1.

Sorry for the duplicate screenshot, I am unable to delete it or change the picture.
Comment 7 Stéphane Guillou (stragu) 2024-01-19 11:25:10 UTC Comment hidden (obsolete)
Comment 8 Stéphane Guillou (stragu) 2024-01-19 11:28:40 UTC
Thanks for screenshots. I've deleted one duplicate.

@Buovjaga, any insights regarding Arch?
Comment 9 Buovjaga 2024-01-19 12:10:40 UTC
(In reply to Stéphane Guillou (stragu) from comment #8)
> Thanks for screenshots. I've deleted one duplicate.
> 
> @Buovjaga, any insights regarding Arch?

I don't know how to test the driver without having the actual printer.

If this is a regression in 7.5, the printers owners could bibisect it with the 7.5 repository:

https://wiki.documentfoundation.org/QA/Bibisect
https://wiki.documentfoundation.org/QA/Bibisect/Linux
Comment 10 documentfoundation 2024-01-19 17:46:04 UTC
@Buovjaga 
> I don't know how to test the driver without having the actual printer.

I don't have my QL500 connected and the preview is already broken after chosing the printer type and dimensions. The preview and the print are identical AFAIK. So just focus on the preview. You probably don't need the printer hardware to verify the issue.
Comment 11 Stéphane Guillou (stragu) 2024-05-16 10:49:05 UTC
*** Bug 161130 has been marked as a duplicate of this bug. ***
Comment 12 Stéphane Guillou (stragu) 2024-05-16 11:01:20 UTC
Brother QL570 also affected in duplicate bug 161130.

For anyone affected, as in comment 0, please confirm that you have tested other recommended solutions:
- ticking "use only paper settings from printer preferences" setting[1]
- using "Postcript (Level from Driver)"[2]

[1]: https://ask.libreoffice.org/t/unable-to-change-print-paper-size-to-print-labels/27082
[2]: https://www.brother.co.uk/support/ql700/faqs/troubleshooting/faqp00100435_000

If one of you is able to, please try bibisecting the issue: https://bibisect.libreoffice.org/
Or at least confirm that it is a regression by seeing if it worked as expected with LO 7.4 (or ealier): https://downloadarchive.documentfoundation.org/libreoffice/old/
Comment 13 Dr. Martinus 2024-05-18 08:54:32 UTC
I don't understand how to do bibisecting, else I would try. I know it works fine using OpenOffice, and it worked fine in LO before I switched to OpenOffice for a while which was around the end of 2023, or early 2024. Maybe you can pinpoint it with the help of this info.
I played around with the settings, the preview always remains the same (i.e.portrait mode). I changed the orientation in the printer settings, save, and when I get back into the printer settings, the orientation is again in portrait mode, even though I had changed and saved it in landscape mode. The LO print dialog shows always landscape mode, probably because the document is in landscape orientation. The preview remains always in portrait orientation. I noticed that paper size changes: in LO print dialogue it is set to some other format (17x54 mm). 
I close the LO print dialog, open it again, the orientation says "auto", the paper size is empty. I set that to 62x100 mm, then I enter landscape mode, preview stays in portrait mode. When I then turn back to auto, the preview turns the sheet around to landscape, but the print begins somewhere to the left of the sheet, so that again the printout is cut off. I would say left margin something around -20 mm, top margin +20 mm, i.e. the print has moved downwards, the last lines are cut off.
Just for info: my label printer is QL 570.
Comment 14 Buovjaga 2024-05-18 11:08:22 UTC
(In reply to Dr. Martinus from comment #13)
> I don't understand how to do bibisecting, else I would try. I know it works
> fine using OpenOffice, and it worked fine in LO before I switched to
> OpenOffice for a while which was around the end of 2023, or early 2024.
> Maybe you can pinpoint it with the help of this info.

It is impossible to pinpoint without the printer or until some other way to reproduce appears.

Steps to test with 7.5 on Linux:

1. wget --continue https://bibisect.libreoffice.org/linux-64-7.5.git-bundle
2. git clone -o bundle linux-64-7.5.git-bundle linux-64-7.5
3. rm ./linux-64-7.5.git-bundle
4. cd ./linux-64-7.5
5. git remote remove bundle
6. git checkout oldest && instdir/program/soffice
7. Test, if you see the bug. If you don't see it, proceed to next step
8. git checkout master && instdir/program/soffice
9. Test, if you see the bug.

If at step 7 you in fact see the bug, you need to start over from step 1, this time using 7.4 in the steps.

When you have a situation, where you don't see the bug in "oldest", but do see it in "master", you can start bisecting.

git bisect start master oldest && instdir/program/soffice

Whenever you don't see the bug after testing, say
git bisect good && instdir/program/soffice

Whenever you see the bug after testing, say
git bisect bad && instdir/program/soffice

and share the final result in a comment here.
Comment 15 Stéphane Guillou (stragu) 2024-05-24 04:51:43 UTC
*** Bug 160996 has been marked as a duplicate of this bug. ***
Comment 16 Matt 2024-07-26 18:46:28 UTC
Jumping in on this. Having a similar (same?) experience with this but with a Zebra LP 2824 Plus. (https://ask.libreoffice.org/t/page-orientation-incorrect-when-trying-to-print-a-label/108643)

Labels were 2.25" by 1.25". Swapping page dimensions does not help. Checking/unchecking "Use only paper size from printer preferences" did not help.

LibreOffice v24.2.5.2 (X86_64) on Manjaro Linux 6.9.9-1, Xfce 4.18.

Happened to me in Writer and Draw, a CUPS test page and gLabels print fine.

I can provide more information if this helps.
Ran (hopefully correctly because I have no idea!) git bibisect and maybe learned something:
 f3ab94bc09f3707cc0463d1d7e35e1fe3e9e47e5 is the first bad commit
commit f3ab94bc09f3707cc0463d1d7e35e1fe3e9e47e5 (HEAD)
Author: Jenkins Build User <tdf@pollux.tdf>
Date:   Thu Sep 22 19:44:17 2022 +0200

    source 3805a4090dbbffa54bb1a9d7fe63e723fc6d029b
    
    source 3805a4090dbbffa54bb1a9d7fe63e723fc6d029b

 instdir/program/libvcllo.so | Bin 19250328 -> 19250264 bytes
 instdir/program/setuprc     |   2 +-
 instdir/program/versionrc   |   2 +-
 3 files changed, 2 insertions(+), 2 deletions(-)
javaldx: Could not find a Java Runtime Environment!
Warning: failed to read path from javaldx
Comment 17 Buovjaga 2024-07-26 19:45:17 UTC
Thanks, Matt. That looks relevant indeed as it's touching PPD parsing code.
Comment 18 Stéphane Guillou (stragu) 2024-07-29 03:32:04 UTC
Also note regression bug 154975 which was bibisected to the child commit 6005aec, also by Caolán. Might be worth looking into the two issues as a whole.
Comment 19 Caolán McNamara 2024-08-03 20:40:50 UTC
Created attachment 195684 [details]
example document
Comment 20 Caolán McNamara 2024-08-03 20:41:54 UTC
Created attachment 195685 [details]
Brother QL500 PPD with which I could reproduce
Comment 21 Caolán McNamara 2024-08-03 21:04:01 UTC
https://gerrit.libreoffice.org/c/core/+/171449 looks promising
Comment 22 Commit Notification 2024-08-04 13:41:10 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/f1b582772bb47fb421886fa268d469c1b5ba41bb

Resolves: tdf#154959 label printers no longer rotate

It will be available in 25.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 23 Dr. Martinus 2024-08-07 07:08:34 UTC
Just to let you know:
The problem still exists with the following version.

Version: 7.6.7.2 (X86_64) / LibreOffice Community
Build ID: 60(Build:2)
CPU threads: 12; OS: Linux 6.6; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.UTF-8); UI: de-DE
7.6.7-1
Calc: threaded

System: 

Operating System: Manjaro Linux 
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.4.0
Qt Version: 6.7.2
Kernel Version: 6.6.41-1-MANJARO (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 2600 Six-Core Processor
Memory: 31.3 GiB of RAM
Graphics Processor: AMD Radeon RX 570 Series
Manufacturer: Micro-Star International Co., Ltd.
Product Name: MS-7B79
System Version: 1.0

I can print the file without problems in proper orientation with OpenOffice 4.1.15.
Comment 24 Stéphane Guillou (stragu) 2024-08-07 07:11:11 UTC
(In reply to Dr. Martinus from comment #23)
> Just to let you know:
> The problem still exists with the following version.
> Version: 7.6.7.2 (X86_64) / LibreOffice Community
That is expected, as the fix is only currently in master, and 7.6 has already reached end of life.
It would be very much appreciated if you could instead test the fix with a recent daily build (which will install in parallel to your current version): https://dev-builds.libreoffice.org/daily/master/current.html
Comment 25 Buovjaga 2024-08-07 07:12:04 UTC
Linux users might use the appimage method: https://wiki.documentfoundation.org/Installing_in_parallel/Linux#Automated_installation
Comment 26 Caolán McNamara 2024-08-10 20:06:52 UTC
done in trunk, backport to 24-8 in gerrit
Comment 27 Commit Notification 2024-08-11 12:25:29 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/6900c51a1054cd12179f4ad15ba8d5768b43afca

Resolves: tdf#154959 label printers no longer rotate

It will be available in 24.8.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 28 Commit Notification 2024-08-11 14:23:47 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/f736e3a0c23acf908462bfd184e1224c78244224

Related: tdf#154959 suitable label printer paper size not auto-selected

It will be available in 25.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 29 Caolán McNamara 2024-08-19 15:45:36 UTC
*** Bug 158614 has been marked as a duplicate of this bug. ***
Comment 30 raal 2024-08-19 17:19:08 UTC
(In reply to Caolán McNamara from comment #29)
> *** Bug 158614 has been marked as a duplicate of this bug. ***

Verified with Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 1565181908a06dcdb8d97d6be8ff773acd1d05cb
CPU threads: 4; OS: Linux 6.5; UI render: default; VCL: gtk3
Locale: cs-CZ (cs_CZ.UTF-8); UI: en-US
Calc: threaded

Caolán, thank you for the fix.