The XHTML index.html and content files should use dir="rtl" for Arabic content
See original GitHub issueThe DITA Map has the xml:lang=“ar” set to it. Each topic also has the language set to Arabic. The XHTML generated for each topic contains dir=“rtl” set on the HTML root. But for the TOC the XSL:
DITA-OT/plugins/org.dita.xhtml/xsl/map2htmtoc/map2htmtocImpl.xsl
in the template:
<xsl:template name="generate-toc">
does not generate any attribute for the HTML root element. The “DITA-OT/plugins/org.dita.xhtml/xsl/xslhtml/dita2htmlImpl.xsl” stylesheet defines an XSL template called “bidi-area” which should probably be moved to a common XSLT and used for generting the TOC list of references as well.
Issue Analytics
- State:
- Created 9 years ago
- Comments:21 (21 by maintainers)
Top Results From Across the Web
Handling Right-to-left Scripts in XHTML and HTML Content
Discussion: Values of right and left in attributes need to be converted when translating the document into a language using the Arabic or...
Read more >HTML text-direction regarding arabic content. Is using dir="rtl ...
Its would display the text according to how that language is expected to be, rtl is mearnt for arabic and/or hebrews.
Read more >The dir attribute - OASIS Open
While most languages are written in text where characters flow from left to ... In most cases, authors need to use dir="rtl|ltr" to...
Read more ><bdo>: The Bidirectional Text Override element - HTML
rtl : Indicates that the text should go in a right-to-left direction. Examples. <!-- Switch text direction --> <p> ...
Read more >Symbol Codes | Right to Left (RTL) Scripts - Sites at Penn State
Use the code <html dir="rtl" lang=""> to ensure that all paragraphs and headers are right aligned and that the page language is set...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Double checked - the DITA specification has a normative reference to RFC 5646 for language identification: https://www.rfc-editor.org/rfc/rfc5646.txt
From section 2.1.1 in that RFC:
Thanks Robert.