The paper tray selected in the page style dialog is not saved in RTF and DOCX files.
Oliver Specht committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/8b191a6566065438417665af32fa30f8346ad4df tdf#159793 Save printer paper tray in RTF and DOCX It will be available in 24.8.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.
Oliver Specht committed a patch related to this issue. It has been pushed to "libreoffice-24-2": https://git.libreoffice.org/core/commit/e3fed54f866ac6880c9977d800aa455d3d37de5d tdf#159793 Save printer paper tray in RTF and DOCX It will be available in 24.2.2. 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.
Reproduced with RTF in: Version: 7.6.5.2 (X86_64) / LibreOffice Community Build ID: 38d5f62f85355c192ef5f1dd47c5c0c0c6d6598b CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: gtk3 Locale: en-AU (en_AU.UTF-8); UI: en-US Calc: threaded After printing once, the printer's trays are listed in the Page Style dialog. Choosing one persists after a save-reload for ODT, but not RTF.
Tested with the RTF and DOCX examples from bug 159254, export seems to work in both formats, and Word 16 opens the files correctly in: Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: e939685f9c6918830bd3097062790bfccbce937e CPU threads: 15; OS: Windows 10.0 Build 19045; UI render: default; VCL: win Locale: hu-HU (hu_HU); UI: en-US Calc: default