I only want this to happen when the locale is RTL, is there any efficient way to find out what layout direction should be used?
c
Csaba Kozák
09/30/2021, 2:54 PM
I do not think you should provide this at all. It is already provided by compose. You can just read the value
LocalLayoutDirection.current
and make decision based on that.
You only have to provide this if you want to force your layout to be another direction than the system’s.
s
shahroz
09/30/2021, 3:14 PM
But the behaviour is very different, if i dont provide this i dont get fully RTL screen, some views automatically gets shifted but not all.
But with this, every single view is mirrored.