Read More

How to Localize the Plist file?

Localize Plist file.

Localization is the process of making your app support multiple languages. In many cases, you make your app with English user interface first and then localize the app to other languages such as Arabic. Today I am going to show how to localize the permission text.

Please follow the below steps to localize the Plist file:

Step 1: Add the language in you your project.

Select project -> Select localizations->Add language

Step 2: Add a new string file and name it “InfoPlist.strings”.

Step 3: Select “InfoPlist.strings” and on the right side click on ” localize ” this and select the respective language whatever present in your project.

Step 4: Then it will create the file for the base, English, and respective language.

Step 5: Now localize the Plist key description.

for the English file:

NSAppleMusicUsageDescription = “Uses for music”;

NSCameraUsageDescription = “Uses the camera for taking profile picture and image detection”;

NSLocationAlwaysAndWhenInUseUsageDescription = “Uses location for getting user current address”;

NSLocationAlwaysUsageDescription = “Uses location for getting user current address”;

NSLocationUsageDescription = “Uses location for getting user current address”;

NSLocationWhenInUseUsageDescription = “Uses location for getting user current address”;

NSPhotoLibraryUsageDescription = “Uses photo for taking profile picture and image detection”;

for Arabic file:

NSAppleMusicUsageDescription = “يستخدم للموسيقى”;

NSCameraUsageDescription = “يستخدم الكاميرا لالتقاط صورة الملف الشخصي واكتشاف الصورة”;

NSLocationAlwaysAndWhenInUseUsageDescription = “يستخدم الموقع للحصول على عنوان المستخدم الحالي”;

NSLocationAlwaysUsageDescription = “يستخدم الموقع للحصول على عنوان المستخدم الحالي”;

NSLocationUsageDescription = “يستخدم الموقع للحصول على عنوان المستخدم الحالي”;

NSLocationWhenInUseUsageDescription = “يستخدم الموقع للحصول على عنوان المستخدم الحالي”;

NSPhotoLibraryUsageDescription = “يستخدم الصورة لالتقاط صورة الملف الشخصي واكتشاف الصورة”;

We have mentioned the most common keys which we have used in our every project. You can take any key from the Plist file and localize it.

Step 6: Now your Plist file is localized.

Step 7: It depends on your iPhone or iPad ‘s language, it will automatically pick the description from the “InfoPlist.strings”. file.

. . .

Comment

Add Your Comment

Be the first to comment.

css.php
Hire Us!
Brief us about your requirements and we'll get back to you.
Woo! Hooy!
We have just recieved your project brief and our expert will contact you shortly.
Send Again
Close