guides icon indicating copy to clipboard operation
guides copied to clipboard

Ability to specify text language in ReST

Open mabolek opened this issue 1 month ago • 2 comments

Feature request

It would be great to be able to specify text language for blocks of text in ReST.

This could for example be achieved with .. role:: language(nb) to set the language to Norwegian Bokmål (ISO code nb). An inline version of this would also be great. Maybe Example in Norwegian is :language(nb):`eksempel`

mabolek avatar Nov 18 '25 14:11 mabolek

Thanks for your request. I do not fully understand what is need in the output. Why would one set the language of a text? How would this reflect in the output?

jaapio avatar Nov 19 '25 20:11 jaapio

In HTML, it would change the lang attribute of the surrounding tag. For example, it would change the language of text readers (for accessibility) and change the language interpreted by search engines, so homonymous keywords are not mixed up.

mabolek avatar Nov 20 '25 08:11 mabolek