samedi 29 novembre 2014

Creating Right to Left user interface for iOS

As per apple documentation "iOS doesn’t automatically mirror controls, so if you want this behaviour for an iOS app, subclass the control and override the drawing methods."


I want to mirror my whole UI when the user selects the language as Arabic or hebrew in the home screen. i was searching for tutorials and documentation for the same but nothing helps.


Please find what i have done till now: am using Xcode 6.1 and the app targets from iOS 7 to iOS 8.1. Autolayout is enabled and am not using left or right constraints. am using only leading or trailing constraints. Base internationalisation is enabled in project settings also have added the languages in localization. but when am running the app in device and set device language and region to arabic i cant get the mirrored UI. Do i have to do anything in code to get the mirrored UI? What is the best way to support RTL based UI? How to subclass control and override drawing methods?


Please use this link to get the sample screenshot of my app.




Aucun commentaire:

Enregistrer un commentaire