Created attachment 164018 [details] screenshot of print preveiw. and the ODT file Expected: when the document is RTL,in the 'print preview', the pages should be arranged from Right to Left. but they are arranged from Left to Right. the attached screenshot clarifies this. the ODT file is also attached. Note: the option in (page style) dialog box under ‘page’ tab that says Text Direction to RTL is toggled on.
Created attachment 164019 [details] print_preview screenshot
Dis you search existing RTL bugs before reporting?
(In reply to Timur from comment #2) > Dis you search existing RTL bugs before reporting? yes, to my knowledge this bug has not been reported. if you have more information about the bug, please provide.
The bug is indeed valid. I still wonder if there isn't a dupe. Another point is: It's not clear what exactly should determine the inter-page order in print preview. Obviously, a document with RTL default page style, default paragraph style, and RTL content should be print-previewed with RTL page order by default. But - what if some pages have an LTR style and some an RTL style? What if the default paragraph style doesn't agree with the default page style? Things become less obvious then. I therefore suggest that: 1. The default page ordering during print preview correspond to the default page style's direction. 2. There be some UI for toggling the page order (between LTR and RTL).
(In reply to Eyal Rozenberg from comment #4) > The bug is indeed valid. I still wonder if there isn't a dupe. > > Another point is: It's not clear what exactly should determine the > inter-page order in print preview. Obviously, a document with RTL default > page style, default paragraph style, and RTL content should be > print-previewed with RTL page order by default. But - what if some pages > have an LTR style and some an RTL style? What if the default paragraph style > doesn't agree with the default page style? Things become less obvious then. > > I therefore suggest that: > > 1. The default page ordering during print preview correspond to the default > page style's direction. > 2. There be some UI for toggling the page order (between LTR and RTL). "what if some pages have an LTR style and some an RTL style? What if the default paragraph style doesn't agree with the default page style?" I think this case is very very rare.
(In reply to Eyal Rozenberg from comment #4) > 1. The default page ordering during print preview correspond to the default > page style's direction. What exactly is the page style text direction? Left/Right on the printer layout affects only the page number. Was thinking about the Default Paragraph Style but this shouldn't be used- and you cannot be sure whether Text Body is the actual used default. > 2. There be some UI for toggling the page order (between LTR and RTL). The PS has an option under Alignment but this doesn't affects the print preview neither the multiple-page view. Point is still what we take.
(In reply to Heiko Tietze from comment #6) > (In reply to Eyal Rozenberg from comment #4) > > 1. The default page ordering during print preview correspond to the default > > page style's direction. > > What exactly is the page style text direction? Format->Page Style->Page tab->Text direction. I am generally unsure how to do this best. A toggle button on print preview toolbar? an option... Using default paragraph style direction? also an option, but is guaranteed to create confusion. Follow page style text direction? also seems sane, but then we should allow alternating page order direction inside the document? which might be logical (? I don't know how bi-directional books are created, if any) - like allowing alternating text direction in one paragraph is OK... People really knowledgeable in RTL should decide this, not Englih- (Russian- (myself), German-....) speaking people.
> (? I don't know how > bi-directional books are created, if any) I have no idea how if bi-directional books exist or not. I have not seen any. but here is my opinion: If a document is typed in RTL then pages which follow LTR rules should also be numbered according to RTL and previewed as well. This will make it easier for the RTL reader since the document is essentially written for RTL readers.
(In reply to Mike Kaganski from comment #7) > I am generally unsure how to do this best. A toggle button on print preview > toolbar? a toggle button would be fine to overcome the issues at hand at the moment. if something else turned out to be needed or desired then we can look for a way for it.
(In reply to Safeer Pasha from comment #8) > If a document is typed in RTL then pages which follow LTR rules should also > be numbered according to RTL and previewed as well. Different topic, let's keep this ticket for the print preview/print dialog thumbnail view. My comment 6 was about what property defines whether a _document_ is LTR or RTL: a) Style of the first page (page > text direction; requires tools > options > ctl or cjk enabled) b) Style of the first paragraph (alignment > text direction) c) Document language d) Application locale e) Some toggle in the print preview dialog (that would need a default anyway) I would go with c) meaning Tools > Options > Language Settings > Default Language for Documents. It would show RTL in the print preview even when the entire document is written in English. Adding e) is cheap and might help in this case. While there is enough room for the option in the print preview, it fit's only in the thumbnail of the print dialog. And I would rather not clutter this part. So how about a context menu?
(In reply to Heiko Tietze from comment #10) > I would go with c) meaning Tools > Options > Language Settings > Default > Language for Documents. It would show RTL in the print preview even when the > entire document is written in English. Adding e) is cheap and might help in > this case. While there is enough room for the option in the print preview, > it fit's only in the thumbnail of the print dialog. And I would rather not > clutter this part. So how about a context menu? I agree with option C) and E). I don't know what you mean by this: "it fit's only in the thumbnail of the print dialog. And I would rather not clutter this part. So how about a context menu?"
(In reply to Safeer Pasha from comment #11) > I don't know what you mean by this: > "it fit's only in the thumbnail of the print dialog. It's about the UI. This toggle needs to be realized as radio buttons, checkbox, or whatever, and placed somewhere. My reasoning starts with the fact that the dialog is cluttered and the feature to be introduced is for the preview only. And my conclusion is to "hide" the LTR/RTL selection with radio buttons in a context menu (right click on the thumbnail).
> It's about the UI. This toggle needs to be realized as radio buttons, > checkbox, or whatever, and placed somewhere. My reasoning starts with the > fact that the dialog is cluttered and the feature to be introduced is for > the preview only. And my conclusion is to "hide" the LTR/RTL selection with > radio buttons in a context menu (right click on the thumbnail). your point seems valid. Do as you please as long as the job gets done.
still present Version: 7.0.3.1 Build ID: 00(Build:1) CPU threads: 4; OS: Linux 5.10; UI render: default; VCL: kf5 Locale: en-US (en_US.UTF-8); UI: en-US Calc: threaded
I believe this "inherits" OOo bug 80209: https://bz.apache.org/ooo/show_bug.cgi?id=80209 (if I'm interpreting their term, "page preview", correctly)
I would like to draw our attention to the contrast between page layout with Print Preview, as opposed to the multi-page layout for editing. If we use the menus and navigate to: View > Zoom > Zoom... > (View Layout) Columns and choose more than a single column, for a Default Page Style with RTL text direction, the pages will be laid our right-to-left. I'm not sure exactly what determines the choice of direction there, but - it does work for simple cases at least. So, perhaps the code for print preview can borrow the logic from there. Thanks goes to an anonymous user who pointed this out to me.