| 1 | # U.S. English Computer Braille Code |
| 2 | # <http://liblouis.io/braille-specs/english/#computer-braille-code-cbc> |
| 3 | # |
| 4 | # Copyright © 2019 by Timothy Wynn |
| 5 | # Copyright © 2021 by BAUM Engineering |
| 6 | # |
| 7 | # Copying and distribution of this file, with or without modification, |
| 8 | # are permitted in any medium without royalty provided the copyright |
| 9 | # notice and this notice are preserved. This file is offered as-is, |
| 10 | # without any warranty. |
| 11 | # ---------------------------------------------------------------------------------------------- |
| 12 | |
| 13 | display: unicode.dis |
| 14 | table: |
| 15 | language: en |
| 16 | region: en-US |
| 17 | type: computer |
| 18 | dots: 6 |
| 19 | __assert-match: en-us-comp6.ctb |
| 20 | |
| 21 | flags: {testmode: bothDirections} |
| 22 | tests: |
| 23 | # Character Definitions: |
| 24 | # Alphanumeric characters: |
| 25 | - - AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz |
| 26 | - ⠸⠁⠁⠸⠃⠃⠸⠉⠉⠸⠙⠙⠸⠑⠑⠸⠋⠋⠸⠛⠛⠸⠓⠓⠸⠊⠊⠸⠚⠚⠸⠅⠅⠸⠇⠇⠸⠍⠍⠸⠝⠝⠸⠕⠕⠸⠏⠏⠸⠟⠟⠸⠗⠗⠸⠎⠎⠸⠞⠞⠸⠥⠥⠸⠧⠧⠸⠺⠺⠸⠭⠭⠸⠽⠽⠸⠵⠵ |
| 27 | - [0123456789, ⠴⠂⠆⠒⠲⠢⠖⠶⠦⠔] |
| 28 | # Single-Cell Symbols: |
| 29 | - ["!\"#$%&'()*+,-./:;<=>?@[\\\\]^", ⠮⠐⠼⠫⠩⠯⠄⠷⠾⠡⠬⠠⠤⠨⠌⠱⠰⠣⠿⠜⠹⠈⠪⠳⠻⠘] |
| 30 | # Braille symbols with the 456 prefix: |
| 31 | - ["_`{|}~", ⠸⠸⠸⠈⠸⠪⠸⠳⠸⠻⠸⠘] |
| 32 | |
| 33 | # Braille Indicators: |
| 34 | # capsLetter already tested (see above alphabet. |
| 35 | # Upper and Lower Case Designation: "Two or more upper case letters |
| 36 | # occurring in predominantly lower case text—whether these letters |
| 37 | # appear consecutively or are separated by numbers, punctuation, |
| 38 | # etc.—must be preceded by the caps lock indicator[, and] remains in |
| 39 | # effect until cancelled by the caps release indicator or the next |
| 40 | # significant space, whichever comes first" (pp. 19-20). |
| 41 | # Example 4.4.1: Caps Lock and Caps Release Indicators (p. 20): |
| 42 | - [VFUN PSTmsgToVec(ipcMsg, ⠸⠜⠧⠋⠥⠝⠀⠸⠜⠏⠎⠞⠸⠣⠍⠎⠛⠸⠞⠕⠸⠧⠑⠉⠷⠊⠏⠉⠸⠍⠎⠛] |
| 43 | # Modify above example to test a capsModeChar (2): |
| 44 | - [VFUN PSTmsG2Vec(ipcMsg, ⠸⠜⠧⠋⠥⠝⠀⠸⠜⠏⠎⠞⠸⠣⠍⠎⠸⠜⠛⠆⠧⠸⠣⠑⠉⠷⠊⠏⠉⠸⠍⠎⠛] |
| 45 | |
| 46 | # Isolated Lower-Cell Signs: "When a lower-cell sign is isolated |
| 47 | # (i.e., preceded and followed by a space or line end), dots 456 must |
| 48 | # immediately precede this sign. The lower-cell sign may be a |
| 49 | # single-digit number, quotation mark, apostrophe, comma, hyphen/minus |
| 50 | # sign, or semicolon" (p. 27). |
| 51 | # Example 8.1.1: Isolated Lower-Cell Signs (p. 27): |
| 52 | # Note: The below example has been modified to use lowercase letters. |
| 53 | - - "107 : clear ylen 0 do xlen 0 do 0 i j universe c! loop loop ;" |
| 54 | - ⠂⠴⠶⠀⠱⠀⠉⠇⠑⠁⠗⠀⠽⠇⠑⠝⠀⠸⠴⠀⠙⠕⠀⠭⠇⠑⠝⠀⠸⠴⠀⠙⠕⠀⠸⠴⠀⠊⠀⠚⠀⠥⠝⠊⠧⠑⠗⠎⠑⠀⠉⠮⠀⠇⠕⠕⠏⠀⠇⠕⠕⠏⠀⠸⠰ |
| 55 | |
| 56 | flags: {testmode: forward} |
| 57 | # Typeforms only supported with testmode 'forward'. |
| 58 | tests: |
| 59 | # Emphasis Indicators: |
| 60 | # Example 10.1.1 Emphasis Indicators (p. 33): |
| 61 | # Note: Only the computer braille portion of the example is utilized. |
| 62 | - - "&Hdddd where dddd" |
| 63 | - ⠯⠸⠓⠸⠡⠙⠙⠙⠙⠸⠌⠀⠺⠓⠑⠗⠑⠀⠸⠡⠙⠙⠙⠙⠸⠌ |
| 64 | - typeform: |
| 65 | italic: " ++++ ++++" |
| 66 | |
| 67 | # Spaces |
| 68 | flags: {testmode: bothDirections} |
| 69 | tests: |
| 70 | - ['\x0020', '⠀'] |
| 71 | flags: {testmode: forward} |
| 72 | tests: |
| 73 | - ['\x0009', '⠀'] |
| 74 | - ['\x000a', '⠀'] |
| 75 | - ['\x000d', '⠀'] |
| 76 | - ['\x00a0', '⠀'] |
| 77 | |
| 78 | # Apostrophes |
| 79 | flags: {testmode: forward} |
| 80 | tests: |
| 81 | - ['\x2019\x00b4\x0027', '⠄⠄⠄'] |