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

per-file-settings: text direction (RTL/LTR) #1221

Open
mr-islam opened this issue Feb 6, 2021 · 2 comments
Open

per-file-settings: text direction (RTL/LTR) #1221

mr-islam opened this issue Feb 6, 2021 · 2 comments

Comments

@mr-islam
Copy link

mr-islam commented Feb 6, 2021

Hi, I really love Markor and had one feature request:

Auto detection of RTL text and setting RTL direction. (At least in view mode.)

Right now, there's a setting that changes text direction globally for all documents. That's already helpful and better than so many apps that don't event consider RTL.

But the issue is when a user has documents in multiple languages, some RTL and some LTR. In this case, a global setting is unsuitable.

If possible, I would like to request auto detection of RTL text to set the direction of each document.

Another, possibly more difficult, option would be auto detection of text direction on the paragraph level. This would help when one file has multiple languages.

An easy way to do this is to check the text-direction unicode property of the first character in each paragraph and set the paragraph direction accordingly.

I'm not too familiar with Android app development, so sadly I don't think I can contribute to this directly with code...

@gsantner
Copy link
Owner

gsantner commented Feb 6, 2021

I read through some discussions and topics - everybody/everything I read does RTL/LTR based on Locale and/or system settings. Not based on any content.
Analyzing content comes at cost of performance and I don't see the need for it in this case.

What I rather think off is, moving/adding the RTL setting out from global settings to file settings menu so you can manually set it per-file as you wish.

@mr-islam
Copy link
Author

mr-islam commented Feb 6, 2021

Yes of course, doing it on a per file basis is a popular approach that users are familiar with 👍.

I was suggesting automatic text direction based on Google Docs and Keep – they have my personal favorite implementation with auto direction based on the content of each paragraph.

But that has performance costs like you said, and is not very common.

@gsantner gsantner changed the title Auto detect and set text direction (RTL/LTR) Add file-specific setting for text direction (RTL/LTR) Feb 6, 2021
@gsantner gsantner changed the title Add file-specific setting for text direction (RTL/LTR) per-file-settings: text direction (RTL/LTR) Jan 22, 2022
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

2 participants