| OLD | NEW |
| 1 | 1 |
| 2 #-------------------------------------------------------------------------- | 2 #-------------------------------------------------------------------------- |
| 3 # Parameter $zName must be a path to the file UnicodeData.txt. This command | 3 # Parameter $zName must be a path to the file UnicodeData.txt. This command |
| 4 # reads the file and returns a list of mappings required to remove all | 4 # reads the file and returns a list of mappings required to remove all |
| 5 # diacritical marks from a unicode string. Each mapping is itself a list | 5 # diacritical marks from a unicode string. Each mapping is itself a list |
| 6 # consisting of two elements - the unicode codepoint and the single ASCII | 6 # consisting of two elements - the unicode codepoint and the single ASCII |
| 7 # character that it should be replaced with, or an empty string if the | 7 # character that it should be replaced with, or an empty string if the |
| 8 # codepoint should simply be removed from the input. Examples: | 8 # codepoint should simply be removed from the input. Examples: |
| 9 # | 9 # |
| 10 # { 224 a } (replace codepoint 224 to "a") | 10 # { 224 a } (replace codepoint 224 to "a") |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 foreach elem $a { lappend a2 [expr "0x[string trim $elem]"] } | 137 foreach elem $a { lappend a2 [expr "0x[string trim $elem]"] } |
| 138 foreach elem $c { lappend c2 [expr "0x[string trim $elem]"] } | 138 foreach elem $c { lappend c2 [expr "0x[string trim $elem]"] } |
| 139 set b [string trim $b] | 139 set b [string trim $b] |
| 140 set d [string trim $d] | 140 set d [string trim $d] |
| 141 | 141 |
| 142 if {$b=="C" || $b=="S"} { set tl_lookup_table($a2) $c2 } | 142 if {$b=="C" || $b=="S"} { set tl_lookup_table($a2) $c2 } |
| 143 } | 143 } |
| 144 } | 144 } |
| 145 | 145 |
| 146 | 146 |
| OLD | NEW |