5

I want GEdit to show all paragraphs in right-to-left view. I know that it renders paragraphs starting with rtl characters correctly. But I need paragraphs starting with ltr characters also shown as rtl.

Something like vim -F or set: rl command in Vim.n

1 Answer 1

6

You can force a paragraph to be RTL by adding Unicode control U+200F RIGHT-TO-LEFT MARK (RLM) to the beginning of the paragraph. Using:

Crtl+Shift+u Then 200f Enter

For easy entry, you may have to customize you keyboard layout. See reference.

There are more Unicode control characters:

  • U+200E LEFT-TO-RIGHT MARK (LRM), To do the reverse on a right-to-left environment.
  • U+061C ARABIC LETTER MARK (ALM), Note: Most users uses RLM instead which is more general and it works for Arabic scripts too.
  • More at Wikipedia: Bidirectional Text.

References:

1
  • 1
    Just one thing should be noted: this solution is not suitable if you don't want the text to be modified. using this approach might have side effect in other situations. This solution is not changing GEdit behavior but altering the text. This should be noted and kept in mind while applying this answer. Feb 14, 2021 at 8:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .