RTL Layout Support
The application needs to support the layout of RTL languages in the interface as well as the orientation and alignment of RTL languages in text input
https://github.com/maelchiotti/LocalMaterialNotes/assets/38974362/13be791c-5bd1-4a3b-8c7b-bb22fce91332
Hi @AI-IMED, you are right, I will look into it.
@AI-IMED I looked into it, and almost all of the app already supports RTL. I only had to fix paddings in #32.
The text field uses fleather which automatically adapts to the language (this is why it's LTR at the beginning of your screen capture, then it switches to RTL as soon as you input some RTL characters).
If you ever wish to localize the app in your language, please feel free to read this!
https://developer.android.com/reference/android/text/TextDirectionHeuristics
@AI-IMED Hi, I'm sorry but aren't the two things you hilighted already implemented? In the screen capture you itinialy sent, the interface is RTL, and as soon as you input a RTL character into the editor it switches to RTL.
Where exactly do you think I am missing an RTL improvement?
I didn't notice any changes
But I don't understand what exactly you would want me to change
The bugs that I reported to you and that you told me were fixed and implemented, I did not notice at all
Ok, I am pretty sure I tried the app with an RTL language and that they were but to be sure I will try it again.
https://github.com/maelchiotti/LocalMaterialNotes/assets/38974362/624162f1-7eb0-456e-88e3-ba998ab1f2da
The interface layout and note writing should be just as this app does
Ok thanks for the reference
I am pretty sure I tried the app with an RTL language and that they were
https://github.com/maelchiotti/LocalMaterialNotes/assets/38974362/9405d0e1-751f-4aa3-baf3-603566bc1a8d
Oh well it makes that the interface is in LTR mode. Flutter uses the locale of the app to determine if it should set the interface to LTR or RTL. As no RTL languages are supported yet, even if you phone uses a RTL language, the app defaults to English (which of course is LTR). I don't know if it's possible to force RTL, or even if it would be a desirable option to add into the app.
As for the editor, it should automatically support RTL juste like in the other app you showed, so I will look into it.
Hi again @AI-IMED.
- Regarding the interface: the app was never in RTL mode because it used the locale of the app to determine which mode to use. As no RTL languages are supported (yet), the app falls back to english which is LTR. I modified that in #86 to set the directionality of the app based on the device locale directly, so if your phone does use an RTL language, the app will also be in RTL even if it uses english for the strings.
- Regarding the editor: The fleather library seems to switch to RTL only if a line begins with an RTL character. To me it looks like a design choice, and a popular one, as I encountered it in Simplenote, Google Keep, Notein... If you believe this should be changed, feel free to create an issue in their repository.
RTL support was completely removed starting with version 2.0.0-dev2❗
Really? I don't think I made any changes about this. It it removed in the app, in the editor or both?
Both