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

RTL support #105

Closed
ysmaherzi opened this issue Oct 3, 2015 · 10 comments
Closed

RTL support #105

ysmaherzi opened this issue Oct 3, 2015 · 10 comments

Comments

@ysmaherzi
Copy link

The calendar is giving wrong dates when the device is set to RTL Locale like Arabic or Hebrew.
I made a quick fix in this fork https://github.com/youssef-meherzi/FSCalendar

@WenchaoD
Copy link
Owner

WenchaoD commented Oct 5, 2015

How did you set the locale. I can't even find the iso code of Arabic or Hebrew.

@ysmaherzi
Copy link
Author

I'm really sorry, I couldn't reply earlier. The bug doesn't appear when you change the locale of the calendar but the language of the device.
When you change the localization of the calendar, only the number and months format is affected. But when you change the language of the device (or simulator), even the UICollectionView put the first item on the right and the last one on the left.
In that way the first month will have the greater x value.

@WenchaoD
Copy link
Owner

Mind help me point out the language you mentioned?
ios simulator screen shot oct 12 2015 16 38 52
ios simulator screen shot oct 12 2015 16 39 05
ios simulator screen shot oct 12 2015 16 39 44

@ysmaherzi
Copy link
Author

Of course, you can test the Arabic Language, it's the the before last one in the second screenshot.

screen shot 2015-10-12 at 09 49 41

@WenchaoD
Copy link
Owner

IC.
I'll have it tested.

@ysmaherzi
Copy link
Author

Ok, thank you fior your interest :)

@WenchaoD
Copy link
Owner

Hi @youssef-meherzi
I've tested this in 7+ and 8+ simulator, but with no luck. Any ideas?
image

@ysmaherzi
Copy link
Author

Hi @WenchaoIOS
Sorry for the inconvenience. Since I'm testing only on iOS 9 I didn't realise that this feature was introduced on iOS 9. So The changes I made are not correct on prior versions.

Actually I've found two choices to fix this :

I've just tested it on iOS9 Arabic and it's working well on both RTL and LTR Languages.

Good luck :)

@WenchaoD WenchaoD closed this as completed Nov 4, 2015
@repl-Someshubhra
Copy link

Hi @youssef-meherzi
I was trying out your branch and run RTL. What I find the days are in reversed order which is fine but the days of week are not in RTL order. Please let me know your views

2017-08-22

@Raj14737
Copy link

Raj14737 commented Dec 6, 2018

Hi @youssef-meherzi how can i get date in reverse order .

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

No branches or pull requests

4 participants