| 1 |
# liblouis: Korean (Base table and chars) |
| 2 |
# |
| 3 |
# Based on the braille contraction table in BRLTTY |
| 4 |
# |
| 5 |
# Copyright (C) 1995-2012 by The BRLTTY Team. |
| 6 |
# Copyright (C) 2012 by Samuel Thibault <[email protected]> |
| 7 |
# Copyright (C) 2012 by Mesar Hameed <[email protected]> |
| 8 |
# Copyright (C) 2013 by Joseph Lee <[email protected]> |
| 9 |
# |
| 10 |
# This file is part of liblouis. |
| 11 |
# |
| 12 |
# liblouis is free software: you can redistribute it and/or modify it |
| 13 |
# under the terms of the GNU Lesser General Public License as |
| 14 |
# published by the Free Software Foundation, either version 2.1 of the |
| 15 |
# License, or (at your option) any later version. |
| 16 |
# |
| 17 |
# liblouis is distributed in the hope that it will be useful, but |
| 18 |
# WITHOUT ANY WARRANTY; without even the implied warranty of |
| 19 |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 20 |
# Lesser General Public License for more details. |
| 21 |
# |
| 22 |
# You should have received a copy of the GNU Lesser General Public |
| 23 |
# License along with liblouis. If not, see |
| 24 |
# <http://www.gnu.org/licenses/>. |
| 25 |
|
| 26 |
# This is missing CHITUEUM*, CEONGCHIEUMSIOS, PANSIOS, YESIEUNG, RINHIEUH and |
| 27 |
# ARAEA for which I couldn't find documentation. Please contact me to fix |
| 28 |
# anything, as this table was generated from a C program. |
| 29 |
|
| 30 |
## Comments: |
| 31 |
|
| 32 |
# There are three files that are needed for displaying Korean chars: |
| 33 |
|
| 34 |
# ko.cti, which contains punctuations, numbers and Unicode sign |
| 35 |
# opcodes for Korean (Hangul) chars. This file also includes Korean |
| 36 |
# dot/char patterns which are not affected by grade 1 and grade 2 |
| 37 |
# rules - that is, entries which are common to grade 1 and grade 2. |
| 38 |
# The "universal" entries fixes an issue where some Korean conscenant |
| 39 |
# dot patterns were confused with litdigit (although in the table, I |
| 40 |
# put after digit), which was a concern raised by a number of Korean |
| 41 |
# braille readers. For example, the conscenant dots fpr "ni-eun" is |
| 42 |
# dots 14, which are same as number 3. |
| 43 |
|
| 44 |
# ko-g1.ctb, uncontracted Korean table. Includes har/dot pairs used in |
| 45 |
# Grade 1 rules. Mostly deals with "after digit" situations. |
| 46 |
|
| 47 |
# ko-g2.ctb, contracted Korean braille. Includes same chars as ko1.ctb |
| 48 |
# which has different dot patterns in grade 2. These are shorthands |
| 49 |
# for uncontracted chars. Also includes certain strings which must be |
| 50 |
# uncontracted and a number of multi-char ones which has shorthand dot |
| 51 |
# patterns. |
| 52 |
|
| 53 |
# As for the structure of the files: ko.cti is the base table from |
| 54 |
# which ko-g1.ctb and ko-g2.ctb derives. Thus, unlike other tables, |
| 55 |
# ko-g2.ctb does not include ko-g1.ctb. This would help me extend the |
| 56 |
# table without major modifications - all I need to do is categorize |
| 57 |
# whether an entry is universal or grade-specific, then add the |
| 58 |
# entries in the appropriate file (if it is universal, then ko.cti |
| 59 |
# will be modified; if it is grade-specific, ko-g1 or ko-g2 will be |
| 60 |
# modified). |
| 61 |
|
| 62 |
# Globals (used for punctuations and others): |
| 63 |
|
| 64 |
include en-chardefs.cti English character definition opcodes |
| 65 |
include braille-patterns.cti |
| 66 |
|
| 67 |
# Braille indicators |
| 68 |
numsign 3456 number sign, just a dots operand |
| 69 |
capsletter 6 |
| 70 |
begcapsword 6-6 |
| 71 |
endcapsword 6-3 |
| 72 |
emphclass italic |
| 73 |
emphclass underline |
| 74 |
emphclass bold |
| 75 |
begemphphrase italic 46-46 |
| 76 |
endemphphrase italic before 46 |
| 77 |
lenemphphrase italic 4 |
| 78 |
begemphword italic 46-3 |
| 79 |
endemphword italic 46-36 |
| 80 |
emphletter italic 46-25 |
| 81 |
begemphphrase bold 456-456 |
| 82 |
endemphphrase bold before 456 |
| 83 |
lenemphphrase bold 4 |
| 84 |
begcomp 456-346 |
| 85 |
endcomp 456-156 |
| 86 |
|
| 87 |
# literary forms of the decimal digits |
| 88 |
include litdigits6Dots.uti |
| 89 |
|
| 90 |
# Letters are defined in chardefs.cti |
| 91 |
|
| 92 |
# punctuation |
| 93 |
prepunc ( 36 |
| 94 |
word ( 36 |
| 95 |
noback always ( 36 |
| 96 |
postpunc ) 36 |
| 97 |
word ) 36 |
| 98 |
noback always ) 36 |
| 99 |
prepunc " 236 |
| 100 |
postpunc " 356 |
| 101 |
word " 236 |
| 102 |
prepunc ` 236 |
| 103 |
prepunc ' 6-236 |
| 104 |
postpunc ' 356-3 |
| 105 |
word ' 4-3 |
| 106 |
word 'em = |
| 107 |
word 'tis = |
| 108 |
word 'twas = |
| 109 |
begnum # 3456 print number sign before number |
| 110 |
midnum , 5 |
| 111 |
postpunc , 5 |
| 112 |
word , 5 |
| 113 |
noback always , 5 |
| 114 |
decpoint . 3 |
| 115 |
midnum - 36 |
| 116 |
hyphen - 36 |
| 117 |
always \s--\s 36-36 |
| 118 |
always \s-\s 36-36 |
| 119 |
midnum \x00ad 36 |
| 120 |
postpunc . 256 |
| 121 |
word . 256 |
| 122 |
noback always . 256 |
| 123 |
postpunc ; 56-23 |
| 124 |
word ; 56-23 |
| 125 |
midnum : 5-2 |
| 126 |
postpunc : 5-2 |
| 127 |
always : 5-2 |
| 128 |
postpunc ! 456 |
| 129 |
noback always ! 456 |
| 130 |
midnum / 456-34 |
| 131 |
always / 456-34 |
| 132 |
always < 5-13 |
| 133 |
always = 25-25 |
| 134 |
always > 46-2 |
| 135 |
always + 5-235 |
| 136 |
postpunc ? 236 |
| 137 |
word ? 236 |
| 138 |
noback always ? 236 |
| 139 |
endnum st 34 |
| 140 |
endnum nd 1345-145 |
| 141 |
endnum rd 1235-145 |
| 142 |
endnum 's 3-234 |
| 143 |
endnum th 1456 |
| 144 |
endnum 's 3-234 |
| 145 |
always % 356-1234 |
| 146 |
midnum ^ 45 |
| 147 |
always ^ 456-126 |
| 148 |
always ~ 36-36 |
| 149 |
always & 4-12346 |
| 150 |
midnum * 5-23 |
| 151 |
always * 35-35 |
| 152 |
prepunc [ 236-3 |
| 153 |
word [ 236-3 |
| 154 |
always [ 236-3 |
| 155 |
postpunc ] 6-356 |
| 156 |
word ] 6-356 |
| 157 |
always ] 6-356 |
| 158 |
prepunc { 236-23 |
| 159 |
word { 236-23 |
| 160 |
always { 236-23 |
| 161 |
postpunc } 56-356 |
| 162 |
word } 56-356 |
| 163 |
always } 56-356 |
| 164 |
always @ 4-1 |
| 165 |
always \\ 4-1256 |
| 166 |
always | 456-1256 |
| 167 |
always \s-\s 36 |
| 168 |
always ..." 5-5-5-356 |
| 169 |
always … 5-5-5 |
| 170 |
always ... 5-5-5 |
| 171 |
always ...' 5-5-5-356-3 |
| 172 |
repeated .... 0 |
| 173 |
repeated ____ 6-36-36-3 |
| 174 |
repeated ---- 36 |
| 175 |
always .\s.\s." 3-3-3-356 |
| 176 |
always .\s.\s. 3-3-3 . . . |
| 177 |
begnum $ 256 |
| 178 |
always $ 4-256 |
| 179 |
always _ 6-36-36-3 |
| 180 |
always — 56-36-36-23 |
| 181 |
|
| 182 |
# special character sequences |
| 183 |
compbrl :// URLs |
| 184 |
compbrl () |
| 185 |
compbrl www. |
| 186 |
compbrl :: |
| 187 |
compbrl .com |
| 188 |
compbrl .edu |
| 189 |
compbrl .gov |
| 190 |
compbrl .ini |
| 191 |
compbrl .mil |
| 192 |
compbrl .net |
| 193 |
compbrl .org |
| 194 |
compbrl .doc |
| 195 |
compbrl .xml |
| 196 |
compbrl .xsl |
| 197 |
compbrl .htm |
| 198 |
compbrl .html |
| 199 |
compbrl .tex |
| 200 |
compbrl .txt |
| 201 |
compbrl .gif |
| 202 |
compbrl .jpg |
| 203 |
compbrl .png |
| 204 |
compbrl .wav |
| 205 |
compbrl .tar |
| 206 |
compbrl .zip |
| 207 |
|
| 208 |
noback context "\e"$a * |
| 209 |
always \\_ 56 letter sign before Roman page numbers |
| 210 |
noback pass2 @56-56 @56 |
| 211 |
noback pass2 @3-56 @3 |
| 212 |
|
| 213 |
|
| 214 |
#Korean section: |
| 215 |
|
| 216 |
#Detect English: |
| 217 |
letsign 356 |
| 218 |
|
| 219 |
#Basic letter patterns (to be used in G1 and G2): |
| 220 |
include ko-chars.cti |
| 221 |
|
| 222 |
|
| 223 |
# For grade 1 and grade 2 rules not discussed here, see ko-g1.ctb and ko-g2.ctb. |