Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support right-to-left languages #31

Open
gyscos opened this issue Jun 27, 2016 · 6 comments
Open

Support right-to-left languages #31

gyscos opened this issue Jun 27, 2016 · 6 comments

Comments

@gyscos
Copy link
Owner

gyscos commented Jun 27, 2016

Some languages like Japanese and Chinese can write right-to-left (and/or top to bottom), but are fine with the usual left-to-right orientation.
Other languages like Arabic simply must be written right-to-left (I think?), so we may need some support for those.
Low priority for now, as I know next to nothing about how RTL languages are usually used on terminals.

@adals
Copy link

adals commented Nov 30, 2016

hello

I am native Arabic speaker if you need any help just ask me its my pleasure

@gyscos
Copy link
Owner Author

gyscos commented Nov 30, 2016

Thanks!

Here are a few questions:

  • What terminal are you using? (Very interesting if someone using linux answers that.) Do you need to do anything to enable right-to-left support?
  • Is the command prompt itself right-to-left? Or individual words, for instance $ cd ARABIC_FOLDER, does the folder name itself write right-to-left?
  • With a monospace font (in the terminal), are all characters 1-cell wide (like latin alphabet), or are some 2-cells wide (like some asian alphabets)?

@adals
Copy link

adals commented Aug 4, 2017

sorry for the delay

What terminal are you using?
I am user for Linux Fedora and macOs
i use default terminal i can write arabic language at terminal in easy way

Do you need to do anything to enable right-to-left support?
No

Is the command prompt itself right-to-left? Or individual words, for instance $ cd ARABIC_FOLDER, does the folder name itself write right-to-left?
it shows like we read it like cd ملفاتي not like wrong way from left to right (ي ت ا ف ل م) or (م ل ف ا ت ي) all are wrong but (ملفاتي) is correct from RTL and not separated letters

With a monospace font (in the terminal), are all characters 1-cell wide (like latin alphabet), or are some 2-cells wide (like some asian alphabets)?
i dnt know how do i know?

@gyscos
Copy link
Owner Author

gyscos commented Aug 4, 2017

Hmm interesting...
I am testing using gnome-terminal and konsole here.

  • In konsole, it looks like it prints the name properly:
    screenshot from 2017-08-04 12-21-56
    However, attempting to move the cursor and edit in the middle of the word causes some mess:
    screenshot from 2017-08-04 12-23-05
    Running vim gives a slightly different result:
    screenshot from 2017-08-04 12-24-07
    Running the edit example from cursive has the same result:
    screenshot from 2017-08-04 12-26-00
    Where editing the middle of the words apparently splits it in two:
    screenshot from 2017-08-04 12-26-14
    It seems to be printing ok:
    screenshot from 2017-08-04 12-26-53

  • In gnome-terminal, it's not as good:
    screenshot from 2017-08-04 12-27-57
    screenshot from 2017-08-04 12-28-34
    screenshot from 2017-08-04 12-29-41
    screenshot from 2017-08-04 12-29-47
    It doesn't split the word weirdly when I edit in the middle, mainly because it just always write it left-to-right.

So it's clear already that some terminals have really bad support (gnome-terminal), some have some support (Konsole). In both situation, cursive behaves mostly like vim.

EDIT: Actually, the "split in two" resulting from editing in the middle on Konsole is indeed cursive's fault. I'll see how this can be improved.

@adals
Copy link

adals commented Aug 4, 2017

hello again

i used mac os with edit example and here is the results
the first image it should be in the right side not left side and the shape for the word is perfect

screen shot 2017-08-04 at 11 04 07 pm

the second one we have edited the word from the center(by removing ف letter) and the result is not good for the dialog
screen shot 2017-08-04 at 11 04 25 pm

the third one we have edited the word from the center(by removing ل letter) and the result is good for the dialog its strange problem
screen shot 2017-08-04 at 11 05 22 pm

@mskf1383
Copy link

mskf1383 commented Apr 7, 2022

Hi
Now GNOME Terminal has great support for RTL languages because of VTE. And also every Terminal emulators that use VTE. The only problem that I seen, is when the Bidi is active (is not active by default and can be active by printf "\e[?2501h" command):
نماگرفت از 2022-04-07 18-48-25

The first problem is the reversed shadow. The second is reversed arrows. when I press left arow, It goes right and the same for right arow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants