https://bugs.documentfoundation.org/show_bug.cgi?id=161195
Hossein <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|needsDevEval |difficultyMedium, easyHack, | |skillCpp --- Comment #2 from Hossein <[email protected]> --- (In reply to Stéphane Guillou (stragu) from comment #1) > Hossein, wondering if this could be an easyHack? Yes, I think so. Code pointers: Searching for the string "brochure" leads to the constant STR_PRINTOPTUI_BROCHURE: $ git grep -i brochure *.hrc This constant is used in sw/source/core/view/printdata.cxx, which provides such an option in Writer. This part of code is relevant: // check if either CJK or CTL is enabled bool bRTL = SvtCJKOptions::IsCJKFontEnabled() || SvtCTLOptions::IsCTLFontEnabled(); ... if (bRTL) { // create a bool option for brochure RTL dependent on brochure uno::Sequence< OUString > aBRTLChoices{ SwResId( STR_PRINTOPTUI_LEFT_SCRIPT), SwResId( STR_PRINTOPTUI_RIGHT_SCRIPT) }; vcl::PrinterOptionsHelper::UIControlOptions aBrochureRTLOpt( aBrochurePropertyName, -1, true ); uno::Sequence<OUString> aBRTLHelpIds { ".HelpID:vcl:PrintDialog:PrintProspectRTL:ListBox" }; aBrochureRTLOpt.maGroupHint = "LayoutPage"; // RTL brochure choices // 0 : left-to-right // 1 : right-to-left const sal_Int16 nBRTLChoice = rDefaultPrintData.IsPrintProspectRTL() ? 1 : 0; m_aUIProperties[ nIdx++ ].Value = setChoiceListControlOpt("scriptdirection", OUString(), aBRTLHelpIds, "PrintProspectRTL", aBRTLChoices, nBRTLChoice, uno::Sequence< sal_Bool >(), aBrochureRTLOpt); } On the other hand, there is not such thing for LTR/RTL selection in sd/ module, which is relevant here. One can find things related to brochure in sd/ with: $ git grep -i brochure sd/ Most of the things related to preparing the print dialog is done in sd/source/ui/view/DocumentRenderer.cxx in a method named ProcessResource(). Similar code should be added to the last parts of this function. The way brochure direction is used in Writer (sw/) can be a blueprint for implementing the same thing in Draw/Impress (sd/). -- You are receiving this mail because: You are the assignee for the bug.
