summaryrefslogtreecommitdiff
path: root/platform/darwin/src/NSString+MGLAdditions.h
diff options
context:
space:
mode:
authorJason Wray <jason@mapbox.com>2018-01-09 16:09:41 -0500
committerJason Wray <jason@mapbox.com>2018-01-10 17:26:11 -0500
commit0806e16eb390d9eb7db3157e23798f4010614aca (patch)
treee4e8a2d83ea49df8ec83b6d16e9f1c0b83a20140 /platform/darwin/src/NSString+MGLAdditions.h
parentc9da6e495900cfe927d1f571e1687b20e0543dbd (diff)
downloadqtlocation-mapboxgl-0806e16eb390d9eb7db3157e23798f4010614aca.tar.gz
[ios] Fix and expand accessibility feature transliteration
- Fixed pre-iOS 11 compatibility. - Expanded transliteration to all supported languages.
Diffstat (limited to 'platform/darwin/src/NSString+MGLAdditions.h')
-rw-r--r--platform/darwin/src/NSString+MGLAdditions.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/platform/darwin/src/NSString+MGLAdditions.h b/platform/darwin/src/NSString+MGLAdditions.h
index d82ecaa671..75c593c10b 100644
--- a/platform/darwin/src/NSString+MGLAdditions.h
+++ b/platform/darwin/src/NSString+MGLAdditions.h
@@ -20,6 +20,20 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (NSString *)mgl_titleCasedStringWithLocale:(NSLocale *)locale;
+/**
+ Returns a transliterated representation of the receiver using the specified
+ script. If transliteration fails, the receiver will be returned.
+
+ Only supports scripts for languages used by Mapbox Streets.
+
+ On iOS 8 or older, this will method will always return the untransliterated
+ receiver.
+
+ @param script The four-letter code representing the name of the script, as
+ specified by ISO 15924.
+ */
+- (NSString *)mgl_stringByTransliteratingIntoScript:(NSString *)script;
+
@end
@interface NSAttributedString (MGLAdditions)