sphinx-doc / sphinx-doc/sphinx

Support for RTL Languages

Open
#10,385 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type:enhancement
Dominant language
Python
Stars
8k
Forks
2.6k
PR merge metrics
No merged PRs in 30d

Description

Is your feature request related to a problem? Please describe.
Sphinx has no support for RTL language, which makes it hard to use for global audience that uses languages which RTL (e.g. Hebrew, Farsi, Arabic, ..).

Describe the solution you'd like
We would like to have dir property in the config file.

Describe alternatives you've considered
I'm using CSS tags, but I'd like to change the global dir for the HTML file. For example, changing the lang in the config file result in <html lang="ar"> but I'd like to trigger <html dir="rtl" lang="ar">. I looked in the docs but couldn't find a lead.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the config file's language setting becomes the generated HTML element and where global HTML attributes are assembled. Add support for configuring the document direction so generated pages can include dir="rtl", and verify that the setting works alongside the existing lang behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.