filter/qa/unit/data/tdf91315.fodp |  429 ++++++++++++++++++++++++++++++++++++++
 filter/qa/unit/svg.cxx            |   15 +
 filter/source/svg/svgwriter.cxx   |   10 
 3 files changed, 454 insertions(+)

New commits:
commit 3e985bc26b4d57b390b34e48ef1c51f48151e455
Author:     Jonathan Clark <jonat...@libreoffice.org>
AuthorDate: Wed Nov 20 08:16:40 2024 -0700
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Thu Nov 21 09:22:05 2024 +0100

    tdf#91315 Implemented RTL support for SVG export
    
    Previously, the direction attribute was not set on text tags when
    exporting RTL text to SVG. This change adds the missing attribute.
    
    Change-Id: I57770c1cc44f10c3c43ccac2f5a17c1422c34d35
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176869
    Tested-by: Jenkins
    Reviewed-by: Jonathan Clark <jonat...@libreoffice.org>
    (cherry picked from commit 235aebe31e6ba32a7ffc6a960396f651bdaa6ae3)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176875
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/filter/qa/unit/data/tdf91315.fodp 
b/filter/qa/unit/data/tdf91315.fodp
new file mode 100644
index 000000000000..a3d472fc1613
--- /dev/null
+++ b/filter/qa/unit/data/tdf91315.fodp
@@ -0,0 +1,429 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<office:document 
xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0" 
xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0" 
xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:ooow="http://ope
 noffice.org/2004/writer" xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:officeooo="http://openoffice.org/2009/office"; 
xmlns:table="urn:oasis:names:tc:opendocument:x
 mlns:table:1.0" 
xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 office:version="1.4" 
office:mimetype="application/vnd.oasis.opendocument.presentation">
+ 
<office:meta><meta:creation-date>2015-05-16T06:24:54.783324675</meta:creation-date><dc:date>2015-05-16T06:26:35.675435300</dc:date><meta:editing-duration>PT43S</meta:editing-duration><meta:editing-cycles>1</meta:editing-cycles><meta:generator>LibreOfficeDev/25.2.0.0.alpha0$Linux_X86_64
 
LibreOffice_project/8392aa55baf949d7fecfcce56499256866ba5de9</meta:generator><meta:document-statistic
 meta:object-count="24"/></office:meta>
+ <office:font-face-decls>
+  <style:font-face style:name="DejaVu Sans" svg:font-family="'DejaVu Sans'" 
style:font-family-generic="system" style:font-pitch="variable"/>
+  <style:font-face style:name="FreeSans" svg:font-family="FreeSans" 
style:font-family-generic="system" style:font-pitch="variable"/>
+  <style:font-face style:name="Liberation Sans" svg:font-family="'Liberation 
Sans'" style:font-family-generic="roman" style:font-pitch="variable"/>
+  <style:font-face style:name="Liberation Serif" svg:font-family="'Liberation 
Serif'" style:font-family-generic="roman" style:font-pitch="variable"/>
+  <style:font-face style:name="Noto Sans Hebrew" svg:font-family="'Noto Sans 
Hebrew'" style:font-family-generic="swiss" style:font-pitch="variable"/>
+  <style:font-face style:name="Noto Sans Hebrew1" svg:font-family="'Noto Sans 
Hebrew'" style:font-adornments="Regular" style:font-family-generic="swiss" 
style:font-pitch="variable"/>
+  <style:font-face style:name="Noto Sans1" svg:font-family="'Noto Sans'" 
style:font-adornments="Regular" style:font-family-generic="swiss" 
style:font-pitch="variable"/>
+ </office:font-face-decls>
+ <office:styles>
+  <style:default-style style:family="graphic">
+   <style:graphic-properties svg:stroke-color="#3465a4" 
draw:fill-color="#729fcf" fo:wrap-option="no-wrap" style:writing-mode="lr-tb"/>
+   <style:paragraph-properties style:text-autospace="ideograph-alpha" 
style:punctuation-wrap="simple" style:line-break="strict" 
loext:tab-stop-distance="0cm" style:font-independent-line-spacing="false">
+    <style:tab-stops/>
+   </style:paragraph-properties>
+   <style:text-properties style:use-window-font-color="true" 
loext:opacity="0%" style:font-name="Liberation Serif" fo:font-size="24pt" 
fo:language="en" fo:country="US" style:font-name-asian="DejaVu Sans" 
style:font-size-asian="24pt" style:language-asian="zh" style:country-asian="CN" 
style:font-name-complex="DejaVu Sans" style:font-size-complex="24pt" 
style:language-complex="hi" style:country-complex="IN"/>
+  </style:default-style>
+  <style:style style:name="standard" style:family="graphic">
+   <style:graphic-properties draw:stroke="solid" svg:stroke-width="0cm" 
svg:stroke-color="#3465a4" draw:marker-start-width="0.2cm" 
draw:marker-start-center="false" draw:marker-end-width="0.2cm" 
draw:marker-end-center="false" draw:fill="solid" draw:fill-color="#729fcf" 
draw:textarea-horizontal-align="justify" fo:padding-top="0.125cm" 
fo:padding-bottom="0.125cm" fo:padding-left="0.25cm" fo:padding-right="0.25cm" 
draw:shadow="hidden" draw:shadow-offset-x="0.2cm" draw:shadow-offset-y="0.2cm" 
draw:shadow-color="#808080">
+    <text:list-style style:name="standard">
+     <text:list-level-style-bullet text:level="1" text:bullet-char="●">
+      <style:list-level-properties text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="2" text:bullet-char="●">
+      <style:list-level-properties text:space-before="0.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="3" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="4" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="5" text:bullet-char="●">
+      <style:list-level-properties text:space-before="2.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="6" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="7" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="8" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="9" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="10" text:bullet-char="●">
+      <style:list-level-properties text:space-before="5.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+    </text:list-style>
+   </style:graphic-properties>
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" 
fo:margin-top="0cm" fo:margin-bottom="0cm" fo:line-height="100%" 
fo:text-indent="0cm"/>
+   <style:text-properties fo:font-variant="normal" fo:text-transform="none" 
style:use-window-font-color="true" loext:opacity="0%" 
style:text-outline="false" style:text-line-through-style="none" 
style:text-line-through-type="none" style:font-name="Liberation Sans" 
fo:font-family="'Liberation Sans'" style:font-family-generic="roman" 
style:font-pitch="variable" fo:font-size="18pt" fo:font-style="normal" 
fo:text-shadow="none" style:text-underline-style="none" fo:font-weight="normal" 
style:letter-kerning="true" style:font-name-asian="DejaVu Sans" 
style:font-family-asian="'DejaVu Sans'" 
style:font-family-generic-asian="system" style:font-pitch-asian="variable" 
style:font-size-asian="18pt" style:font-style-asian="normal" 
style:font-weight-asian="normal" style:font-name-complex="FreeSans" 
style:font-family-complex="FreeSans" style:font-family-generic-complex="system" 
style:font-pitch-complex="variable" style:font-size-complex="18pt" 
style:font-style-complex="normal" style:font-weight-comple
 x="normal" style:text-emphasize="none" style:font-relief="none" 
style:text-overline-style="none" style:text-overline-color="font-color"/>
+  </style:style>
+  <style:style style:name="Default-backgroundobjects" 
style:family="presentation">
+   <style:graphic-properties draw:textarea-horizontal-align="justify" 
draw:shadow="hidden" draw:shadow-offset-x="0.2cm" draw:shadow-offset-y="0.2cm" 
draw:shadow-color="#808080"/>
+   <style:text-properties style:letter-kerning="true"/>
+  </style:style>
+  <style:style style:name="Default-notes" style:family="presentation">
+   <style:graphic-properties draw:stroke="none" draw:fill="none"/>
+   <style:paragraph-properties fo:margin-left="0.6cm" fo:margin-right="0cm" 
fo:text-indent="-0.6cm"/>
+   <style:text-properties fo:font-variant="normal" fo:text-transform="none" 
style:use-window-font-color="true" loext:opacity="0%" 
style:text-outline="false" style:text-line-through-style="none" 
style:text-line-through-type="none" style:font-name="Liberation Sans" 
fo:font-family="'Liberation Sans'" style:font-family-generic="roman" 
style:font-pitch="variable" fo:font-size="20pt" fo:font-style="normal" 
fo:text-shadow="none" style:text-underline-style="none" fo:font-weight="normal" 
style:letter-kerning="true" fo:background-color="#ffffff" 
style:font-name-asian="DejaVu Sans" style:font-family-asian="'DejaVu Sans'" 
style:font-family-generic-asian="system" style:font-pitch-asian="variable" 
style:font-size-asian="20pt" style:font-style-asian="normal" 
style:font-weight-asian="normal" style:font-name-complex="FreeSans" 
style:font-family-complex="FreeSans" style:font-family-generic-complex="system" 
style:font-pitch-complex="variable" style:font-size-complex="20pt" 
style:font-style-complex="no
 rmal" style:font-weight-complex="normal" style:text-emphasize="none" 
style:font-relief="none" style:text-overline-style="none" 
style:text-overline-color="font-color"/>
+  </style:style>
+  <style:style style:name="Default-outline1" style:family="presentation">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:auto-grow-height="false" draw:fit-to-size="false" 
style:shrink-to-fit="true">
+    <text:list-style style:name="Default-outline1">
+     <text:list-level-style-bullet text:level="1" text:bullet-char="●">
+      <style:list-level-properties text:space-before="0.3cm" 
text:min-label-width="0.9cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="2" text:bullet-char="–">
+      <style:list-level-properties text:space-before="1.5cm" 
text:min-label-width="0.9cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="75%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="3" text:bullet-char="●">
+      <style:list-level-properties text:space-before="2.8cm" 
text:min-label-width="0.8cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="4" text:bullet-char="–">
+      <style:list-level-properties text:space-before="4.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="75%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="5" text:bullet-char="●">
+      <style:list-level-properties text:space-before="5.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="6" text:bullet-char="●">
+      <style:list-level-properties text:space-before="6.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="7" text:bullet-char="●">
+      <style:list-level-properties text:space-before="7.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="8" text:bullet-char="●">
+      <style:list-level-properties text:space-before="9cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="9" text:bullet-char="●">
+      <style:list-level-properties text:space-before="10.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="10" text:bullet-char="●">
+      <style:list-level-properties text:space-before="11.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+    </text:list-style>
+   </style:graphic-properties>
+   <style:paragraph-properties fo:margin-top="0.5cm" fo:margin-bottom="0cm"/>
+   <style:text-properties fo:font-variant="normal" fo:text-transform="none" 
style:use-window-font-color="true" loext:opacity="0%" 
style:text-outline="false" style:text-line-through-style="none" 
style:text-line-through-type="none" style:font-name="Liberation Sans" 
fo:font-family="'Liberation Sans'" style:font-family-generic="roman" 
style:font-pitch="variable" fo:font-size="32pt" fo:font-style="normal" 
fo:text-shadow="none" style:text-underline-style="none" fo:font-weight="normal" 
style:letter-kerning="true" fo:background-color="#ffffff" 
style:font-name-asian="DejaVu Sans" style:font-family-asian="'DejaVu Sans'" 
style:font-family-generic-asian="system" style:font-pitch-asian="variable" 
style:font-size-asian="32pt" style:font-style-asian="normal" 
style:font-weight-asian="normal" style:font-name-complex="FreeSans" 
style:font-family-complex="FreeSans" style:font-family-generic-complex="system" 
style:font-pitch-complex="variable" style:font-size-complex="32pt" 
style:font-style-complex="no
 rmal" style:font-weight-complex="normal" style:text-emphasize="none" 
style:font-relief="none" style:text-overline-style="none" 
style:text-overline-color="font-color"/>
+  </style:style>
+  <style:style style:name="Default-subtitle" style:family="presentation">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:textarea-vertical-align="middle">
+    <text:list-style style:name="Default-subtitle">
+     <text:list-level-style-bullet text:level="1" text:bullet-char="●">
+      <style:list-level-properties text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="2" text:bullet-char="●">
+      <style:list-level-properties text:space-before="0.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="3" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="4" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="5" text:bullet-char="●">
+      <style:list-level-properties text:space-before="2.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="6" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="7" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="8" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="9" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="10" text:bullet-char="●">
+      <style:list-level-properties text:space-before="5.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+    </text:list-style>
+   </style:graphic-properties>
+   <style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" 
fo:text-align="center" fo:text-indent="0cm"/>
+   <style:text-properties fo:font-variant="normal" fo:text-transform="none" 
style:use-window-font-color="true" loext:opacity="0%" 
style:text-outline="false" style:text-line-through-style="none" 
style:text-line-through-type="none" style:font-name="Liberation Sans" 
fo:font-family="'Liberation Sans'" style:font-family-generic="roman" 
style:font-pitch="variable" fo:font-size="32pt" fo:font-style="normal" 
fo:text-shadow="none" style:text-underline-style="none" fo:font-weight="normal" 
style:letter-kerning="true" fo:background-color="#ffffff" 
style:font-name-asian="DejaVu Sans" style:font-family-asian="'DejaVu Sans'" 
style:font-family-generic-asian="system" style:font-pitch-asian="variable" 
style:font-size-asian="32pt" style:font-style-asian="normal" 
style:font-weight-asian="normal" style:font-name-complex="FreeSans" 
style:font-family-complex="FreeSans" style:font-family-generic-complex="system" 
style:font-pitch-complex="variable" style:font-size-complex="32pt" 
style:font-style-complex="no
 rmal" style:font-weight-complex="normal" style:text-emphasize="none" 
style:font-relief="none" style:text-overline-style="none" 
style:text-overline-color="font-color"/>
+  </style:style>
+  <style:style style:name="Default-title" style:family="presentation">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:textarea-vertical-align="middle">
+    <text:list-style style:name="Default-title">
+     <text:list-level-style-bullet text:level="1" text:bullet-char="●">
+      <style:list-level-properties text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="2" text:bullet-char="●">
+      <style:list-level-properties text:space-before="0.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="3" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="4" text:bullet-char="●">
+      <style:list-level-properties text:space-before="1.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="5" text:bullet-char="●">
+      <style:list-level-properties text:space-before="2.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="6" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="7" text:bullet-char="●">
+      <style:list-level-properties text:space-before="3.6cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="8" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.2cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="9" text:bullet-char="●">
+      <style:list-level-properties text:space-before="4.8cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+     <text:list-level-style-bullet text:level="10" text:bullet-char="●">
+      <style:list-level-properties text:space-before="5.4cm" 
text:min-label-width="0.6cm"/>
+      <style:text-properties fo:font-family="StarSymbol" 
style:use-window-font-color="true" fo:font-size="45%"/>
+     </text:list-level-style-bullet>
+    </text:list-style>
+   </style:graphic-properties>
+   <style:paragraph-properties fo:text-align="center"/>
+   <style:text-properties fo:font-variant="normal" fo:text-transform="none" 
style:use-window-font-color="true" loext:opacity="0%" 
style:text-outline="false" style:text-line-through-style="none" 
style:text-line-through-type="none" style:font-name="Noto Sans1" 
fo:font-family="'Noto Sans'" style:font-style-name="Regular" 
style:font-family-generic="swiss" style:font-pitch="variable" 
fo:font-size="44pt" fo:font-style="normal" fo:text-shadow="none" 
style:text-underline-style="none" fo:font-weight="normal" 
style:letter-kerning="true" fo:background-color="#ffffff" 
style:font-name-asian="DejaVu Sans" style:font-family-asian="'DejaVu Sans'" 
style:font-family-generic-asian="system" style:font-pitch-asian="variable" 
style:font-size-asian="44pt" style:language-asian="zxx" 
style:country-asian="none" style:font-style-asian="normal" 
style:font-weight-asian="normal" style:font-name-complex="Noto Sans Hebrew1" 
style:font-family-complex="'Noto Sans Hebrew'" 
style:font-style-name-complex="Regular" styl
 e:font-family-generic-complex="swiss" style:font-pitch-complex="variable" 
style:font-size-complex="44pt" style:language-complex="he" 
style:country-complex="IL" style:font-style-complex="normal" 
style:font-weight-complex="normal" style:text-emphasize="none" 
style:font-relief="none" style:text-overline-style="none" 
style:text-overline-color="font-color"/>
+  </style:style>
+  <style:presentation-page-layout style:name="AL0T26">
+   <presentation:placeholder presentation:object="handout" svg:x="2.058cm" 
svg:y="1.743cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+   <presentation:placeholder presentation:object="handout" svg:x="15.414cm" 
svg:y="1.743cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+   <presentation:placeholder presentation:object="handout" svg:x="2.058cm" 
svg:y="3.612cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+   <presentation:placeholder presentation:object="handout" svg:x="15.414cm" 
svg:y="3.612cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+   <presentation:placeholder presentation:object="handout" svg:x="2.058cm" 
svg:y="5.481cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+   <presentation:placeholder presentation:object="handout" svg:x="15.414cm" 
svg:y="5.481cm" svg:width="10.556cm" svg:height="-0.231cm"/>
+  </style:presentation-page-layout>
+  <style:presentation-page-layout style:name="AL1T0">
+   <presentation:placeholder presentation:object="title" svg:x="2.058cm" 
svg:y="1.743cm" svg:width="23.912cm" svg:height="3.507cm"/>
+   <presentation:placeholder presentation:object="subtitle" svg:x="2.058cm" 
svg:y="5.838cm" svg:width="23.912cm" svg:height="13.23cm"/>
+  </style:presentation-page-layout>
+ </office:styles>
+ <office:automatic-styles>
+  <style:page-layout style:name="PM0">
+   <style:page-layout-properties fo:margin-top="0cm" fo:margin-bottom="0cm" 
fo:margin-left="0cm" fo:margin-right="0cm" fo:page-width="21cm" 
fo:page-height="29.7cm" style:print-orientation="portrait"/>
+  </style:page-layout>
+  <style:page-layout style:name="PM1">
+   <style:page-layout-properties fo:margin-top="0cm" fo:margin-bottom="0cm" 
fo:margin-left="0cm" fo:margin-right="0cm" fo:page-width="28cm" 
fo:page-height="21cm" style:print-orientation="landscape"/>
+  </style:page-layout>
+  <style:style style:name="dp1" style:family="drawing-page">
+   <style:drawing-page-properties draw:background-size="border" 
draw:fill="none"/>
+  </style:style>
+  <style:style style:name="dp2" style:family="drawing-page">
+   <style:drawing-page-properties presentation:display-header="true" 
presentation:display-footer="true" presentation:display-page-number="false" 
presentation:display-date-time="true"/>
+  </style:style>
+  <style:style style:name="dp3" style:family="drawing-page">
+   <style:drawing-page-properties presentation:background-visible="true" 
presentation:background-objects-visible="true" 
presentation:display-footer="true" presentation:display-page-number="false" 
presentation:display-date-time="true"/>
+  </style:style>
+  <style:style style:name="gr1" style:family="graphic" 
style:parent-style-name="standard">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:fill-color="#ffffff" draw:auto-grow-height="false" fo:min-height="1.485cm" 
loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="gr2" style:family="graphic" 
style:parent-style-name="standard">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:fill-color="#ffffff" draw:textarea-vertical-align="bottom" 
draw:auto-grow-height="false" fo:min-height="1.485cm" loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="gr3" style:family="graphic">
+   <style:graphic-properties style:protect="size" loext:decorative="false"/>
+  </style:style>
+  <style:style style:name="pr1" style:family="presentation" 
style:parent-style-name="Default-backgroundobjects">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:fill-color="#ffffff" draw:auto-grow-height="false" fo:min-height="1.449cm" 
loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="pr2" style:family="presentation" 
style:parent-style-name="Default-backgroundobjects">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:fill-color="#ffffff" draw:auto-grow-height="false" fo:min-height="1.485cm" 
loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="pr3" style:family="presentation" 
style:parent-style-name="Default-backgroundobjects">
+   <style:graphic-properties draw:stroke="none" draw:fill="none" 
draw:fill-color="#ffffff" draw:textarea-vertical-align="bottom" 
draw:auto-grow-height="false" fo:min-height="1.485cm" loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="pr4" style:family="presentation" 
style:parent-style-name="Default-subtitle">
+   <style:graphic-properties draw:fill-color="#ffffff" 
fo:min-height="12.179cm" loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="pr5" style:family="presentation" 
style:parent-style-name="Default-notes">
+   <style:graphic-properties draw:fill-color="#ffffff" 
fo:min-height="13.364cm" loext:decorative="false"/>
+   <style:paragraph-properties style:writing-mode="lr-tb"/>
+  </style:style>
+  <style:style style:name="P1" style:family="paragraph">
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P2" style:family="paragraph">
+   <loext:graphic-properties draw:fill="none" draw:fill-color="#ffffff"/>
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P3" style:family="paragraph">
+   <style:paragraph-properties fo:text-align="end"/>
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P4" style:family="paragraph">
+   <loext:graphic-properties draw:fill="none" draw:fill-color="#ffffff"/>
+   <style:paragraph-properties fo:text-align="end"/>
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P5" style:family="paragraph">
+   <style:paragraph-properties fo:text-align="center"/>
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P6" style:family="paragraph">
+   <loext:graphic-properties draw:fill="none" draw:fill-color="#ffffff"/>
+   <style:paragraph-properties fo:text-align="center"/>
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="P7" style:family="paragraph">
+   <style:paragraph-properties style:writing-mode="rl-tb"/>
+   <style:text-properties style:font-name="Noto Sans Hebrew" 
style:font-name-complex="Noto Sans Hebrew"/>
+  </style:style>
+  <style:style style:name="P8" style:family="paragraph">
+   <loext:graphic-properties draw:fill-color="#ffffff"/>
+   <style:text-properties style:font-name="Noto Sans Hebrew" 
style:font-name-complex="Noto Sans Hebrew"/>
+  </style:style>
+  <style:style style:name="P9" style:family="paragraph">
+   <loext:graphic-properties draw:fill-color="#ffffff"/>
+  </style:style>
+  <style:style style:name="T1" style:family="text">
+   <style:text-properties fo:font-size="14pt" style:font-size-asian="14pt" 
style:font-size-complex="14pt"/>
+  </style:style>
+  <style:style style:name="T2" style:family="text">
+   <style:text-properties style:font-name="Noto Sans Hebrew" 
style:font-name-complex="Noto Sans Hebrew"/>
+  </style:style>
+  </office:automatic-styles>
+ <office:master-styles>
+  <draw:layer-set>
+   <draw:layer draw:name="layout"/>
+   <draw:layer draw:name="background"/>
+   <draw:layer draw:name="backgroundobjects"/>
+   <draw:layer draw:name="controls"/>
+   <draw:layer draw:name="measurelines"/>
+  </draw:layer-set>
+  <style:handout-master presentation:presentation-page-layout-name="AL0T26" 
style:page-layout-name="PM0" draw:style-name="dp2">
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="1cm" svg:y="2.898cm"/>
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="1cm" svg:y="11.474cm"/>
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="1cm" svg:y="20.05cm"/>
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="11cm" svg:y="2.898cm"/>
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="11cm" svg:y="11.474cm"/>
+   <draw:page-thumbnail draw:layer="backgroundobjects" svg:width="8.999cm" 
svg:height="6.749cm" svg:x="11cm" svg:y="20.05cm"/>
+   <draw:frame draw:style-name="gr1" draw:text-style-name="P2" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="0cm" svg:y="0cm" presentation:class="header">
+    <draw:text-box>
+     <text:p text:style-name="P1"><text:span 
text:style-name="T1"><presentation:header/></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <draw:frame draw:style-name="gr1" draw:text-style-name="P4" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="11.886cm" svg:y="0cm" presentation:class="date-time">
+    <draw:text-box>
+     <text:p text:style-name="P3"><text:span 
text:style-name="T1"><presentation:date-time/></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <draw:frame draw:style-name="gr2" draw:text-style-name="P2" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="0cm" svg:y="28.215cm" presentation:class="footer">
+    <draw:text-box>
+     <text:p text:style-name="P1"><text:span 
text:style-name="T1"><presentation:footer/></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <draw:frame draw:style-name="gr2" draw:text-style-name="P4" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="11.886cm" svg:y="28.215cm" presentation:class="page-number">
+    <draw:text-box>
+     <text:p text:style-name="P3"><text:span 
text:style-name="T1"><text:page-number>&lt;number&gt;</text:page-number></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+  </style:handout-master>
+  <style:master-page style:name="Default" style:page-layout-name="PM1" 
draw:style-name="dp1">
+   <draw:frame presentation:style-name="Default-title" 
draw:layer="backgroundobjects" svg:width="25.199cm" svg:height="3.506cm" 
svg:x="1.4cm" svg:y="0.837cm" presentation:class="title" 
presentation:placeholder="true">
+    <draw:text-box/>
+   </draw:frame>
+   <draw:frame presentation:style-name="Default-outline1" 
draw:layer="backgroundobjects" svg:width="25.199cm" svg:height="12.179cm" 
svg:x="1.4cm" svg:y="4.914cm" presentation:class="outline" 
presentation:placeholder="true">
+    <draw:text-box/>
+   </draw:frame>
+   <draw:frame presentation:style-name="pr1" draw:text-style-name="P2" 
draw:layer="backgroundobjects" svg:width="6.523cm" svg:height="1.448cm" 
svg:x="1.4cm" svg:y="19.131cm" presentation:class="date-time">
+    <draw:text-box>
+     <text:p text:style-name="P1"><text:span 
text:style-name="T1"><presentation:date-time/></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <draw:frame presentation:style-name="pr1" draw:text-style-name="P6" 
draw:layer="backgroundobjects" svg:width="8.875cm" svg:height="1.448cm" 
svg:x="9.576cm" svg:y="19.131cm" presentation:class="footer">
+    <draw:text-box>
+     <text:p text:style-name="P5"><text:span 
text:style-name="T1"><presentation:footer/></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <draw:frame presentation:style-name="pr1" draw:text-style-name="P4" 
draw:layer="backgroundobjects" svg:width="6.523cm" svg:height="1.448cm" 
svg:x="20.076cm" svg:y="19.131cm" presentation:class="page-number">
+    <draw:text-box>
+     <text:p text:style-name="P3"><text:span 
text:style-name="T1"><text:page-number>&lt;number&gt;</text:page-number></text:span></text:p>
+    </draw:text-box>
+   </draw:frame>
+   <presentation:notes style:page-layout-name="PM0">
+    <draw:page-thumbnail presentation:style-name="Default-title" 
draw:layer="backgroundobjects" svg:width="14.848cm" svg:height="11.136cm" 
svg:x="3.075cm" svg:y="2.257cm" presentation:class="page"/>
+    <draw:frame presentation:style-name="Default-notes" 
draw:layer="backgroundobjects" svg:width="16.799cm" svg:height="13.364cm" 
svg:x="2.1cm" svg:y="14.107cm" presentation:class="notes" 
presentation:placeholder="true">
+     <draw:text-box/>
+    </draw:frame>
+    <draw:frame presentation:style-name="pr2" draw:text-style-name="P2" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="0cm" svg:y="0cm" presentation:class="header">
+     <draw:text-box>
+      <text:p text:style-name="P1"><text:span 
text:style-name="T1"><presentation:header/></text:span></text:p>
+     </draw:text-box>
+    </draw:frame>
+    <draw:frame presentation:style-name="pr2" draw:text-style-name="P4" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="11.886cm" svg:y="0cm" presentation:class="date-time">
+     <draw:text-box>
+      <text:p text:style-name="P3"><text:span 
text:style-name="T1"><presentation:date-time/></text:span></text:p>
+     </draw:text-box>
+    </draw:frame>
+    <draw:frame presentation:style-name="pr3" draw:text-style-name="P2" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="0cm" svg:y="28.215cm" presentation:class="footer">
+     <draw:text-box>
+      <text:p text:style-name="P1"><text:span 
text:style-name="T1"><presentation:footer/></text:span></text:p>
+     </draw:text-box>
+    </draw:frame>
+    <draw:frame presentation:style-name="pr3" draw:text-style-name="P4" 
draw:layer="backgroundobjects" svg:width="9.113cm" svg:height="1.484cm" 
svg:x="11.886cm" svg:y="28.215cm" presentation:class="page-number">
+     <draw:text-box>
+      <text:p text:style-name="P3"><text:span 
text:style-name="T1"><text:page-number>&lt;number&gt;</text:page-number></text:span></text:p>
+     </draw:text-box>
+    </draw:frame>
+   </presentation:notes>
+  </style:master-page>
+ </office:master-styles>
+ <office:body>
+  <office:presentation>
+   <draw:page draw:name="page1" draw:style-name="dp3" 
draw:master-page-name="Default" 
presentation:presentation-page-layout-name="AL1T0">
+    <draw:frame presentation:style-name="pr4" draw:text-style-name="P8" 
draw:layer="layout" svg:width="25.199cm" svg:height="12.179cm" svg:x="1.4cm" 
svg:y="4.914cm" presentation:class="subtitle" 
presentation:user-transformed="true">
+     <draw:text-box>
+      <text:p text:style-name="P7"><text:span text:style-name="T2">בדיקה 
(</text:span><text:span text:style-name="T2">test</text:span><text:span 
text:style-name="T2">)</text:span></text:p>
+     </draw:text-box>
+    </draw:frame>
+    <presentation:notes draw:style-name="dp2">
+     <draw:page-thumbnail draw:style-name="gr3" draw:layer="layout" 
svg:width="14.848cm" svg:height="11.136cm" svg:x="3.075cm" svg:y="2.257cm" 
draw:page-number="1" presentation:class="page"/>
+     <draw:frame presentation:style-name="pr5" draw:text-style-name="P9" 
draw:layer="layout" svg:width="16.799cm" svg:height="13.364cm" svg:x="2.1cm" 
svg:y="14.107cm" presentation:class="notes" presentation:placeholder="true">
+      <draw:text-box/>
+     </draw:frame>
+    </presentation:notes>
+   </draw:page>
+   <presentation:settings presentation:mouse-visible="false"/>
+  </office:presentation>
+ </office:body>
+</office:document>
\ No newline at end of file
diff --git a/filter/qa/unit/svg.cxx b/filter/qa/unit/svg.cxx
index 63b914eb9b7b..a4dd35f14034 100644
--- a/filter/qa/unit/svg.cxx
+++ b/filter/qa/unit/svg.cxx
@@ -369,6 +369,21 @@ CPPUNIT_TEST_FIXTURE(SvgFilterTest, testMapModeText)
     // ahead to get the rotation.
 }
 
+CPPUNIT_TEST_FIXTURE(SvgFilterTest, testTdf91315)
+{
+    // Load a presentation containing RTL text
+    loadFromFile(u"tdf91315.fodp");
+
+    save(u"impress_svg_Export"_ustr);
+
+    xmlDocUniquePtr pXmlDoc = parseExportedFile();
+
+    assertXPath(pXmlDoc, "//svg:text[@direction='rtl']"_ostr, 1);
+    // Without the accompanying fix, this test would have failed with:
+    // - Expected: 1
+    // - Actual  : 0
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index 314f6f315024..6121f773bc33 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -91,6 +91,7 @@ constexpr OUString aXMLAttrOffset = u"offset"_ustr;
 constexpr OUString aXMLAttrStopColor = u"stop-color"_ustr;
 constexpr OUString aXMLAttrStrokeLinejoin = u"stroke-linejoin"_ustr;
 constexpr OUString aXMLAttrStrokeLinecap = u"stroke-linecap"_ustr;
+constexpr OUString aXMLAttrTextDirection = u"direction"_ustr;
 
 
 vcl::PushFlags SVGContextHandler::getPushFlags() const
@@ -1332,6 +1333,15 @@ void SVGTextWriter::startTextShape()
             mrExport.AddAttribute( XML_NAMESPACE_NONE, aXMLAttrTransform, 
aTransform );
         }
 
+        // tdf#91315: Set text direction
+        auto nLayoutMode = mpVDev->GetLayoutMode();
+        if (nLayoutMode
+            & (vcl::text::ComplexTextLayoutFlags::BiDiRtl
+               | vcl::text::ComplexTextLayoutFlags::BiDiStrong))
+        {
+            mrExport.AddAttribute(XML_NAMESPACE_NONE, aXMLAttrTextDirection, 
"rtl");
+        }
+
         mpTextShapeElem.reset(new SvXMLElementExport( mrExport, 
XML_NAMESPACE_NONE, aXMLElemText, true, mbIWS ));
         startTextParagraph();
     }

Reply via email to