Last active
October 12, 2017 02:45
-
-
Save yycking/e7c77c4e7dced7788eacda548005e35b to your computer and use it in GitHub Desktop.
繁轉簡,簡轉繁,中文轉拼音,拼音轉注音
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| extension StringTransform { | |
| public static let 简 = StringTransform("Hant-Hans") | |
| public static let 繁 = StringTransform("Hans-Hant") | |
| public static let 拼 = StringTransform("Han-Latin") | |
| public static let 注 = StringTransform("Han-Latin;Latin-Bopomofo") | |
| } | |
| let 繁转简 = "繁轉簡".applyingTransform(.简, reverse: false) | |
| let 簡轉繁 = "简转繁".applyingTransform(.繁, reverse: false) | |
| let pīnyīn = "拼音".applyingTransform(.拼, reverse: false) | |
| let ㄓㄨˋㄧㄣ = "注音".applyingTransform(.注, reverse: false) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment