Here is a quick way to detect if a text is in Canadian Aboriginal Syllabic in C#.
It is just an extension method that would detect if your string is in that range by using regex.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
public static bool IsInuktitut(this string input) { if (string.IsNullOrEmpty(input)) { return false; } //http://msdn.microsoft.com/en-us/library/20bw873z.aspx //look at section Supported Named Blocks const string pattern = @"\p{IsUnifiedCanadianAboriginalSyllabics}"; Match match = Regex.Match(input, pattern); return match.Success; } |
Enjoy.
Leave A Comment