summaryrefslogtreecommitdiff
path: root/platform/ios/DEVELOPING.md
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2016-11-18 10:29:17 -0800
committerMinh Nguyễn <mxn@1ec5.org>2016-11-18 10:38:57 -0800
commite858dba86def62967865856f4dbbe1b24663cb45 (patch)
tree27d58c00cf15560601950817f0fe799b6bea1556 /platform/ios/DEVELOPING.md
parentb4aba87892d8b6fa5c9d5608032bf54db98b6143 (diff)
downloadqtlocation-mapboxgl-e858dba86def62967865856f4dbbe1b24663cb45.tar.gz
[ios, macos] Documented localization workflow
Diffstat (limited to 'platform/ios/DEVELOPING.md')
-rw-r--r--platform/ios/DEVELOPING.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/platform/ios/DEVELOPING.md b/platform/ios/DEVELOPING.md
index a948456203..94ff49ee1b 100644
--- a/platform/ios/DEVELOPING.md
+++ b/platform/ios/DEVELOPING.md
@@ -109,6 +109,15 @@ To add or update text that the user may see in the iOS SDK:
1. _(Optional.)_ When dealing with a number followed by a pluralized word, do not split the string. Instead, use a format string and make `val` ambiguous, like `%d file(s)`. Then pluralize for English in the appropriate [.stringsdict file](https://developer.apple.com/library/ios/documentation/MacOSX/Conceptual/BPInternational/StringsdictFileFormat/StringsdictFileFormat.html). See [platform/darwin/resources/en.lproj/Foundation.stringsdict](../darwin/resources/en.lproj/Foundation.stringsdict) for an example. Localizers should do likewise for their languages.
1. Run `make genstrings` and commit any changes it makes to .strings files. The make rule also updates the macOS SDK’s strings tables.
+### Adding a localization
+
+To add a localization to the iOS SDK:
+
+1. In ios.xcworkspace, open the project editor for ios.xcodeproj. Using the project editor’s sidebar or tab bar dropdown, go to the “ios” project; under the Localizations section of the Info tab, click the + button to add your language to the project.
+1. In the sheet that appears, select all the .strings and .stringsdict files but not the .storyboard file. (LaunchScreen.storyboard is part of the iosapp example application, which is not localized.)
+1. In the Project navigator, expand each .strings and .stringsdict file in the project. An additional version for your localization should be listed; translate it. Translate everything on the right side of the equals sign. Leave the left side and any comments unmodified. See Apple’s documentation on the [.strings](https://developer.apple.com/library/content/documentation/Cocoa/Conceptual/LoadingResources/Strings/Strings.html) and [.stringsdict](https://developer.apple.com/library/content/documentation/MacOSX/Conceptual/BPInternational/StringsdictFileFormat/StringsdictFileFormat.html) formats.
+1. You’re already most of the way towards localizing the macOS SDK too – consider [completing that localization](../macos/DEVELOPING.md#adding-a-localization).
+
## Testing
`make ios-test` builds and runs unit tests of cross-platform code as well as the SDK.