runetypebody.h (24961B)
1 /* Automatically generated from UnicodeData-6.1.0.txt by mkrunetype.awk */ 2 3 static Rune alpha2[][2] = { 4 { 0x0041, 0x005A }, 5 { 0x0061, 0x007A }, 6 { 0x00C0, 0x00D6 }, 7 { 0x00D8, 0x00F6 }, 8 { 0x00F8, 0x02C1 }, 9 { 0x02C6, 0x02D1 }, 10 { 0x02E0, 0x02E4 }, 11 { 0x0370, 0x0374 }, 12 { 0x0376, 0x0377 }, 13 { 0x037A, 0x037D }, 14 { 0x0388, 0x038A }, 15 { 0x038E, 0x03A1 }, 16 { 0x03A3, 0x03F5 }, 17 { 0x03F7, 0x0481 }, 18 { 0x048A, 0x0527 }, 19 { 0x0531, 0x0556 }, 20 { 0x0561, 0x0587 }, 21 { 0x05D0, 0x05EA }, 22 { 0x05F0, 0x05F2 }, 23 { 0x0620, 0x064A }, 24 { 0x066E, 0x066F }, 25 { 0x0671, 0x06D3 }, 26 { 0x06E5, 0x06E6 }, 27 { 0x06EE, 0x06EF }, 28 { 0x06FA, 0x06FC }, 29 { 0x0712, 0x072F }, 30 { 0x074D, 0x07A5 }, 31 { 0x07CA, 0x07EA }, 32 { 0x07F4, 0x07F5 }, 33 { 0x0800, 0x0815 }, 34 { 0x0840, 0x0858 }, 35 { 0x08A2, 0x08AC }, 36 { 0x0904, 0x0939 }, 37 { 0x0958, 0x0961 }, 38 { 0x0971, 0x0977 }, 39 { 0x0979, 0x097F }, 40 { 0x0985, 0x098C }, 41 { 0x098F, 0x0990 }, 42 { 0x0993, 0x09A8 }, 43 { 0x09AA, 0x09B0 }, 44 { 0x09B6, 0x09B9 }, 45 { 0x09DC, 0x09DD }, 46 { 0x09DF, 0x09E1 }, 47 { 0x09F0, 0x09F1 }, 48 { 0x0A05, 0x0A0A }, 49 { 0x0A0F, 0x0A10 }, 50 { 0x0A13, 0x0A28 }, 51 { 0x0A2A, 0x0A30 }, 52 { 0x0A32, 0x0A33 }, 53 { 0x0A35, 0x0A36 }, 54 { 0x0A38, 0x0A39 }, 55 { 0x0A59, 0x0A5C }, 56 { 0x0A72, 0x0A74 }, 57 { 0x0A85, 0x0A8D }, 58 { 0x0A8F, 0x0A91 }, 59 { 0x0A93, 0x0AA8 }, 60 { 0x0AAA, 0x0AB0 }, 61 { 0x0AB2, 0x0AB3 }, 62 { 0x0AB5, 0x0AB9 }, 63 { 0x0AE0, 0x0AE1 }, 64 { 0x0B05, 0x0B0C }, 65 { 0x0B0F, 0x0B10 }, 66 { 0x0B13, 0x0B28 }, 67 { 0x0B2A, 0x0B30 }, 68 { 0x0B32, 0x0B33 }, 69 { 0x0B35, 0x0B39 }, 70 { 0x0B5C, 0x0B5D }, 71 { 0x0B5F, 0x0B61 }, 72 { 0x0B85, 0x0B8A }, 73 { 0x0B8E, 0x0B90 }, 74 { 0x0B92, 0x0B95 }, 75 { 0x0B99, 0x0B9A }, 76 { 0x0B9E, 0x0B9F }, 77 { 0x0BA3, 0x0BA4 }, 78 { 0x0BA8, 0x0BAA }, 79 { 0x0BAE, 0x0BB9 }, 80 { 0x0C05, 0x0C0C }, 81 { 0x0C0E, 0x0C10 }, 82 { 0x0C12, 0x0C28 }, 83 { 0x0C2A, 0x0C33 }, 84 { 0x0C35, 0x0C39 }, 85 { 0x0C58, 0x0C59 }, 86 { 0x0C60, 0x0C61 }, 87 { 0x0C85, 0x0C8C }, 88 { 0x0C8E, 0x0C90 }, 89 { 0x0C92, 0x0CA8 }, 90 { 0x0CAA, 0x0CB3 }, 91 { 0x0CB5, 0x0CB9 }, 92 { 0x0CE0, 0x0CE1 }, 93 { 0x0CF1, 0x0CF2 }, 94 { 0x0D05, 0x0D0C }, 95 { 0x0D0E, 0x0D10 }, 96 { 0x0D12, 0x0D3A }, 97 { 0x0D60, 0x0D61 }, 98 { 0x0D7A, 0x0D7F }, 99 { 0x0D85, 0x0D96 }, 100 { 0x0D9A, 0x0DB1 }, 101 { 0x0DB3, 0x0DBB }, 102 { 0x0DC0, 0x0DC6 }, 103 { 0x0E01, 0x0E30 }, 104 { 0x0E32, 0x0E33 }, 105 { 0x0E40, 0x0E46 }, 106 { 0x0E81, 0x0E82 }, 107 { 0x0E87, 0x0E88 }, 108 { 0x0E94, 0x0E97 }, 109 { 0x0E99, 0x0E9F }, 110 { 0x0EA1, 0x0EA3 }, 111 { 0x0EAA, 0x0EAB }, 112 { 0x0EAD, 0x0EB0 }, 113 { 0x0EB2, 0x0EB3 }, 114 { 0x0EC0, 0x0EC4 }, 115 { 0x0EDC, 0x0EDF }, 116 { 0x0F40, 0x0F47 }, 117 { 0x0F49, 0x0F6C }, 118 { 0x0F88, 0x0F8C }, 119 { 0x1000, 0x102A }, 120 { 0x1050, 0x1055 }, 121 { 0x105A, 0x105D }, 122 { 0x1065, 0x1066 }, 123 { 0x106E, 0x1070 }, 124 { 0x1075, 0x1081 }, 125 { 0x10A0, 0x10C5 }, 126 { 0x10D0, 0x10FA }, 127 { 0x10FC, 0x1248 }, 128 { 0x124A, 0x124D }, 129 { 0x1250, 0x1256 }, 130 { 0x125A, 0x125D }, 131 { 0x1260, 0x1288 }, 132 { 0x128A, 0x128D }, 133 { 0x1290, 0x12B0 }, 134 { 0x12B2, 0x12B5 }, 135 { 0x12B8, 0x12BE }, 136 { 0x12C2, 0x12C5 }, 137 { 0x12C8, 0x12D6 }, 138 { 0x12D8, 0x1310 }, 139 { 0x1312, 0x1315 }, 140 { 0x1318, 0x135A }, 141 { 0x1380, 0x138F }, 142 { 0x13A0, 0x13F4 }, 143 { 0x1401, 0x166C }, 144 { 0x166F, 0x167F }, 145 { 0x1681, 0x169A }, 146 { 0x16A0, 0x16EA }, 147 { 0x1700, 0x170C }, 148 { 0x170E, 0x1711 }, 149 { 0x1720, 0x1731 }, 150 { 0x1740, 0x1751 }, 151 { 0x1760, 0x176C }, 152 { 0x176E, 0x1770 }, 153 { 0x1780, 0x17B3 }, 154 { 0x1820, 0x1877 }, 155 { 0x1880, 0x18A8 }, 156 { 0x18B0, 0x18F5 }, 157 { 0x1900, 0x191C }, 158 { 0x1950, 0x196D }, 159 { 0x1970, 0x1974 }, 160 { 0x1980, 0x19AB }, 161 { 0x19C1, 0x19C7 }, 162 { 0x1A00, 0x1A16 }, 163 { 0x1A20, 0x1A54 }, 164 { 0x1B05, 0x1B33 }, 165 { 0x1B45, 0x1B4B }, 166 { 0x1B83, 0x1BA0 }, 167 { 0x1BAE, 0x1BAF }, 168 { 0x1BBA, 0x1BE5 }, 169 { 0x1C00, 0x1C23 }, 170 { 0x1C4D, 0x1C4F }, 171 { 0x1C5A, 0x1C7D }, 172 { 0x1CE9, 0x1CEC }, 173 { 0x1CEE, 0x1CF1 }, 174 { 0x1CF5, 0x1CF6 }, 175 { 0x1D00, 0x1DBF }, 176 { 0x1E00, 0x1F15 }, 177 { 0x1F18, 0x1F1D }, 178 { 0x1F20, 0x1F45 }, 179 { 0x1F48, 0x1F4D }, 180 { 0x1F50, 0x1F57 }, 181 { 0x1F5F, 0x1F7D }, 182 { 0x1F80, 0x1FB4 }, 183 { 0x1FB6, 0x1FBC }, 184 { 0x1FC2, 0x1FC4 }, 185 { 0x1FC6, 0x1FCC }, 186 { 0x1FD0, 0x1FD3 }, 187 { 0x1FD6, 0x1FDB }, 188 { 0x1FE0, 0x1FEC }, 189 { 0x1FF2, 0x1FF4 }, 190 { 0x1FF6, 0x1FFC }, 191 { 0x2090, 0x209C }, 192 { 0x210A, 0x2113 }, 193 { 0x2119, 0x211D }, 194 { 0x212A, 0x212D }, 195 { 0x212F, 0x2139 }, 196 { 0x213C, 0x213F }, 197 { 0x2145, 0x2149 }, 198 { 0x2183, 0x2184 }, 199 { 0x2C00, 0x2C2E }, 200 { 0x2C30, 0x2C5E }, 201 { 0x2C60, 0x2CE4 }, 202 { 0x2CEB, 0x2CEE }, 203 { 0x2CF2, 0x2CF3 }, 204 { 0x2D00, 0x2D25 }, 205 { 0x2D30, 0x2D67 }, 206 { 0x2D80, 0x2D96 }, 207 { 0x2DA0, 0x2DA6 }, 208 { 0x2DA8, 0x2DAE }, 209 { 0x2DB0, 0x2DB6 }, 210 { 0x2DB8, 0x2DBE }, 211 { 0x2DC0, 0x2DC6 }, 212 { 0x2DC8, 0x2DCE }, 213 { 0x2DD0, 0x2DD6 }, 214 { 0x2DD8, 0x2DDE }, 215 { 0x3005, 0x3006 }, 216 { 0x3031, 0x3035 }, 217 { 0x303B, 0x303C }, 218 { 0x3041, 0x3096 }, 219 { 0x309D, 0x309F }, 220 { 0x30A1, 0x30FA }, 221 { 0x30FC, 0x30FF }, 222 { 0x3105, 0x312D }, 223 { 0x3131, 0x318E }, 224 { 0x31A0, 0x31BA }, 225 { 0x31F0, 0x31FF }, 226 { 0xA000, 0xA48C }, 227 { 0xA4D0, 0xA4FD }, 228 { 0xA500, 0xA60C }, 229 { 0xA610, 0xA61F }, 230 { 0xA62A, 0xA62B }, 231 { 0xA640, 0xA66E }, 232 { 0xA67F, 0xA697 }, 233 { 0xA6A0, 0xA6E5 }, 234 { 0xA717, 0xA71F }, 235 { 0xA722, 0xA788 }, 236 { 0xA78B, 0xA78E }, 237 { 0xA790, 0xA793 }, 238 { 0xA7A0, 0xA7AA }, 239 { 0xA7F8, 0xA801 }, 240 { 0xA803, 0xA805 }, 241 { 0xA807, 0xA80A }, 242 { 0xA80C, 0xA822 }, 243 { 0xA840, 0xA873 }, 244 { 0xA882, 0xA8B3 }, 245 { 0xA8F2, 0xA8F7 }, 246 { 0xA90A, 0xA925 }, 247 { 0xA930, 0xA946 }, 248 { 0xA960, 0xA97C }, 249 { 0xA984, 0xA9B2 }, 250 { 0xAA00, 0xAA28 }, 251 { 0xAA40, 0xAA42 }, 252 { 0xAA44, 0xAA4B }, 253 { 0xAA60, 0xAA76 }, 254 { 0xAA80, 0xAAAF }, 255 { 0xAAB5, 0xAAB6 }, 256 { 0xAAB9, 0xAABD }, 257 { 0xAADB, 0xAADD }, 258 { 0xAAE0, 0xAAEA }, 259 { 0xAAF2, 0xAAF4 }, 260 { 0xAB01, 0xAB06 }, 261 { 0xAB09, 0xAB0E }, 262 { 0xAB11, 0xAB16 }, 263 { 0xAB20, 0xAB26 }, 264 { 0xAB28, 0xAB2E }, 265 { 0xABC0, 0xABE2 }, 266 { 0xD7B0, 0xD7C6 }, 267 { 0xD7CB, 0xD7FB }, 268 { 0xF900, 0xFA6D }, 269 { 0xFA70, 0xFAD9 }, 270 { 0xFB00, 0xFB06 }, 271 { 0xFB13, 0xFB17 }, 272 { 0xFB1F, 0xFB28 }, 273 { 0xFB2A, 0xFB36 }, 274 { 0xFB38, 0xFB3C }, 275 { 0xFB40, 0xFB41 }, 276 { 0xFB43, 0xFB44 }, 277 { 0xFB46, 0xFBB1 }, 278 { 0xFBD3, 0xFD3D }, 279 { 0xFD50, 0xFD8F }, 280 { 0xFD92, 0xFDC7 }, 281 { 0xFDF0, 0xFDFB }, 282 { 0xFE70, 0xFE74 }, 283 { 0xFE76, 0xFEFC }, 284 { 0xFF21, 0xFF3A }, 285 { 0xFF41, 0xFF5A }, 286 { 0xFF66, 0xFFBE }, 287 { 0xFFC2, 0xFFC7 }, 288 { 0xFFCA, 0xFFCF }, 289 { 0xFFD2, 0xFFD7 }, 290 { 0xFFDA, 0xFFDC }, 291 { 0x10000, 0x1000B }, 292 { 0x1000D, 0x10026 }, 293 { 0x10028, 0x1003A }, 294 { 0x1003C, 0x1003D }, 295 { 0x1003F, 0x1004D }, 296 { 0x10050, 0x1005D }, 297 { 0x10080, 0x100FA }, 298 { 0x10280, 0x1029C }, 299 { 0x102A0, 0x102D0 }, 300 { 0x10300, 0x1031E }, 301 { 0x10330, 0x10340 }, 302 { 0x10342, 0x10349 }, 303 { 0x10380, 0x1039D }, 304 { 0x103A0, 0x103C3 }, 305 { 0x103C8, 0x103CF }, 306 { 0x10400, 0x1049D }, 307 { 0x10800, 0x10805 }, 308 { 0x1080A, 0x10835 }, 309 { 0x10837, 0x10838 }, 310 { 0x1083F, 0x10855 }, 311 { 0x10900, 0x10915 }, 312 { 0x10920, 0x10939 }, 313 { 0x10980, 0x109B7 }, 314 { 0x109BE, 0x109BF }, 315 { 0x10A10, 0x10A13 }, 316 { 0x10A15, 0x10A17 }, 317 { 0x10A19, 0x10A33 }, 318 { 0x10A60, 0x10A7C }, 319 { 0x10B00, 0x10B35 }, 320 { 0x10B40, 0x10B55 }, 321 { 0x10B60, 0x10B72 }, 322 { 0x10C00, 0x10C48 }, 323 { 0x11003, 0x11037 }, 324 { 0x11083, 0x110AF }, 325 { 0x110D0, 0x110E8 }, 326 { 0x11103, 0x11126 }, 327 { 0x11183, 0x111B2 }, 328 { 0x111C1, 0x111C4 }, 329 { 0x11680, 0x116AA }, 330 { 0x12000, 0x1236E }, 331 { 0x13000, 0x1342E }, 332 { 0x16800, 0x16A38 }, 333 { 0x16F00, 0x16F44 }, 334 { 0x16F93, 0x16F9F }, 335 { 0x1B000, 0x1B001 }, 336 { 0x1D400, 0x1D454 }, 337 { 0x1D456, 0x1D49C }, 338 { 0x1D49E, 0x1D49F }, 339 { 0x1D4A5, 0x1D4A6 }, 340 { 0x1D4A9, 0x1D4AC }, 341 { 0x1D4AE, 0x1D4B9 }, 342 { 0x1D4BD, 0x1D4C3 }, 343 { 0x1D4C5, 0x1D505 }, 344 { 0x1D507, 0x1D50A }, 345 { 0x1D50D, 0x1D514 }, 346 { 0x1D516, 0x1D51C }, 347 { 0x1D51E, 0x1D539 }, 348 { 0x1D53B, 0x1D53E }, 349 { 0x1D540, 0x1D544 }, 350 { 0x1D54A, 0x1D550 }, 351 { 0x1D552, 0x1D6A5 }, 352 { 0x1D6A8, 0x1D6C0 }, 353 { 0x1D6C2, 0x1D6DA }, 354 { 0x1D6DC, 0x1D6FA }, 355 { 0x1D6FC, 0x1D714 }, 356 { 0x1D716, 0x1D734 }, 357 { 0x1D736, 0x1D74E }, 358 { 0x1D750, 0x1D76E }, 359 { 0x1D770, 0x1D788 }, 360 { 0x1D78A, 0x1D7A8 }, 361 { 0x1D7AA, 0x1D7C2 }, 362 { 0x1D7C4, 0x1D7CB }, 363 { 0x1EE00, 0x1EE03 }, 364 { 0x1EE05, 0x1EE1F }, 365 { 0x1EE21, 0x1EE22 }, 366 { 0x1EE29, 0x1EE32 }, 367 { 0x1EE34, 0x1EE37 }, 368 { 0x1EE4D, 0x1EE4F }, 369 { 0x1EE51, 0x1EE52 }, 370 { 0x1EE61, 0x1EE62 }, 371 { 0x1EE67, 0x1EE6A }, 372 { 0x1EE6C, 0x1EE72 }, 373 { 0x1EE74, 0x1EE77 }, 374 { 0x1EE79, 0x1EE7C }, 375 { 0x1EE80, 0x1EE89 }, 376 { 0x1EE8B, 0x1EE9B }, 377 { 0x1EEA1, 0x1EEA3 }, 378 { 0x1EEA5, 0x1EEA9 }, 379 { 0x1EEAB, 0x1EEBB }, 380 { 0x2F800, 0x2FA1D }, 381 }; 382 383 static Rune alpha1[] = { 384 0x00AA, 385 0x00B5, 386 0x00BA, 387 0x02EC, 388 0x02EE, 389 0x0386, 390 0x038C, 391 0x0559, 392 0x06D5, 393 0x06FF, 394 0x0710, 395 0x07B1, 396 0x07FA, 397 0x081A, 398 0x0824, 399 0x0828, 400 0x08A0, 401 0x093D, 402 0x0950, 403 0x09B2, 404 0x09BD, 405 0x09CE, 406 0x0A5E, 407 0x0ABD, 408 0x0AD0, 409 0x0B3D, 410 0x0B71, 411 0x0B83, 412 0x0B9C, 413 0x0BD0, 414 0x0C3D, 415 0x0CBD, 416 0x0CDE, 417 0x0D3D, 418 0x0D4E, 419 0x0DBD, 420 0x0E84, 421 0x0E8A, 422 0x0E8D, 423 0x0EA5, 424 0x0EA7, 425 0x0EBD, 426 0x0EC6, 427 0x0F00, 428 0x103F, 429 0x1061, 430 0x108E, 431 0x10C7, 432 0x10CD, 433 0x1258, 434 0x12C0, 435 0x17D7, 436 0x17DC, 437 0x18AA, 438 0x1AA7, 439 0x1F59, 440 0x1F5B, 441 0x1F5D, 442 0x1FBE, 443 0x2071, 444 0x207F, 445 0x2102, 446 0x2107, 447 0x2115, 448 0x2124, 449 0x2126, 450 0x2128, 451 0x214E, 452 0x2D27, 453 0x2D2D, 454 0x2D6F, 455 0x2E2F, 456 0x3400, 457 0x4DB5, 458 0x4E00, 459 0x9FCC, 460 0xA8FB, 461 0xA9CF, 462 0xAA7A, 463 0xAAB1, 464 0xAAC0, 465 0xAAC2, 466 0xAC00, 467 0xD7A3, 468 0xFB1D, 469 0xFB3E, 470 0x10808, 471 0x1083C, 472 0x10A00, 473 0x16F50, 474 0x1D4A2, 475 0x1D4BB, 476 0x1D546, 477 0x1EE24, 478 0x1EE27, 479 0x1EE39, 480 0x1EE3B, 481 0x1EE42, 482 0x1EE47, 483 0x1EE49, 484 0x1EE4B, 485 0x1EE54, 486 0x1EE57, 487 0x1EE59, 488 0x1EE5B, 489 0x1EE5D, 490 0x1EE5F, 491 0x1EE64, 492 0x1EE7E, 493 0x20000, 494 0x2A6D6, 495 0x2A700, 496 0x2B734, 497 0x2B740, 498 0x2B81D, 499 }; 500 501 int 502 isalpharune(Rune r) 503 { 504 if(bsearch(&r, alpha2, nelem(alpha2), sizeof *alpha2, &rune2cmp)) 505 return 1; 506 if(bsearch(&r, alpha1, nelem(alpha1), sizeof *alpha1, &rune1cmp)) 507 return 1; 508 return 0; 509 } 510 511 static Rune space2[][2] = { 512 { 0x2000, 0x200A }, 513 { 0x2028, 0x2029 }, 514 }; 515 516 static Rune space1[] = { 517 0x0020, 518 0x00A0, 519 0x1680, 520 0x180E, 521 0x202F, 522 0x205F, 523 0x3000, 524 }; 525 526 int 527 isspacerune(Rune r) 528 { 529 if(bsearch(&r, space2, nelem(space2), sizeof *space2, &rune2cmp)) 530 return 1; 531 if(bsearch(&r, space1, nelem(space1), sizeof *space1, &rune1cmp)) 532 return 1; 533 return 0; 534 } 535 536 static Rune upper2[][2] = { 537 { 0x0041, 0x005A }, 538 { 0x00C0, 0x00D6 }, 539 { 0x00D8, 0x00DE }, 540 { 0x0178, 0x0179 }, 541 { 0x0181, 0x0182 }, 542 { 0x0186, 0x0187 }, 543 { 0x0189, 0x018B }, 544 { 0x018E, 0x0191 }, 545 { 0x0193, 0x0194 }, 546 { 0x0196, 0x0198 }, 547 { 0x019C, 0x019D }, 548 { 0x019F, 0x01A0 }, 549 { 0x01A6, 0x01A7 }, 550 { 0x01AE, 0x01AF }, 551 { 0x01B1, 0x01B3 }, 552 { 0x01B7, 0x01B8 }, 553 { 0x01F6, 0x01F8 }, 554 { 0x023A, 0x023B }, 555 { 0x023D, 0x023E }, 556 { 0x0243, 0x0246 }, 557 { 0x0388, 0x038A }, 558 { 0x038E, 0x038F }, 559 { 0x0391, 0x03A1 }, 560 { 0x03A3, 0x03AB }, 561 { 0x03D2, 0x03D4 }, 562 { 0x03F9, 0x03FA }, 563 { 0x03FD, 0x042F }, 564 { 0x04C0, 0x04C1 }, 565 { 0x0531, 0x0556 }, 566 { 0x10A0, 0x10C5 }, 567 { 0x1F08, 0x1F0F }, 568 { 0x1F18, 0x1F1D }, 569 { 0x1F28, 0x1F2F }, 570 { 0x1F38, 0x1F3F }, 571 { 0x1F48, 0x1F4D }, 572 { 0x1F68, 0x1F6F }, 573 { 0x1FB8, 0x1FBB }, 574 { 0x1FC8, 0x1FCB }, 575 { 0x1FD8, 0x1FDB }, 576 { 0x1FE8, 0x1FEC }, 577 { 0x1FF8, 0x1FFB }, 578 { 0x210B, 0x210D }, 579 { 0x2110, 0x2112 }, 580 { 0x2119, 0x211D }, 581 { 0x212A, 0x212D }, 582 { 0x2130, 0x2133 }, 583 { 0x213E, 0x213F }, 584 { 0x2C00, 0x2C2E }, 585 { 0x2C62, 0x2C64 }, 586 { 0x2C6D, 0x2C70 }, 587 { 0x2C7E, 0x2C80 }, 588 { 0xA77D, 0xA77E }, 589 { 0xFF21, 0xFF3A }, 590 { 0x10400, 0x10427 }, 591 { 0x1D400, 0x1D419 }, 592 { 0x1D434, 0x1D44D }, 593 { 0x1D468, 0x1D481 }, 594 { 0x1D49E, 0x1D49F }, 595 { 0x1D4A5, 0x1D4A6 }, 596 { 0x1D4A9, 0x1D4AC }, 597 { 0x1D4AE, 0x1D4B5 }, 598 { 0x1D4D0, 0x1D4E9 }, 599 { 0x1D504, 0x1D505 }, 600 { 0x1D507, 0x1D50A }, 601 { 0x1D50D, 0x1D514 }, 602 { 0x1D516, 0x1D51C }, 603 { 0x1D538, 0x1D539 }, 604 { 0x1D53B, 0x1D53E }, 605 { 0x1D540, 0x1D544 }, 606 { 0x1D54A, 0x1D550 }, 607 { 0x1D56C, 0x1D585 }, 608 { 0x1D5A0, 0x1D5B9 }, 609 { 0x1D5D4, 0x1D5ED }, 610 { 0x1D608, 0x1D621 }, 611 { 0x1D63C, 0x1D655 }, 612 { 0x1D670, 0x1D689 }, 613 { 0x1D6A8, 0x1D6C0 }, 614 { 0x1D6E2, 0x1D6FA }, 615 { 0x1D71C, 0x1D734 }, 616 { 0x1D756, 0x1D76E }, 617 { 0x1D790, 0x1D7A8 }, 618 }; 619 620 static Rune upper1[] = { 621 0x0100, 622 0x0102, 623 0x0104, 624 0x0106, 625 0x0108, 626 0x010A, 627 0x010C, 628 0x010E, 629 0x0110, 630 0x0112, 631 0x0114, 632 0x0116, 633 0x0118, 634 0x011A, 635 0x011C, 636 0x011E, 637 0x0120, 638 0x0122, 639 0x0124, 640 0x0126, 641 0x0128, 642 0x012A, 643 0x012C, 644 0x012E, 645 0x0130, 646 0x0132, 647 0x0134, 648 0x0136, 649 0x0139, 650 0x013B, 651 0x013D, 652 0x013F, 653 0x0141, 654 0x0143, 655 0x0145, 656 0x0147, 657 0x014A, 658 0x014C, 659 0x014E, 660 0x0150, 661 0x0152, 662 0x0154, 663 0x0156, 664 0x0158, 665 0x015A, 666 0x015C, 667 0x015E, 668 0x0160, 669 0x0162, 670 0x0164, 671 0x0166, 672 0x0168, 673 0x016A, 674 0x016C, 675 0x016E, 676 0x0170, 677 0x0172, 678 0x0174, 679 0x0176, 680 0x017B, 681 0x017D, 682 0x0184, 683 0x01A2, 684 0x01A4, 685 0x01A9, 686 0x01AC, 687 0x01B5, 688 0x01BC, 689 0x01C4, 690 0x01C7, 691 0x01CA, 692 0x01CD, 693 0x01CF, 694 0x01D1, 695 0x01D3, 696 0x01D5, 697 0x01D7, 698 0x01D9, 699 0x01DB, 700 0x01DE, 701 0x01E0, 702 0x01E2, 703 0x01E4, 704 0x01E6, 705 0x01E8, 706 0x01EA, 707 0x01EC, 708 0x01EE, 709 0x01F1, 710 0x01F4, 711 0x01FA, 712 0x01FC, 713 0x01FE, 714 0x0200, 715 0x0202, 716 0x0204, 717 0x0206, 718 0x0208, 719 0x020A, 720 0x020C, 721 0x020E, 722 0x0210, 723 0x0212, 724 0x0214, 725 0x0216, 726 0x0218, 727 0x021A, 728 0x021C, 729 0x021E, 730 0x0220, 731 0x0222, 732 0x0224, 733 0x0226, 734 0x0228, 735 0x022A, 736 0x022C, 737 0x022E, 738 0x0230, 739 0x0232, 740 0x0241, 741 0x0248, 742 0x024A, 743 0x024C, 744 0x024E, 745 0x0370, 746 0x0372, 747 0x0376, 748 0x0386, 749 0x038C, 750 0x03CF, 751 0x03D8, 752 0x03DA, 753 0x03DC, 754 0x03DE, 755 0x03E0, 756 0x03E2, 757 0x03E4, 758 0x03E6, 759 0x03E8, 760 0x03EA, 761 0x03EC, 762 0x03EE, 763 0x03F4, 764 0x03F7, 765 0x0460, 766 0x0462, 767 0x0464, 768 0x0466, 769 0x0468, 770 0x046A, 771 0x046C, 772 0x046E, 773 0x0470, 774 0x0472, 775 0x0474, 776 0x0476, 777 0x0478, 778 0x047A, 779 0x047C, 780 0x047E, 781 0x0480, 782 0x048A, 783 0x048C, 784 0x048E, 785 0x0490, 786 0x0492, 787 0x0494, 788 0x0496, 789 0x0498, 790 0x049A, 791 0x049C, 792 0x049E, 793 0x04A0, 794 0x04A2, 795 0x04A4, 796 0x04A6, 797 0x04A8, 798 0x04AA, 799 0x04AC, 800 0x04AE, 801 0x04B0, 802 0x04B2, 803 0x04B4, 804 0x04B6, 805 0x04B8, 806 0x04BA, 807 0x04BC, 808 0x04BE, 809 0x04C3, 810 0x04C5, 811 0x04C7, 812 0x04C9, 813 0x04CB, 814 0x04CD, 815 0x04D0, 816 0x04D2, 817 0x04D4, 818 0x04D6, 819 0x04D8, 820 0x04DA, 821 0x04DC, 822 0x04DE, 823 0x04E0, 824 0x04E2, 825 0x04E4, 826 0x04E6, 827 0x04E8, 828 0x04EA, 829 0x04EC, 830 0x04EE, 831 0x04F0, 832 0x04F2, 833 0x04F4, 834 0x04F6, 835 0x04F8, 836 0x04FA, 837 0x04FC, 838 0x04FE, 839 0x0500, 840 0x0502, 841 0x0504, 842 0x0506, 843 0x0508, 844 0x050A, 845 0x050C, 846 0x050E, 847 0x0510, 848 0x0512, 849 0x0514, 850 0x0516, 851 0x0518, 852 0x051A, 853 0x051C, 854 0x051E, 855 0x0520, 856 0x0522, 857 0x0524, 858 0x0526, 859 0x10C7, 860 0x10CD, 861 0x1E00, 862 0x1E02, 863 0x1E04, 864 0x1E06, 865 0x1E08, 866 0x1E0A, 867 0x1E0C, 868 0x1E0E, 869 0x1E10, 870 0x1E12, 871 0x1E14, 872 0x1E16, 873 0x1E18, 874 0x1E1A, 875 0x1E1C, 876 0x1E1E, 877 0x1E20, 878 0x1E22, 879 0x1E24, 880 0x1E26, 881 0x1E28, 882 0x1E2A, 883 0x1E2C, 884 0x1E2E, 885 0x1E30, 886 0x1E32, 887 0x1E34, 888 0x1E36, 889 0x1E38, 890 0x1E3A, 891 0x1E3C, 892 0x1E3E, 893 0x1E40, 894 0x1E42, 895 0x1E44, 896 0x1E46, 897 0x1E48, 898 0x1E4A, 899 0x1E4C, 900 0x1E4E, 901 0x1E50, 902 0x1E52, 903 0x1E54, 904 0x1E56, 905 0x1E58, 906 0x1E5A, 907 0x1E5C, 908 0x1E5E, 909 0x1E60, 910 0x1E62, 911 0x1E64, 912 0x1E66, 913 0x1E68, 914 0x1E6A, 915 0x1E6C, 916 0x1E6E, 917 0x1E70, 918 0x1E72, 919 0x1E74, 920 0x1E76, 921 0x1E78, 922 0x1E7A, 923 0x1E7C, 924 0x1E7E, 925 0x1E80, 926 0x1E82, 927 0x1E84, 928 0x1E86, 929 0x1E88, 930 0x1E8A, 931 0x1E8C, 932 0x1E8E, 933 0x1E90, 934 0x1E92, 935 0x1E94, 936 0x1E9E, 937 0x1EA0, 938 0x1EA2, 939 0x1EA4, 940 0x1EA6, 941 0x1EA8, 942 0x1EAA, 943 0x1EAC, 944 0x1EAE, 945 0x1EB0, 946 0x1EB2, 947 0x1EB4, 948 0x1EB6, 949 0x1EB8, 950 0x1EBA, 951 0x1EBC, 952 0x1EBE, 953 0x1EC0, 954 0x1EC2, 955 0x1EC4, 956 0x1EC6, 957 0x1EC8, 958 0x1ECA, 959 0x1ECC, 960 0x1ECE, 961 0x1ED0, 962 0x1ED2, 963 0x1ED4, 964 0x1ED6, 965 0x1ED8, 966 0x1EDA, 967 0x1EDC, 968 0x1EDE, 969 0x1EE0, 970 0x1EE2, 971 0x1EE4, 972 0x1EE6, 973 0x1EE8, 974 0x1EEA, 975 0x1EEC, 976 0x1EEE, 977 0x1EF0, 978 0x1EF2, 979 0x1EF4, 980 0x1EF6, 981 0x1EF8, 982 0x1EFA, 983 0x1EFC, 984 0x1EFE, 985 0x1F59, 986 0x1F5B, 987 0x1F5D, 988 0x1F5F, 989 0x2102, 990 0x2107, 991 0x2115, 992 0x2124, 993 0x2126, 994 0x2128, 995 0x2145, 996 0x2183, 997 0x2C60, 998 0x2C67, 999 0x2C69, 1000 0x2C6B, 1001 0x2C72, 1002 0x2C75, 1003 0x2C82, 1004 0x2C84, 1005 0x2C86, 1006 0x2C88, 1007 0x2C8A, 1008 0x2C8C, 1009 0x2C8E, 1010 0x2C90, 1011 0x2C92, 1012 0x2C94, 1013 0x2C96, 1014 0x2C98, 1015 0x2C9A, 1016 0x2C9C, 1017 0x2C9E, 1018 0x2CA0, 1019 0x2CA2, 1020 0x2CA4, 1021 0x2CA6, 1022 0x2CA8, 1023 0x2CAA, 1024 0x2CAC, 1025 0x2CAE, 1026 0x2CB0, 1027 0x2CB2, 1028 0x2CB4, 1029 0x2CB6, 1030 0x2CB8, 1031 0x2CBA, 1032 0x2CBC, 1033 0x2CBE, 1034 0x2CC0, 1035 0x2CC2, 1036 0x2CC4, 1037 0x2CC6, 1038 0x2CC8, 1039 0x2CCA, 1040 0x2CCC, 1041 0x2CCE, 1042 0x2CD0, 1043 0x2CD2, 1044 0x2CD4, 1045 0x2CD6, 1046 0x2CD8, 1047 0x2CDA, 1048 0x2CDC, 1049 0x2CDE, 1050 0x2CE0, 1051 0x2CE2, 1052 0x2CEB, 1053 0x2CED, 1054 0x2CF2, 1055 0xA640, 1056 0xA642, 1057 0xA644, 1058 0xA646, 1059 0xA648, 1060 0xA64A, 1061 0xA64C, 1062 0xA64E, 1063 0xA650, 1064 0xA652, 1065 0xA654, 1066 0xA656, 1067 0xA658, 1068 0xA65A, 1069 0xA65C, 1070 0xA65E, 1071 0xA660, 1072 0xA662, 1073 0xA664, 1074 0xA666, 1075 0xA668, 1076 0xA66A, 1077 0xA66C, 1078 0xA680, 1079 0xA682, 1080 0xA684, 1081 0xA686, 1082 0xA688, 1083 0xA68A, 1084 0xA68C, 1085 0xA68E, 1086 0xA690, 1087 0xA692, 1088 0xA694, 1089 0xA696, 1090 0xA722, 1091 0xA724, 1092 0xA726, 1093 0xA728, 1094 0xA72A, 1095 0xA72C, 1096 0xA72E, 1097 0xA732, 1098 0xA734, 1099 0xA736, 1100 0xA738, 1101 0xA73A, 1102 0xA73C, 1103 0xA73E, 1104 0xA740, 1105 0xA742, 1106 0xA744, 1107 0xA746, 1108 0xA748, 1109 0xA74A, 1110 0xA74C, 1111 0xA74E, 1112 0xA750, 1113 0xA752, 1114 0xA754, 1115 0xA756, 1116 0xA758, 1117 0xA75A, 1118 0xA75C, 1119 0xA75E, 1120 0xA760, 1121 0xA762, 1122 0xA764, 1123 0xA766, 1124 0xA768, 1125 0xA76A, 1126 0xA76C, 1127 0xA76E, 1128 0xA779, 1129 0xA77B, 1130 0xA780, 1131 0xA782, 1132 0xA784, 1133 0xA786, 1134 0xA78B, 1135 0xA78D, 1136 0xA790, 1137 0xA792, 1138 0xA7A0, 1139 0xA7A2, 1140 0xA7A4, 1141 0xA7A6, 1142 0xA7A8, 1143 0xA7AA, 1144 0x1D49C, 1145 0x1D4A2, 1146 0x1D546, 1147 0x1D7CA, 1148 }; 1149 1150 int 1151 isupperrune(Rune r) 1152 { 1153 if(bsearch(&r, upper2, nelem(upper2), sizeof *upper2, &rune2cmp)) 1154 return 1; 1155 if(bsearch(&r, upper1, nelem(upper1), sizeof *upper1, &rune1cmp)) 1156 return 1; 1157 return 0; 1158 } 1159 1160 static Rune lower2[][2] = { 1161 { 0x0061, 0x007A }, 1162 { 0x00DF, 0x00F6 }, 1163 { 0x00F8, 0x00FF }, 1164 { 0x0137, 0x0138 }, 1165 { 0x0148, 0x0149 }, 1166 { 0x017E, 0x0180 }, 1167 { 0x018C, 0x018D }, 1168 { 0x0199, 0x019B }, 1169 { 0x01AA, 0x01AB }, 1170 { 0x01B9, 0x01BA }, 1171 { 0x01BD, 0x01BF }, 1172 { 0x01DC, 0x01DD }, 1173 { 0x01EF, 0x01F0 }, 1174 { 0x0233, 0x0239 }, 1175 { 0x023F, 0x0240 }, 1176 { 0x024F, 0x0293 }, 1177 { 0x0295, 0x02AF }, 1178 { 0x037B, 0x037D }, 1179 { 0x03AC, 0x03CE }, 1180 { 0x03D0, 0x03D1 }, 1181 { 0x03D5, 0x03D7 }, 1182 { 0x03EF, 0x03F3 }, 1183 { 0x03FB, 0x03FC }, 1184 { 0x0430, 0x045F }, 1185 { 0x04CE, 0x04CF }, 1186 { 0x0561, 0x0587 }, 1187 { 0x1D00, 0x1D2B }, 1188 { 0x1D6B, 0x1D77 }, 1189 { 0x1D79, 0x1D9A }, 1190 { 0x1E95, 0x1E9D }, 1191 { 0x1EFF, 0x1F07 }, 1192 { 0x1F10, 0x1F15 }, 1193 { 0x1F20, 0x1F27 }, 1194 { 0x1F30, 0x1F37 }, 1195 { 0x1F40, 0x1F45 }, 1196 { 0x1F50, 0x1F57 }, 1197 { 0x1F60, 0x1F67 }, 1198 { 0x1F70, 0x1F7D }, 1199 { 0x1F80, 0x1F87 }, 1200 { 0x1F90, 0x1F97 }, 1201 { 0x1FA0, 0x1FA7 }, 1202 { 0x1FB0, 0x1FB4 }, 1203 { 0x1FB6, 0x1FB7 }, 1204 { 0x1FC2, 0x1FC4 }, 1205 { 0x1FC6, 0x1FC7 }, 1206 { 0x1FD0, 0x1FD3 }, 1207 { 0x1FD6, 0x1FD7 }, 1208 { 0x1FE0, 0x1FE7 }, 1209 { 0x1FF2, 0x1FF4 }, 1210 { 0x1FF6, 0x1FF7 }, 1211 { 0x210E, 0x210F }, 1212 { 0x213C, 0x213D }, 1213 { 0x2146, 0x2149 }, 1214 { 0x2C30, 0x2C5E }, 1215 { 0x2C65, 0x2C66 }, 1216 { 0x2C73, 0x2C74 }, 1217 { 0x2C76, 0x2C7B }, 1218 { 0x2CE3, 0x2CE4 }, 1219 { 0x2D00, 0x2D25 }, 1220 { 0xA72F, 0xA731 }, 1221 { 0xA771, 0xA778 }, 1222 { 0xFB00, 0xFB06 }, 1223 { 0xFB13, 0xFB17 }, 1224 { 0xFF41, 0xFF5A }, 1225 { 0x10428, 0x1044F }, 1226 { 0x1D41A, 0x1D433 }, 1227 { 0x1D44E, 0x1D454 }, 1228 { 0x1D456, 0x1D467 }, 1229 { 0x1D482, 0x1D49B }, 1230 { 0x1D4B6, 0x1D4B9 }, 1231 { 0x1D4BD, 0x1D4C3 }, 1232 { 0x1D4C5, 0x1D4CF }, 1233 { 0x1D4EA, 0x1D503 }, 1234 { 0x1D51E, 0x1D537 }, 1235 { 0x1D552, 0x1D56B }, 1236 { 0x1D586, 0x1D59F }, 1237 { 0x1D5BA, 0x1D5D3 }, 1238 { 0x1D5EE, 0x1D607 }, 1239 { 0x1D622, 0x1D63B }, 1240 { 0x1D656, 0x1D66F }, 1241 { 0x1D68A, 0x1D6A5 }, 1242 { 0x1D6C2, 0x1D6DA }, 1243 { 0x1D6DC, 0x1D6E1 }, 1244 { 0x1D6FC, 0x1D714 }, 1245 { 0x1D716, 0x1D71B }, 1246 { 0x1D736, 0x1D74E }, 1247 { 0x1D750, 0x1D755 }, 1248 { 0x1D770, 0x1D788 }, 1249 { 0x1D78A, 0x1D78F }, 1250 { 0x1D7AA, 0x1D7C2 }, 1251 { 0x1D7C4, 0x1D7C9 }, 1252 }; 1253 1254 static Rune lower1[] = { 1255 0x00B5, 1256 0x0101, 1257 0x0103, 1258 0x0105, 1259 0x0107, 1260 0x0109, 1261 0x010B, 1262 0x010D, 1263 0x010F, 1264 0x0111, 1265 0x0113, 1266 0x0115, 1267 0x0117, 1268 0x0119, 1269 0x011B, 1270 0x011D, 1271 0x011F, 1272 0x0121, 1273 0x0123, 1274 0x0125, 1275 0x0127, 1276 0x0129, 1277 0x012B, 1278 0x012D, 1279 0x012F, 1280 0x0131, 1281 0x0133, 1282 0x0135, 1283 0x013A, 1284 0x013C, 1285 0x013E, 1286 0x0140, 1287 0x0142, 1288 0x0144, 1289 0x0146, 1290 0x014B, 1291 0x014D, 1292 0x014F, 1293 0x0151, 1294 0x0153, 1295 0x0155, 1296 0x0157, 1297 0x0159, 1298 0x015B, 1299 0x015D, 1300 0x015F, 1301 0x0161, 1302 0x0163, 1303 0x0165, 1304 0x0167, 1305 0x0169, 1306 0x016B, 1307 0x016D, 1308 0x016F, 1309 0x0171, 1310 0x0173, 1311 0x0175, 1312 0x0177, 1313 0x017A, 1314 0x017C, 1315 0x0183, 1316 0x0185, 1317 0x0188, 1318 0x0192, 1319 0x0195, 1320 0x019E, 1321 0x01A1, 1322 0x01A3, 1323 0x01A5, 1324 0x01A8, 1325 0x01AD, 1326 0x01B0, 1327 0x01B4, 1328 0x01B6, 1329 0x01C6, 1330 0x01C9, 1331 0x01CC, 1332 0x01CE, 1333 0x01D0, 1334 0x01D2, 1335 0x01D4, 1336 0x01D6, 1337 0x01D8, 1338 0x01DA, 1339 0x01DF, 1340 0x01E1, 1341 0x01E3, 1342 0x01E5, 1343 0x01E7, 1344 0x01E9, 1345 0x01EB, 1346 0x01ED, 1347 0x01F3, 1348 0x01F5, 1349 0x01F9, 1350 0x01FB, 1351 0x01FD, 1352 0x01FF, 1353 0x0201, 1354 0x0203, 1355 0x0205, 1356 0x0207, 1357 0x0209, 1358 0x020B, 1359 0x020D, 1360 0x020F, 1361 0x0211, 1362 0x0213, 1363 0x0215, 1364 0x0217, 1365 0x0219, 1366 0x021B, 1367 0x021D, 1368 0x021F, 1369 0x0221, 1370 0x0223, 1371 0x0225, 1372 0x0227, 1373 0x0229, 1374 0x022B, 1375 0x022D, 1376 0x022F, 1377 0x0231, 1378 0x023C, 1379 0x0242, 1380 0x0247, 1381 0x0249, 1382 0x024B, 1383 0x024D, 1384 0x0371, 1385 0x0373, 1386 0x0377, 1387 0x0390, 1388 0x03D9, 1389 0x03DB, 1390 0x03DD, 1391 0x03DF, 1392 0x03E1, 1393 0x03E3, 1394 0x03E5, 1395 0x03E7, 1396 0x03E9, 1397 0x03EB, 1398 0x03ED, 1399 0x03F5, 1400 0x03F8, 1401 0x0461, 1402 0x0463, 1403 0x0465, 1404 0x0467, 1405 0x0469, 1406 0x046B, 1407 0x046D, 1408 0x046F, 1409 0x0471, 1410 0x0473, 1411 0x0475, 1412 0x0477, 1413 0x0479, 1414 0x047B, 1415 0x047D, 1416 0x047F, 1417 0x0481, 1418 0x048B, 1419 0x048D, 1420 0x048F, 1421 0x0491, 1422 0x0493, 1423 0x0495, 1424 0x0497, 1425 0x0499, 1426 0x049B, 1427 0x049D, 1428 0x049F, 1429 0x04A1, 1430 0x04A3, 1431 0x04A5, 1432 0x04A7, 1433 0x04A9, 1434 0x04AB, 1435 0x04AD, 1436 0x04AF, 1437 0x04B1, 1438 0x04B3, 1439 0x04B5, 1440 0x04B7, 1441 0x04B9, 1442 0x04BB, 1443 0x04BD, 1444 0x04BF, 1445 0x04C2, 1446 0x04C4, 1447 0x04C6, 1448 0x04C8, 1449 0x04CA, 1450 0x04CC, 1451 0x04D1, 1452 0x04D3, 1453 0x04D5, 1454 0x04D7, 1455 0x04D9, 1456 0x04DB, 1457 0x04DD, 1458 0x04DF, 1459 0x04E1, 1460 0x04E3, 1461 0x04E5, 1462 0x04E7, 1463 0x04E9, 1464 0x04EB, 1465 0x04ED, 1466 0x04EF, 1467 0x04F1, 1468 0x04F3, 1469 0x04F5, 1470 0x04F7, 1471 0x04F9, 1472 0x04FB, 1473 0x04FD, 1474 0x04FF, 1475 0x0501, 1476 0x0503, 1477 0x0505, 1478 0x0507, 1479 0x0509, 1480 0x050B, 1481 0x050D, 1482 0x050F, 1483 0x0511, 1484 0x0513, 1485 0x0515, 1486 0x0517, 1487 0x0519, 1488 0x051B, 1489 0x051D, 1490 0x051F, 1491 0x0521, 1492 0x0523, 1493 0x0525, 1494 0x0527, 1495 0x1E01, 1496 0x1E03, 1497 0x1E05, 1498 0x1E07, 1499 0x1E09, 1500 0x1E0B, 1501 0x1E0D, 1502 0x1E0F, 1503 0x1E11, 1504 0x1E13, 1505 0x1E15, 1506 0x1E17, 1507 0x1E19, 1508 0x1E1B, 1509 0x1E1D, 1510 0x1E1F, 1511 0x1E21, 1512 0x1E23, 1513 0x1E25, 1514 0x1E27, 1515 0x1E29, 1516 0x1E2B, 1517 0x1E2D, 1518 0x1E2F, 1519 0x1E31, 1520 0x1E33, 1521 0x1E35, 1522 0x1E37, 1523 0x1E39, 1524 0x1E3B, 1525 0x1E3D, 1526 0x1E3F, 1527 0x1E41, 1528 0x1E43, 1529 0x1E45, 1530 0x1E47, 1531 0x1E49, 1532 0x1E4B, 1533 0x1E4D, 1534 0x1E4F, 1535 0x1E51, 1536 0x1E53, 1537 0x1E55, 1538 0x1E57, 1539 0x1E59, 1540 0x1E5B, 1541 0x1E5D, 1542 0x1E5F, 1543 0x1E61, 1544 0x1E63, 1545 0x1E65, 1546 0x1E67, 1547 0x1E69, 1548 0x1E6B, 1549 0x1E6D, 1550 0x1E6F, 1551 0x1E71, 1552 0x1E73, 1553 0x1E75, 1554 0x1E77, 1555 0x1E79, 1556 0x1E7B, 1557 0x1E7D, 1558 0x1E7F, 1559 0x1E81, 1560 0x1E83, 1561 0x1E85, 1562 0x1E87, 1563 0x1E89, 1564 0x1E8B, 1565 0x1E8D, 1566 0x1E8F, 1567 0x1E91, 1568 0x1E93, 1569 0x1E9F, 1570 0x1EA1, 1571 0x1EA3, 1572 0x1EA5, 1573 0x1EA7, 1574 0x1EA9, 1575 0x1EAB, 1576 0x1EAD, 1577 0x1EAF, 1578 0x1EB1, 1579 0x1EB3, 1580 0x1EB5, 1581 0x1EB7, 1582 0x1EB9, 1583 0x1EBB, 1584 0x1EBD, 1585 0x1EBF, 1586 0x1EC1, 1587 0x1EC3, 1588 0x1EC5, 1589 0x1EC7, 1590 0x1EC9, 1591 0x1ECB, 1592 0x1ECD, 1593 0x1ECF, 1594 0x1ED1, 1595 0x1ED3, 1596 0x1ED5, 1597 0x1ED7, 1598 0x1ED9, 1599 0x1EDB, 1600 0x1EDD, 1601 0x1EDF, 1602 0x1EE1, 1603 0x1EE3, 1604 0x1EE5, 1605 0x1EE7, 1606 0x1EE9, 1607 0x1EEB, 1608 0x1EED, 1609 0x1EEF, 1610 0x1EF1, 1611 0x1EF3, 1612 0x1EF5, 1613 0x1EF7, 1614 0x1EF9, 1615 0x1EFB, 1616 0x1EFD, 1617 0x1FBE, 1618 0x210A, 1619 0x2113, 1620 0x212F, 1621 0x2134, 1622 0x2139, 1623 0x214E, 1624 0x2184, 1625 0x2C61, 1626 0x2C68, 1627 0x2C6A, 1628 0x2C6C, 1629 0x2C71, 1630 0x2C81, 1631 0x2C83, 1632 0x2C85, 1633 0x2C87, 1634 0x2C89, 1635 0x2C8B, 1636 0x2C8D, 1637 0x2C8F, 1638 0x2C91, 1639 0x2C93, 1640 0x2C95, 1641 0x2C97, 1642 0x2C99, 1643 0x2C9B, 1644 0x2C9D, 1645 0x2C9F, 1646 0x2CA1, 1647 0x2CA3, 1648 0x2CA5, 1649 0x2CA7, 1650 0x2CA9, 1651 0x2CAB, 1652 0x2CAD, 1653 0x2CAF, 1654 0x2CB1, 1655 0x2CB3, 1656 0x2CB5, 1657 0x2CB7, 1658 0x2CB9, 1659 0x2CBB, 1660 0x2CBD, 1661 0x2CBF, 1662 0x2CC1, 1663 0x2CC3, 1664 0x2CC5, 1665 0x2CC7, 1666 0x2CC9, 1667 0x2CCB, 1668 0x2CCD, 1669 0x2CCF, 1670 0x2CD1, 1671 0x2CD3, 1672 0x2CD5, 1673 0x2CD7, 1674 0x2CD9, 1675 0x2CDB, 1676 0x2CDD, 1677 0x2CDF, 1678 0x2CE1, 1679 0x2CEC, 1680 0x2CEE, 1681 0x2CF3, 1682 0x2D27, 1683 0x2D2D, 1684 0xA641, 1685 0xA643, 1686 0xA645, 1687 0xA647, 1688 0xA649, 1689 0xA64B, 1690 0xA64D, 1691 0xA64F, 1692 0xA651, 1693 0xA653, 1694 0xA655, 1695 0xA657, 1696 0xA659, 1697 0xA65B, 1698 0xA65D, 1699 0xA65F, 1700 0xA661, 1701 0xA663, 1702 0xA665, 1703 0xA667, 1704 0xA669, 1705 0xA66B, 1706 0xA66D, 1707 0xA681, 1708 0xA683, 1709 0xA685, 1710 0xA687, 1711 0xA689, 1712 0xA68B, 1713 0xA68D, 1714 0xA68F, 1715 0xA691, 1716 0xA693, 1717 0xA695, 1718 0xA697, 1719 0xA723, 1720 0xA725, 1721 0xA727, 1722 0xA729, 1723 0xA72B, 1724 0xA72D, 1725 0xA733, 1726 0xA735, 1727 0xA737, 1728 0xA739, 1729 0xA73B, 1730 0xA73D, 1731 0xA73F, 1732 0xA741, 1733 0xA743, 1734 0xA745, 1735 0xA747, 1736 0xA749, 1737 0xA74B, 1738 0xA74D, 1739 0xA74F, 1740 0xA751, 1741 0xA753, 1742 0xA755, 1743 0xA757, 1744 0xA759, 1745 0xA75B, 1746 0xA75D, 1747 0xA75F, 1748 0xA761, 1749 0xA763, 1750 0xA765, 1751 0xA767, 1752 0xA769, 1753 0xA76B, 1754 0xA76D, 1755 0xA76F, 1756 0xA77A, 1757 0xA77C, 1758 0xA77F, 1759 0xA781, 1760 0xA783, 1761 0xA785, 1762 0xA787, 1763 0xA78C, 1764 0xA78E, 1765 0xA791, 1766 0xA793, 1767 0xA7A1, 1768 0xA7A3, 1769 0xA7A5, 1770 0xA7A7, 1771 0xA7A9, 1772 0xA7FA, 1773 0x1D4BB, 1774 0x1D7CB, 1775 }; 1776 1777 int 1778 islowerrune(Rune r) 1779 { 1780 if(bsearch(&r, lower2, nelem(lower2), sizeof *lower2, &rune2cmp)) 1781 return 1; 1782 if(bsearch(&r, lower1, nelem(lower1), sizeof *lower1, &rune1cmp)) 1783 return 1; 1784 return 0; 1785 } 1786 1787 static Rune title2[][2] = { 1788 { 0x1F88, 0x1F8F }, 1789 { 0x1F98, 0x1F9F }, 1790 { 0x1FA8, 0x1FAF }, 1791 }; 1792 1793 static Rune title1[] = { 1794 0x01C5, 1795 0x01C8, 1796 0x01CB, 1797 0x01F2, 1798 0x1FBC, 1799 0x1FCC, 1800 0x1FFC, 1801 }; 1802 1803 int 1804 istitlerune(Rune r) 1805 { 1806 if(bsearch(&r, title2, nelem(title2), sizeof *title2, &rune2cmp)) 1807 return 1; 1808 if(bsearch(&r, title1, nelem(title1), sizeof *title1, &rune1cmp)) 1809 return 1; 1810 return 0; 1811 } 1812 1813 static Rune digit2[][2] = { 1814 { 0x0030, 0x0039 }, 1815 { 0x0660, 0x0669 }, 1816 { 0x06F0, 0x06F9 }, 1817 { 0x07C0, 0x07C9 }, 1818 { 0x0966, 0x096F }, 1819 { 0x09E6, 0x09EF }, 1820 { 0x0A66, 0x0A6F }, 1821 { 0x0AE6, 0x0AEF }, 1822 { 0x0B66, 0x0B6F }, 1823 { 0x0BE6, 0x0BEF }, 1824 { 0x0C66, 0x0C6F }, 1825 { 0x0CE6, 0x0CEF }, 1826 { 0x0D66, 0x0D6F }, 1827 { 0x0E50, 0x0E59 }, 1828 { 0x0ED0, 0x0ED9 }, 1829 { 0x0F20, 0x0F29 }, 1830 { 0x1040, 0x1049 }, 1831 { 0x1090, 0x1099 }, 1832 { 0x17E0, 0x17E9 }, 1833 { 0x1810, 0x1819 }, 1834 { 0x1946, 0x194F }, 1835 { 0x19D0, 0x19D9 }, 1836 { 0x1A80, 0x1A89 }, 1837 { 0x1A90, 0x1A99 }, 1838 { 0x1B50, 0x1B59 }, 1839 { 0x1BB0, 0x1BB9 }, 1840 { 0x1C40, 0x1C49 }, 1841 { 0x1C50, 0x1C59 }, 1842 { 0xA620, 0xA629 }, 1843 { 0xA8D0, 0xA8D9 }, 1844 { 0xA900, 0xA909 }, 1845 { 0xA9D0, 0xA9D9 }, 1846 { 0xAA50, 0xAA59 }, 1847 { 0xABF0, 0xABF9 }, 1848 { 0xFF10, 0xFF19 }, 1849 { 0x104A0, 0x104A9 }, 1850 { 0x11066, 0x1106F }, 1851 { 0x110F0, 0x110F9 }, 1852 { 0x11136, 0x1113F }, 1853 { 0x111D0, 0x111D9 }, 1854 { 0x116C0, 0x116C9 }, 1855 { 0x1D7CE, 0x1D7FF }, 1856 }; 1857 1858 int 1859 isdigitrune(Rune r) 1860 { 1861 if(bsearch(&r, digit2, nelem(digit2), sizeof *digit2, &rune2cmp)) 1862 return 1; 1863 return 0; 1864 } 1865