~ubuntu-branches/debian/jessie/liblouis/jessie

« back to all changes in this revision

Viewing changes to doc/liblouis.html

  • Committer: Bazaar Package Importer
  • Author(s): Samuel Thibault
  • Date: 2010-01-12 23:48:47 UTC
  • mto: (1.1.4 upstream) (5.2.1 experimental)
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20100112234847-ph9xdk3lrjdox6ks
ImportĀ upstreamĀ versionĀ 1.8.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
<title>Liblouis User's and Programmer's Manual</title>
4
4
<meta http-equiv="Content-Type" content="text/html">
5
5
<meta name="description" content="Liblouis User's and Programmer's Manual">
6
 
<meta name="generator" content="makeinfo 4.8">
 
6
<meta name="generator" content="makeinfo 4.11">
7
7
<link title="Top" rel="top" href="#Top">
8
8
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
9
9
<!--
10
 
This manual is for liblouis (version 1.7.0, 20 August 2009),
 
10
This manual is for liblouis (version 1.8.0, 18 November 2009),
11
11
a Braille Translation and Back-Translation Library derived from the
12
12
Linux screenreader BRLTTY.
13
13
 
59
59
<li><a href="#lou_005fdebug">2.1 lou_debug</a>
60
60
<li><a href="#lou_005fchecktable">2.2 lou_checktable</a>
61
61
<li><a href="#lou_005fallround">2.3 lou_allround</a>
62
 
<li><a href="#lou_005ftranslate-_002df-_007c-_002db-tablename">2.4 lou_translate -f | -b tablename</a>
 
62
<li><a href="#lou_005ftranslate-_0028program_0029">2.4 lou_translate</a>
 
63
<li><a href="#lou_005fcheckhyphens">2.5 lou_checkhyphens</a>
63
64
</li></ul>
64
65
<li><a name="toc_How-to-Write-Translation-Tables" href="#How-to-Write-Translation-Tables">3 How to Write Translation Tables</a>
65
66
<ul>
107
108
 
108
109
<h2 class="unnumbered">Liblouis User's and Programmer's Manual</h2>
109
110
 
110
 
<p>This manual is for liblouis (version 1.7.0, 20 August 2009),
 
111
<p>This manual is for liblouis (version 1.8.0, 18 November 2009),
111
112
a Braille Translation and Back-Translation Library derived from the
112
113
Linux screenreader <acronym>BRLTTY</acronym>.
113
114
 
166
167
 
167
168
<h2 class="chapter">2 Test Programs</h2>
168
169
 
169
 
<p>Four test programs are provided as part of the liblouis package. They
 
170
<p>Five test programs are provided as part of the liblouis package. They
170
171
are intended for testing liblouis and for debugging tables. None of
171
172
them is suitable for braille transcription. An application that can be
172
173
used for transcription is <samp><span class="command">xml2brl</span></samp>, which is part of the
174
175
test programs can be studied to learn how to use the liblouis library
175
176
and they can be used to perform the following functions.
176
177
 
 
178
   <p><a name="common-options"></a>All of these programs recognize the <samp><span class="option">--help</span></samp> and
 
179
<samp><span class="option">--version</span></samp> options.
 
180
 
 
181
     <dl>
 
182
<dt><samp><span class="option">--help</span></samp><dt><samp><span class="option">-h</span></samp><dd>Print a usage message listing all available options, then exit
 
183
successfully.
 
184
 
 
185
     <br><dt><samp><span class="option">--version</span></samp><dt><samp><span class="option">-v</span></samp><dd>Print the version number, then exit successfully.
 
186
 
 
187
   </dl>
 
188
 
177
189
<p><a name="lou_debug"></a>
178
190
<a name="lou_005fdebug"></a>
179
191
 
183
195
The lou_debug tool is intended for debugging liblouis translation
184
196
tables. The command line for lou_debug is:
185
197
 
186
 
   <p><kbd>lou_debug table-name</kbd>
 
198
<pre class="example">     lou_debug [OPTIONS] TABLE[,TABLE,...]
 
199
</pre>
 
200
   <p>The command line options that are accepted by lou_debug are described
 
201
in <a href="#common-options">common options</a>.
187
202
 
188
203
   <p>The table (or comma-separated list of tables) is compiled. If no
189
204
errors are found a brief command summary is printed, then the prompt
190
 
`<samp><span class="samp">Command:</span></samp>'. You can then input one of the command letters and get
 
205
&lsquo;<samp><span class="samp">Command:</span></samp>&rsquo;. You can then input one of the command letters and get
191
206
output, as described below.
192
207
 
193
208
   <p>Most of the commands print information in the various arrays of
194
209
<code>TranslationTableHeader</code>. Since these arrays are pointers to
195
210
chains of hashed items, the commands first print the hash number, then
196
211
the first item, then the next item chained to it, and so on. After
197
 
each item there is a prompt indicated by `<samp><span class="samp">=&gt;</span></samp>'. You can then press
 
212
each item there is a prompt indicated by &lsquo;<samp><span class="samp">=&gt;</span></samp>&rsquo;. You can then press
198
213
enter (<kbd>&lt;RET&gt;</kbd>) to see the next item in the chain or the first
199
214
item in the next chain. Or you can press <kbd>h</kbd> (for next-(h)ash) to
200
215
skip to the next hash chain. You can also press <kbd>e</kbd> to exit the
201
 
command and go back to the `<samp><span class="samp">command:</span></samp>' prompt.
 
216
command and go back to the &lsquo;<samp><span class="samp">command:</span></samp>&rsquo; prompt.
202
217
 
203
218
     <dl>
204
219
<dt><kbd>h</kbd><dd>Brings up a screen of somewhat more extensive help.
205
220
 
206
221
     <br><dt><kbd>f</kbd><dd>Display the first forward-translation rule in the first non-empty hash
207
222
bucket. The number of the bucket is displayed at the beginning of the
208
 
chain. Each rule is identified by the word `<samp><span class="samp">Rule:</span></samp>'. The fields
 
223
chain. Each rule is identified by the word &lsquo;<samp><span class="samp">Rule:</span></samp>&rsquo;. The fields
209
224
are displayed by phrases consisting of the name of the field, an equal
210
225
sign, and its value. The before and after fields are displayed only if
211
226
they are nonzero. Special opcodes such as the <code>correct</code> opcode (see <a href="#correct-opcode">correct</a>) and
212
227
the multipass opcodes are shown with the code that instructs the
213
228
virtual machine that interprets them. If you want to see only the
214
229
rules for a particular character string you can type <kbd>p</kbd> at the
215
 
`<samp><span class="samp">command:</span></samp>' prompt. This will take you to the `<samp><span class="samp">particular:</span></samp>'
 
230
&lsquo;<samp><span class="samp">command:</span></samp>&rsquo; prompt. This will take you to the &lsquo;<samp><span class="samp">particular:</span></samp>&rsquo;
216
231
prompt, where you can press <kbd>f</kbd> and then type in the string. The
217
232
whole hash chain containing the string will be displayed.
218
233
 
238
253
a 6-dot code. Note that the character-definition opcodes should use
239
254
8-dot computer braille.
240
255
 
241
 
     <br><dt><kbd>p</kbd><dd>Bring up a secondary (`<samp><span class="samp">particular:</span></samp>') prompt from which you can
 
256
     <br><dt><kbd>p</kbd><dd>Bring up a secondary (&lsquo;<samp><span class="samp">particular:</span></samp>&rsquo;) prompt from which you can
242
257
examine particular character strings, dot patterns, etc. The commands
243
258
(given in its own command summary) are very similar to those of the
244
 
main `<samp><span class="samp">command:</span></samp>' prompt, but you can type a character string or
 
259
main &lsquo;<samp><span class="samp">command:</span></samp>&rsquo; prompt, but you can type a character string or
245
260
dot pattern. They include <kbd>h</kbd>, <kbd>f</kbd>, <kbd>b</kbd>, <kbd>c</kbd>, <kbd>d</kbd>,
246
261
<kbd>C</kbd>, <kbd>D</kbd>, <kbd>z</kbd> and <kbd>x</kbd> (to exit this prompt), but not
247
262
<kbd>p</kbd>, <kbd>i</kbd> and <kbd>m</kbd>.
268
283
<h3 class="section">2.2 lou_checktable</h3>
269
284
 
270
285
<p><a name="index-lou_005fchecktable-2"></a>
271
 
To use this program type <kbd>lou_checktable</kbd> followed by a space and
272
 
the name of a table. If the table contains errors, appropriate
273
 
messages will be displayed. If there are no errors the message
274
 
`<samp><span class="samp">no errors found.</span></samp>' will be shown.
 
286
To use this program type the following:
 
287
 
 
288
<pre class="example">     lou_checktable [OPTIONS] TABLE
 
289
</pre>
 
290
   <p>The command line options that are accepted by lou_checktable are
 
291
described in <a href="#common-options">common options</a>.
 
292
 
 
293
   <p>If the table contains errors, appropriate messages will be displayed. 
 
294
If there are no errors the message &lsquo;<samp><span class="samp">no errors found.</span></samp>&rsquo; will be
 
295
shown.
275
296
 
276
297
<p><a name="lou_allround"></a>
277
298
<a name="lou_005fallround"></a>
280
301
 
281
302
<p><a name="index-lou_005fallround-3"></a>
282
303
This program tests every capability of the liblouis library. It is
283
 
completely interactive. To start it, type <kbd>lou_allround</kbd> and then
284
 
&lt;RET&gt;. You will see a few lines telling you how to use the
285
 
program. Pressing one of the letters in parentheses and then enter
286
 
will take you to a message asking for more information or for the
287
 
answer to a yes/no question. Typing the letter `<samp><span class="samp">r</span></samp>' and then
288
 
&lt;RET&gt; will take you to a screen where you can enter a line to be
289
 
processed by the library and then view the results.
290
 
 
291
 
<p><a name="lou_translate--f-%7c--b-tablename"></a>
292
 
<a name="lou_005ftranslate-_002df-_007c-_002db-tablename"></a>
293
 
 
294
 
<h3 class="section">2.4 lou_translate -f | -b tablename</h3>
 
304
completely interactive. Invoke it as follows:
 
305
 
 
306
<pre class="example">     lou_allround [OPTIONS]
 
307
</pre>
 
308
   <p>The command line options that are accepted by lou_debug are described
 
309
in <a href="#common-options">common options</a>.
 
310
 
 
311
   <p>You will see a few lines telling you how to use the program. Pressing
 
312
one of the letters in parentheses and then enter will take you to a
 
313
message asking for more information or for the answer to a yes/no
 
314
question. Typing the letter &lsquo;<samp><span class="samp">r</span></samp>&rsquo; and then &lt;RET&gt; will take you
 
315
to a screen where you can enter a line to be processed by the library
 
316
and then view the results.
 
317
 
 
318
<p><a name="lou_translate-(program)"></a>
 
319
<a name="lou_005ftranslate-_0028program_0029"></a>
 
320
 
 
321
<h3 class="section">2.4 lou_translate</h3>
295
322
 
296
323
<p><a name="index-lou_005ftranslate-4"></a>
297
324
This program translates whatever is on the standard input unit and
298
325
prints it on the standard output unit. It is intended for large-scale
299
 
testing of the accuracy of translation and back-translation. The first
300
 
argument must be <samp><span class="option">-f</span></samp> for forward translation or <samp><span class="option">-b</span></samp> for
301
 
backward translation. To use it to translate or back-translate a file
302
 
use a line like
303
 
 
304
 
   <p><kbd>./lou_translate -f en-us-g2.ctb &lt;liblouis.txt &gt;testtrans</kbd>
 
326
testing of the accuracy of translation and back-translation. The
 
327
command line for lou_translate is:
 
328
 
 
329
<pre class="example">     lou_translate [OPTION] TABLE
 
330
</pre>
 
331
   <p>Aside from the standard options (see <a href="#common-options">common options</a>) this program
 
332
also accepts the following options:
 
333
 
 
334
     <dl>
 
335
<dt><samp><span class="option">--forward</span></samp><dt><samp><span class="option">-f</span></samp><dd>Do a forward translation.
 
336
 
 
337
     <br><dt><samp><span class="option">--backward</span></samp><dt><samp><span class="option">-b</span></samp><dd>Do a backward translation.
 
338
 
 
339
   </dl>
 
340
 
 
341
   <p>To use it to translate or back-translate a file use a line like
 
342
 
 
343
<pre class="example">     lou_translate --forward en-us-g2.ctb &lt;liblouis.txt &gt;testtrans
 
344
</pre>
 
345
   <p><a name="lou_checkhyphens"></a>
 
346
<a name="lou_005fcheckhyphens"></a>
 
347
 
 
348
<h3 class="section">2.5 lou_checkhyphens</h3>
 
349
 
 
350
<p><a name="index-lou_005fcheckhyphens-5"></a>
 
351
This program checks the accuracy of hyphenation in Braille translation
 
352
for both translated and untranslated words. It is completely
 
353
interactive. Invoke it as follows:
 
354
 
 
355
<pre class="example">     lou_checkhyphens [OPTIONS]
 
356
</pre>
 
357
   <p>The command line options that are accepted by lou_checkhyphens are
 
358
described in <a href="#common-options">common options</a>.
 
359
 
 
360
   <p>You will see a few lines telling you how to use the program.
305
361
 
306
362
<p><a name="How-to-Write-Translation-Tables"></a>
307
363
 
331
387
files or 16-bit little-endian Unicode files. Blank lines are ignored. 
332
388
Any leading and trailing white-space (any number of blanks and/or tabs)
333
389
is ignored. Lines which begin with a number sign or hatch mark
334
 
(`<samp><span class="samp">#</span></samp>') are ignored, i.e. they are comments. If the number sign is
 
390
(&lsquo;<samp><span class="samp">#</span></samp>&rsquo;) are ignored, i.e. they are comments. If the number sign is
335
391
not the first non-blank character in the line, it is treated as an
336
392
ordinary character. If the first non-blank character is less-than
337
 
(`<samp><span class="samp">&lt;</span></samp>') the line is also treated as a comment. This makes it possible
 
393
(&lsquo;<samp><span class="samp">&lt;</span></samp>&rsquo;) the line is also treated as a comment. This makes it possible
338
394
to mark up tables as xhtml documents. Lines which are not blank or
339
395
comments define table entries. The general format of a table entry is:
340
396
 
347
403
certain number of operands. Any text on the line after the last
348
404
operand is ignored, and may be a comment. A few opcodes accept a
349
405
variable number of operands. In this case a number sign begins a
350
 
comment unless it is preceded by a backslash (`<samp><span class="samp">\</span></samp>'). See <a href="#Opcode-Index">Opcode Index</a>, for a list of opcodes, with a link to each one.
 
406
comment unless it is preceded by a backslash (&lsquo;<samp><span class="samp">\</span></samp>&rsquo;). See <a href="#Opcode-Index">Opcode Index</a>, for a list of opcodes, with a link to each one.
351
407
 
352
408
   <p>Here are some examples of table entries.
353
409
 
388
444
through 8, must be specified with their standard numbers. liblouis
389
445
recognizes "virtual dots," which are used for special purposes, such
390
446
as distinguishing accent marks. There are seven virtual dots. They are
391
 
specified by the number 9 and the letters `<samp><span class="samp">a</span></samp>' through `<samp><span class="samp">f</span></samp>'. 
 
447
specified by the number 9 and the letters &lsquo;<samp><span class="samp">a</span></samp>&rsquo; through &lsquo;<samp><span class="samp">f</span></samp>&rsquo;. 
392
448
For a multi-cell dot pattern, the cell specifications must be
393
 
separated from one another by a dash (`<samp><span class="samp">-</span></samp>'). For example, the
394
 
contraction for the English word `<samp><span class="samp">lord</span></samp>' (the letter `<samp><span class="samp">l</span></samp>'
 
449
separated from one another by a dash (&lsquo;<samp><span class="samp">-</span></samp>&rsquo;). For example, the
 
450
contraction for the English word &lsquo;<samp><span class="samp">lord</span></samp>&rsquo; (the letter &lsquo;<samp><span class="samp">l</span></samp>&rsquo;
395
451
preceded by dot 5) would be specified as 5-123. A space may be
396
452
specified with the special dot number 0.
397
453
 
467
523
the character is treated as a space.
468
524
 
469
525
     
470
 
<a name="index-space-5"></a>
471
 
<dl><a name="space-opcode"></a>
472
 
<dt><code>space character dots</code><dd>
 
526
<a name="index-space-6"></a>
 
527
<dl><a name="space-opcode"></a><dt><code>space character dots</code><dd>
473
528
Defines a character as a space and also defines the dot pattern as
474
529
such. for example:
475
530
 
476
531
     <pre class="example">          space \s 0 \s is the escape sequence for blank; 0 means no dots.
477
 
     </pre>
478
 
     <p><a name="index-punctuation-6"></a><a name="punctuation-opcode"></a>
479
 
<br><dt><code>punctuation character dots</code><dd>
 
532
</pre>
 
533
     <p><a name="index-punctuation-7"></a><a name="punctuation-opcode"></a><br><dt><code>punctuation character dots</code><dd>
480
534
Associates a punctuation mark in the particular language with a
481
535
braille representation and defines the character and dot pattern as
482
536
punctuation. For example:
483
537
 
484
538
     <pre class="example">          punctuation . 46 dot pattern for period in NAB computer braille
485
 
     </pre>
486
 
     <p><a name="index-digit-7"></a><a name="digit-opcode"></a>
487
 
<br><dt><code>digit character dots</code><dd>
 
539
</pre>
 
540
     <p><a name="index-digit-8"></a><a name="digit-opcode"></a><br><dt><code>digit character dots</code><dd>
488
541
Associates a digit with a dot pattern and defines the character as a
489
542
digit. For example:
490
543
 
491
544
     <pre class="example">          digit 0 356 NAB computer braille
492
 
     </pre>
493
 
     <p><a name="index-uplow-8"></a><a name="uplow-opcode"></a>
494
 
<br><dt><code>uplow characters dots [,dots]</code><dd>
 
545
</pre>
 
546
     <p><a name="index-uplow-9"></a><a name="uplow-opcode"></a><br><dt><code>uplow characters dots [,dots]</code><dd>
495
547
The characters operand must be a pair of letters, of which the first
496
548
is uppercase and the second lowercase. The first dots suboperand
497
549
indicates the dot pattern for the upper-case letter. It may have more
506
558
distinction is important in the forward translator. for example:
507
559
 
508
560
     <pre class="example">          uplow Aa 17,1
509
 
     </pre>
510
 
     <p><a name="index-grouping-9"></a><a name="grouping-opcode"></a>
511
 
<br><dt><code>grouping name characters dots ,dots</code><dd>
 
561
</pre>
 
562
     <p><a name="index-grouping-10"></a><a name="grouping-opcode"></a><br><dt><code>grouping name characters dots ,dots</code><dd>
512
563
This opcode is used to indicate pairs of grouping symbols used in
513
564
processing mathematical expressions. These symbols are usually generated
514
565
by the MathML interpreter in liblouisxml. They are used in multipass
521
572
 
522
573
     <pre class="example">          grouping mrow \x0001\x0002 1e,2e
523
574
          grouping mfrac \x0003\x0004 3e,4e
524
 
     </pre>
525
 
     <p><a name="index-letter-10"></a><a name="letter-opcode"></a>
526
 
<br><dt><code>letter character dots</code><dd>
 
575
</pre>
 
576
     <p><a name="index-letter-11"></a><a name="letter-opcode"></a><br><dt><code>letter character dots</code><dd>
527
577
Associates a letter in the language with a braille representation and
528
578
defines the character as a letter. This is intended for letters which
529
579
are neither uppercase nor lowercase.
530
580
 
531
 
     <p><a name="index-lowercase-11"></a><a name="lowercase-opcode"></a>
532
 
<br><dt><code>lowercase character dots</code><dd>
 
581
     <p><a name="index-lowercase-12"></a><a name="lowercase-opcode"></a><br><dt><code>lowercase character dots</code><dd>
533
582
Associates a character with a dot pattern and defines the character as
534
583
a lowercase letter. Both the character and the dot pattern have the
535
584
attributes lowercase and letter.
536
585
 
537
 
     <p><a name="index-uppercase-12"></a><a name="uppercase-opcode"></a>
538
 
<br><dt><code>uppercase character dots</code><dd>
 
586
     <p><a name="index-uppercase-13"></a><a name="uppercase-opcode"></a><br><dt><code>uppercase character dots</code><dd>
539
587
Associates a character with a dot pattern and defines the character as
540
588
an uppercase letter. Both the character and the dot pattern have the
541
589
attributes uppercase and letter. <code>lowercase</code> and <code>uppercase</code>
542
590
should be used when a letter has only one case. Otherwise use the
543
591
<code>uplow</code> opcode (see <a href="#uplow-opcode">uplow</a>).
544
592
 
545
 
     <p><a name="index-litdigit-13"></a><a name="litdigit-opcode"></a>
546
 
<br><dt><code>litdigit digit dots</code><dd>
 
593
     <p><a name="index-litdigit-14"></a><a name="litdigit-opcode"></a><br><dt><code>litdigit digit dots</code><dd>
547
594
Associates a digit with the dot pattern which should be used to
548
595
represent it in literary texts. For example:
549
596
 
550
597
     <pre class="example">          litdigit 0 245
551
598
          litdigit 1 1
552
 
     </pre>
553
 
     <p><a name="index-sign-14"></a><a name="sign-opcode"></a>
554
 
<br><dt><code>sign character dots</code><dd>
 
599
</pre>
 
600
     <p><a name="index-sign-15"></a><a name="sign-opcode"></a><br><dt><code>sign character dots</code><dd>
555
601
Associates a character with a dot pattern and defines both as a sign. 
556
 
This opcode should be used for things like at sign (`<samp><span class="samp">@</span></samp>'),
557
 
percent (`<samp><span class="samp">%</span></samp>'), dollar sign (`<samp><span class="samp">$</span></samp>'), etc. Do not use it to
 
602
This opcode should be used for things like at sign (&lsquo;<samp><span class="samp">@</span></samp>&rsquo;),
 
603
percent (&lsquo;<samp><span class="samp">%</span></samp>&rsquo;), dollar sign (&lsquo;<samp><span class="samp">$</span></samp>&rsquo;), etc. Do not use it to
558
604
define ordinary punctuation such as period and comma. For example:
559
605
 
560
606
     <pre class="example">          sign % 4-25-1234 literary percent sign
561
 
     </pre>
562
 
     <p><a name="index-math-15"></a><a name="math-opcode"></a>
563
 
<br><dt><code>math character dots</code><dd>
 
607
</pre>
 
608
     <p><a name="index-math-16"></a><a name="math-opcode"></a><br><dt><code>math character dots</code><dd>
564
609
Associates a character and a dot pattern and defines them as a
565
 
mathematical symbol. It should be used for less than (`<samp><span class="samp">&lt;</span></samp>'),
566
 
greater than(`<samp><span class="samp">&gt;</span></samp>'), equals(`<samp><span class="samp">=</span></samp>'), plus(`<samp><span class="samp">+</span></samp>'), etc. For
 
610
mathematical symbol. It should be used for less than (&lsquo;<samp><span class="samp">&lt;</span></samp>&rsquo;),
 
611
greater than(&lsquo;<samp><span class="samp">&gt;</span></samp>&rsquo;), equals(&lsquo;<samp><span class="samp">=</span></samp>&rsquo;), plus(&lsquo;<samp><span class="samp">+</span></samp>&rsquo;), etc. For
567
612
example:
568
613
 
569
614
     <pre class="example">          math + 346 plus
570
 
     </pre>
 
615
</pre>
571
616
     </dl>
572
617
 
573
618
<p><a name="Braille-Indicator-Opcodes"></a>
580
625
by a dot pattern, which may be one or more cells.
581
626
 
582
627
     
583
 
<a name="index-capsign-16"></a>
584
 
<dl><a name="capsign-opcode"></a>
585
 
<dt><code>capsign dots</code><dd>
 
628
<a name="index-capsign-17"></a>
 
629
<dl><a name="capsign-opcode"></a><dt><code>capsign dots</code><dd>
586
630
The dot pattern which indicates capitalization of a single letter. In
587
631
English, this is dot 6. For example:
588
632
 
589
633
     <pre class="example">          capsign 6
590
 
     </pre>
591
 
     <p><a name="index-begcaps-17"></a><a name="begcaps-opcode"></a>
592
 
<br><dt><code>begcaps dots</code><dd>
 
634
</pre>
 
635
     <p><a name="index-begcaps-18"></a><a name="begcaps-opcode"></a><br><dt><code>begcaps dots</code><dd>
593
636
The dot pattern which begins a block of capital letters. For example:
594
637
 
595
638
     <pre class="example">          begcaps 6-6
596
 
     </pre>
597
 
     <p><a name="index-endcaps-18"></a><a name="endcaps-opcode"></a>
598
 
<br><dt><code>endcaps dots</code><dd>
 
639
</pre>
 
640
     <p><a name="index-endcaps-19"></a><a name="endcaps-opcode"></a><br><dt><code>endcaps dots</code><dd>
599
641
The dot pattern which ends a block of capital letters within a word. 
600
642
For example:
601
643
 
602
644
     <pre class="example">          endcaps 6-3
603
 
     </pre>
604
 
     <p><a name="index-letsign-19"></a><a name="letsign-opcode"></a>
605
 
<br><dt><code>letsign dots</code><dd>
 
645
</pre>
 
646
     <p><a name="index-letsign-20"></a><a name="letsign-opcode"></a><br><dt><code>letsign dots</code><dd>
606
647
This indicator is needed in Grade 2 to show that a single letter is
607
648
not a contraction. It is also used when an abbreviation happens to be
608
649
a sequence of letters that is the same as a contraction. For example:
609
650
 
610
651
     <pre class="example">          letsign 56
611
 
     </pre>
612
 
     <p><a name="index-noletsign-20"></a><a name="noletsign-opcode"></a>
613
 
<br><dt><code>noletsign letters</code><dd>
 
652
</pre>
 
653
     <p><a name="index-noletsign-21"></a><a name="noletsign-opcode"></a><br><dt><code>noletsign letters</code><dd>
614
654
 
615
655
     <p>The letters in the operand will not be proceeded by a letter sign. 
616
656
More than one <code>noletsign</code> opcode can be used. This is equivalent
617
657
to a single entry containing all the letters. In addition, if a single
618
 
letter, such as `<samp><span class="samp">a</span></samp>' in English, is defined as a <code>word</code>
 
658
letter, such as &lsquo;<samp><span class="samp">a</span></samp>&rsquo; in English, is defined as a <code>word</code>
619
659
(see <a href="#word-opcode">word</a>) or <code>largesign</code>
620
660
(see <a href="#largesign-opcode">largesign</a>), it will be
621
661
treated as though it had also been specified in a <code>noletsign</code>
622
662
entry.
623
663
 
624
 
     <p><a name="index-noletsignbefore-21"></a><a name="noletsignbefore-opcode"></a>
625
 
<br><dt><code>noletsignbefore characters</code><dd>
 
664
     <p><a name="index-noletsignbefore-22"></a><a name="noletsignbefore-opcode"></a><br><dt><code>noletsignbefore characters</code><dd>
626
665
If any of the characters proceeds a single letter without a space a
627
666
letter sign is not used. By default the characters apostrophe
628
 
(`<samp><span class="samp">'</span></samp>') and period (`<samp><span class="samp">.</span></samp>') have this property. Use of a
 
667
(&lsquo;<samp><span class="samp">'</span></samp>&rsquo;) and period (&lsquo;<samp><span class="samp">.</span></samp>&rsquo;) have this property. Use of a
629
668
<code>noletsignbefore</code> entry cancels the defaults. If more than one
630
669
<code>noletsignbefore</code> entry is used, the characters in all entries
631
670
are combined.
632
671
 
633
 
     <p><a name="index-noletsignafter-22"></a><a name="noletsignafter-opcode"></a>
634
 
<br><dt><code>noletsignafter characters</code><dd>
 
672
     <p><a name="index-noletsignafter-23"></a><a name="noletsignafter-opcode"></a><br><dt><code>noletsignafter characters</code><dd>
635
673
If any of the characters follows a single letter without a space a
636
674
letter sign is not used. By default the characters apostrophe
637
 
(`<samp><span class="samp">'</span></samp>') and period (`<samp><span class="samp">.</span></samp>') have this property. Use of a
 
675
(&lsquo;<samp><span class="samp">'</span></samp>&rsquo;) and period (&lsquo;<samp><span class="samp">.</span></samp>&rsquo;) have this property. Use of a
638
676
<code>noletsignafter</code> entry cancels the defaults. If more than one
639
677
<code>noletsignafter</code> entry is used the characters in all entries are
640
678
combined.
641
679
 
642
 
     <p><a name="index-numsign-23"></a><a name="numsign-opcode"></a>
643
 
<br><dt><code>numsign dots</code><dd>
 
680
     <p><a name="index-numsign-24"></a><a name="numsign-opcode"></a><br><dt><code>numsign dots</code><dd>
644
681
The translator inserts this indicator before numbers made up of digits
645
682
defined with the <code>litdigit</code> opcode (see <a href="#litdigit-opcode">litdigit</a>) to show that they are a number
646
683
and not letters or some other symbols. For example:
647
684
 
648
685
     <pre class="example">          numsign 3456
649
 
     </pre>
 
686
</pre>
650
687
     </dl>
651
688
 
652
689
<p><a name="Emphasis-Opcodes"></a>
686
723
   <p>Here are the various emphasis opcodes.
687
724
 
688
725
     
689
 
<a name="index-firstwordital-24"></a>
690
 
<dl><a name="firstwordital-opcode"></a>
691
 
<dt><code>firstwordital dots</code><dd>
 
726
<a name="index-firstwordital-25"></a>
 
727
<dl><a name="firstwordital-opcode"></a><dt><code>firstwordital dots</code><dd>
692
728
This is the braille indicator to be placed before the first word of an
693
729
italicized phrase that is longer than the value given in the
694
730
<code>lenitalphrase</code> opcode (see <a href="#lenitalphrase-opcode">lenitalphrase</a>). For example:
695
731
 
696
732
     <pre class="example">          firstwordital 46-46 English indicator
697
 
     </pre>
698
 
     <p><a name="index-lastworditalbefore-25"></a><a name="index-italsign-26"></a><a name="lastworditalbefore-opcode"></a>
699
 
<a name="italsign-opcode"></a>
700
 
<br><dt><code>lastworditalbefore dots</code><dt><code>italsign dots</code><dd>
 
733
</pre>
 
734
     <p><a name="index-lastworditalbefore-26"></a><a name="index-italsign-27"></a><a name="lastworditalbefore-opcode"></a><a name="italsign-opcode"></a><br><dt><code>lastworditalbefore dots</code><dt><code>italsign dots</code><dd>
701
735
These two opcodes are synonyms. This is the braille indicator to be
702
736
placed before the last word of an italicized phrase. In addition, if
703
737
<code>firstwordital</code> is not used, this braille indicator is doubled
705
739
and <code>lastworditalafter</code> in the same table. For example:
706
740
 
707
741
     <pre class="example">          lastworditalbefore 4-6
708
 
     </pre>
709
 
     <p><a name="index-lastworditalafter-27"></a><a name="lastworditalafter-opcode"></a>
710
 
<br><dt><code>lastworditalafter dots</code><dd>
 
742
</pre>
 
743
     <p><a name="index-lastworditalafter-28"></a><a name="lastworditalafter-opcode"></a><br><dt><code>lastworditalafter dots</code><dd>
711
744
This is the braille indicator to be placed after the last word of an
712
745
italicized phrase. Do not use <code>lastworditalbefore</code> and
713
746
<code>lastworditalafter</code> in the same table. See also the
714
747
<code>lenitalphrase</code> opcode (see <a href="#lenitalphrase-opcode">lenitalphrase</a>) for more information.
715
748
 
716
 
     <p><a name="index-firstletterital-28"></a><a name="index-begital-29"></a><a name="firstletterital-opcode"></a>
717
 
<a name="begital-opcode"></a>
718
 
<br><dt><code>firstletterital dots</code><dt><code>begital dots</code><dd>
 
749
     <p><a name="index-firstletterital-29"></a><a name="index-begital-30"></a><a name="firstletterital-opcode"></a><a name="begital-opcode"></a><br><dt><code>firstletterital dots</code><dt><code>begital dots</code><dd>
719
750
These two opcodes are synonyms. This is the braille indicator to be
720
751
placed before the first letter (or character) if italicization begins
721
752
in the middle of a word.
722
753
 
723
 
     <p><a name="index-lastletterital-30"></a><a name="index-endital-31"></a><a name="lastletterital-opcode"></a>
724
 
<a name="endital-opcode"></a>
725
 
<br><dt><code>lastletterital dots</code><dt><code>endital dots</code><dd>
 
754
     <p><a name="index-lastletterital-31"></a><a name="index-endital-32"></a><a name="lastletterital-opcode"></a><a name="endital-opcode"></a><br><dt><code>lastletterital dots</code><dt><code>endital dots</code><dd>
726
755
These two opcodes are synonyms. This is the braille indicator to be
727
756
placed after the last letter (or character) when italicization ends in
728
757
the middle of a word.
729
758
 
730
 
     <p><a name="index-singleletterital-32"></a><a name="singleletterital-opcode"></a>
731
 
<br><dt><code>singleletterital dots</code><dd>
 
759
     <p><a name="index-singleletterital-33"></a><a name="singleletterital-opcode"></a><br><dt><code>singleletterital dots</code><dd>
732
760
This braille indicator is used if only a single letter (or character)
733
761
is italicized.
734
762
 
735
 
     <p><a name="index-lenitalphrase-33"></a><a name="lenitalphrase-opcode"></a>
736
 
<br><dt><code>lenitalphrase number</code><dd>
 
763
     <p><a name="index-lenitalphrase-34"></a><a name="lenitalphrase-opcode"></a><br><dt><code>lenitalphrase number</code><dd>
737
764
If <code>lastworditalbefore</code> is used, an italicized phrase is checked
738
765
to see how many words it contains. If this number is less than or
739
766
equal to the number given in the <code>lenitalphrase</code> opcode, the
745
772
<code>lastworditalbefore</code> entry. For example:
746
773
 
747
774
     <pre class="example">          lenitalphrase 4
748
 
     </pre>
749
 
     <p><a name="index-firstwordbold-34"></a><a name="firstwordbold-opcode"></a>
750
 
<br><dt><code>firstwordbold dots</code><dd>
 
775
</pre>
 
776
     <p><a name="index-firstwordbold-35"></a><a name="firstwordbold-opcode"></a><br><dt><code>firstwordbold dots</code><dd>
751
777
This is the braille indicator to be placed before the first word of a
752
778
bold phrase. For example:
753
779
 
754
780
     <pre class="example">          firstwordbold 456-456
755
 
     </pre>
756
 
     <p><a name="index-lastwordboldbefore-35"></a><a name="index-boldsign-36"></a><a name="lastwordboldbefore-opcode"></a>
757
 
<a name="boldsign-opcode"></a>
758
 
<br><dt><code>lastwordboldbefore dots</code><dt><code>boldsign dots</code><dd>
 
781
</pre>
 
782
     <p><a name="index-lastwordboldbefore-36"></a><a name="index-boldsign-37"></a><a name="lastwordboldbefore-opcode"></a><a name="boldsign-opcode"></a><br><dt><code>lastwordboldbefore dots</code><dt><code>boldsign dots</code><dd>
759
783
These two opcodes are synonyms. This is the braille indicator to be
760
784
placed before the last word of a bold phrase. In addition, if
761
785
<code>firstwordbold</code> is not used, this braille indicator is doubled
763
787
and <code>lastwordboldafter</code> in the same table. For example:
764
788
 
765
789
     <pre class="example">          lastwordboldbefore 456
766
 
     </pre>
767
 
     <p><a name="index-lastwordboldafter-37"></a><a name="lastwordboldafter-opcode"></a>
768
 
<br><dt><code>lastwordboldafter dots</code><dd>
 
790
</pre>
 
791
     <p><a name="index-lastwordboldafter-38"></a><a name="lastwordboldafter-opcode"></a><br><dt><code>lastwordboldafter dots</code><dd>
769
792
This is the braille indicator to be placed after the last word of a
770
793
bold phrase. Do not use <code>lastwordboldbefore</code> and
771
794
<code>lastwordboldafter</code> in the same table.
772
795
 
773
 
     <p><a name="index-firstletterbold-38"></a><a name="index-begbold-39"></a><a name="firstletterbold-opcode"></a>
774
 
<a name="begbold-opcode"></a>
775
 
<br><dt><code>firstletterbold dots</code><dt><code>begbold dots</code><dd>
 
796
     <p><a name="index-firstletterbold-39"></a><a name="index-begbold-40"></a><a name="firstletterbold-opcode"></a><a name="begbold-opcode"></a><br><dt><code>firstletterbold dots</code><dt><code>begbold dots</code><dd>
776
797
These two opcodes are synonyms. This is the braille indicator to be
777
798
placed before the first letter (or character) if bold emphasis begins
778
799
in the middle of a word.
779
800
 
780
 
     <p><a name="index-lastletterbold-40"></a><a name="index-endbold-41"></a><a name="lastletterbold-opcode"></a>
781
 
<a name="endbold-opcode"></a>
782
 
<br><dt><code>lastletterbold dots</code><dt><code>endbold dots</code><dd>
 
801
     <p><a name="index-lastletterbold-41"></a><a name="index-endbold-42"></a><a name="lastletterbold-opcode"></a><a name="endbold-opcode"></a><br><dt><code>lastletterbold dots</code><dt><code>endbold dots</code><dd>
783
802
These two opcodes are synonyms. This is the braille indicator to be
784
803
placed after the last letter (or character) when bold emphasis ends in
785
804
the middle of a word.
786
805
 
787
 
     <p><a name="index-singleletterbold-42"></a><a name="singleletterbold-opcode"></a>
788
 
<br><dt><code>singleletterbold dots</code><dd>
 
806
     <p><a name="index-singleletterbold-43"></a><a name="singleletterbold-opcode"></a><br><dt><code>singleletterbold dots</code><dd>
789
807
This braille indicator is used if only a single letter (or character)
790
808
is in boldface.
791
809
 
792
 
     <p><a name="index-lenboldphrase-43"></a><a name="lenboldphrase-opcode"></a>
793
 
<br><dt><code>lenboldphrase number</code><dd>
 
810
     <p><a name="index-lenboldphrase-44"></a><a name="lenboldphrase-opcode"></a><br><dt><code>lenboldphrase number</code><dd>
794
811
If <code>lastwordboldbefore</code> is used, a bold phrase is checked to see
795
812
how many words it contains. If this number is less than or equal to
796
813
the number given in the <code>lenboldphrase</code> opcode, the
801
818
used its indicator is made up by doubling the dot pattern given in the
802
819
<code>lastwordboldbefore</code> entry.
803
820
 
804
 
     <p><a name="index-firstwordunder-44"></a><a name="firstwordunder-opcode"></a>
805
 
<br><dt><code>firstwordunder dots</code><dd>
 
821
     <p><a name="index-firstwordunder-45"></a><a name="firstwordunder-opcode"></a><br><dt><code>firstwordunder dots</code><dd>
806
822
This is the braille indicator to be placed before the first word of an
807
823
underlined phrase.
808
824
 
809
 
     <p><a name="index-lastwordunderbefore-45"></a><a name="index-undersign-46"></a><a name="lastwordunderbefore-opcode"></a>
810
 
<a name="undersign-opcode"></a>
811
 
<br><dt><code>lastwordunderbefore dots</code><dt><code>undersign dots</code><dd>
 
825
     <p><a name="index-lastwordunderbefore-46"></a><a name="index-undersign-47"></a><a name="lastwordunderbefore-opcode"></a><a name="undersign-opcode"></a><br><dt><code>lastwordunderbefore dots</code><dt><code>undersign dots</code><dd>
812
826
These two opcodes are synonyms. This is the braille indicator to be
813
827
placed before the last word of an underlined phrase. In addition, if
814
828
<code>firstwordunder</code> is not used, this braille indicator is doubled
815
829
and placed before the first word.
816
830
 
817
 
     <p><a name="index-lastwordunderafter-47"></a><a name="lastwordunderafter-opcode"></a>
818
 
<br><dt><code>lastwordunderafter dots</code><dd>
 
831
     <p><a name="index-lastwordunderafter-48"></a><a name="lastwordunderafter-opcode"></a><br><dt><code>lastwordunderafter dots</code><dd>
819
832
This is the braille indicator to be placed after the last word of an
820
833
underlined phrase.
821
834
 
822
 
     <p><a name="index-firstletterunder-48"></a><a name="index-begunder-49"></a><a name="firstletterunder-opcode"></a>
823
 
<a name="begunder-opcode"></a>
824
 
<br><dt><code>firstletterunder dots</code><dt><code>begunder dots</code><dd>
 
835
     <p><a name="index-firstletterunder-49"></a><a name="index-begunder-50"></a><a name="firstletterunder-opcode"></a><a name="begunder-opcode"></a><br><dt><code>firstletterunder dots</code><dt><code>begunder dots</code><dd>
825
836
These two opcodes are synonyms. This is the braille indicator to be
826
837
placed before the first letter (or character) if underline emphasis
827
838
begins in the middle of a word.
828
839
 
829
 
     <p><a name="index-lastletterunder-50"></a><a name="index-endunder-51"></a><a name="lastletterunder-opcode"></a>
830
 
<a name="endunder-opcode"></a>
831
 
<br><dt><code>lastletterunder dots</code><dt><code>endunder dots</code><dd>
 
840
     <p><a name="index-lastletterunder-51"></a><a name="index-endunder-52"></a><a name="lastletterunder-opcode"></a><a name="endunder-opcode"></a><br><dt><code>lastletterunder dots</code><dt><code>endunder dots</code><dd>
832
841
These two opcodes are synonyms. This is the braille indicator to be
833
842
placed after the last letter (or character) when underline emphasis
834
843
ends in the middle of a word.
835
844
 
836
 
     <p><a name="index-singleletterunder-52"></a><a name="singleletterunder-opcode"></a>
837
 
<br><dt><code>singleletterunder dots</code><dd>
 
845
     <p><a name="index-singleletterunder-53"></a><a name="singleletterunder-opcode"></a><br><dt><code>singleletterunder dots</code><dd>
838
846
This braille indicator is used if only a single letter (or character)
839
847
is underlined.
840
848
 
841
 
     <p><a name="index-lenunderphrase-53"></a><a name="lenunderphrase-opcode"></a>
842
 
<br><dt><code>lenunderphrase number</code><dd>
 
849
     <p><a name="index-lenunderphrase-54"></a><a name="lenunderphrase-opcode"></a><br><dt><code>lenunderphrase number</code><dd>
843
850
If <code>lastwordunderbefore</code> is used, an underlined phrase is checked
844
851
to see how many words it contains. If this number is less than or
845
852
equal to the number given in the <code>lenunderphrase</code> opcode, the
850
857
not used its indicator is made up by doubling the dot pattern given in
851
858
the <code>lastwordunderbefore</code> entry.
852
859
 
853
 
     <p><a name="index-begcomp-54"></a><a name="begcomp-opcode"></a>
854
 
<br><dt><code>begcomp dots</code><dd>
 
860
     <p><a name="index-begcomp-55"></a><a name="begcomp-opcode"></a><br><dt><code>begcomp dots</code><dd>
855
861
This braille indicator is placed before a sequence of characters
856
862
translated in computer braille, whether this sequence is indicated in
857
863
the <code>typeform</code> parameter (see <a href="#Programming-with-liblouis">Programming with liblouis</a>) or
858
864
inferred because it contains a subsequence specified by the
859
865
<code>compbrl</code> opcode (see <a href="#compbrl-opcode">compbrl</a>).
860
866
 
861
 
     <p><a name="index-endcomp-55"></a><a name="endcomp-opcode"></a>
862
 
<br><dt><code>endcomp dots</code><dd>
 
867
     <p><a name="index-endcomp-56"></a><a name="endcomp-opcode"></a><br><dt><code>endcomp dots</code><dd>
863
868
This braille indicator is placed after a sequence of characters
864
869
translated in computer braille, whether this sequence is indicated in
865
870
the <code>typeform</code> parameter (see <a href="#Programming-with-liblouis">Programming with liblouis</a>) or
876
881
require special treatment.
877
882
 
878
883
     
879
 
<a name="index-decpoint-56"></a>
880
 
<dl><a name="decpoint-opcode"></a>
881
 
<dt><code>decpoint character dots</code><dd>
 
884
<a name="index-decpoint-57"></a>
 
885
<dl><a name="decpoint-opcode"></a><dt><code>decpoint character dots</code><dd>
882
886
This opcode defines the decimal point. The character operand must have
883
887
only one character. For example, in <samp><span class="file">en-us-g1.ctb</span></samp> we have:
884
888
 
885
889
     <pre class="example">          decpoint . 46
886
 
     </pre>
887
 
     <p><a name="index-hyphen-57"></a><a name="hyphen-opcode"></a>
888
 
<br><dt><code>hyphen character dots</code><dd>
 
890
</pre>
 
891
     <p><a name="index-hyphen-58"></a><a name="hyphen-opcode"></a><br><dt><code>hyphen character dots</code><dd>
889
892
This opcode defines the hyphen, that is, the character used in
890
893
compound words such as have-nots. The back-translator uses it to
891
894
determine the end of individual words.
899
902
<p>These opcodes cause special processing to be carried out.
900
903
 
901
904
     
902
 
<a name="index-capsnocont-58"></a>
903
 
<dl><a name="capsnocont-opcode"></a>
904
 
<dt><code>capsnocont</code><dd>
 
905
<a name="index-capsnocont-59"></a>
 
906
<dl><a name="capsnocont-opcode"></a><dt><code>capsnocont</code><dd>
905
907
This opcode has no operands. If it is specified words or parts of
906
908
words in all caps are not contracted. This is needed for languages
907
909
such as Norwegian.
931
933
   <p>The characters operand is a sequence or string of characters preceded
932
934
and followed by whitespace. Each character can be entered in the
933
935
normal way, or it can be defined as a four-digit hexadecimal number
934
 
preceded by `<samp><span class="samp">\x</span></samp>'.
 
936
preceded by &lsquo;<samp><span class="samp">\x</span></samp>&rsquo;.
935
937
 
936
938
   <p>The dots operand defines the braille representation for the characters
937
 
operand. It may also be specified as an equals sign (`<samp><span class="samp">=</span></samp>'). This
 
939
operand. It may also be specified as an equals sign (&lsquo;<samp><span class="samp">=</span></samp>&rsquo;). This
938
940
means that the the default representation for each character
939
941
(see <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a>) within the sequence is to be
940
942
used.
941
943
 
942
 
   <p>In what follows the word `<samp><span class="samp">characters</span></samp>' means a sequence of one or
 
944
   <p>In what follows the word &lsquo;<samp><span class="samp">characters</span></samp>&rsquo; means a sequence of one or
943
945
more consecutive letters between spaces and/or punctuation marks.
944
946
 
945
947
     
946
 
<a name="index-noback-59"></a>
947
 
<dl><a name="noback-opcode"></a>
948
 
<dt><code>noback opcode ...</code><dd>
 
948
<a name="index-noback-60"></a>
 
949
<dl><a name="noback-opcode"></a><dt><code>noback opcode ...</code><dd>
949
950
This is an opcode prefix, that is to say, it modifies the operation of
950
951
the opcode that follows it on the same line. noback specifies that no
951
952
back-translation is to be done using this line.
952
953
 
953
954
     <pre class="example">          noback always ;\s; 0
954
 
     </pre>
955
 
     <p><a name="index-nofor-60"></a><a name="nofor-opcode"></a>
956
 
<br><dt><code>nofor opcode ...</code><dd>
 
955
</pre>
 
956
     <p><a name="index-nofor-61"></a><a name="nofor-opcode"></a><br><dt><code>nofor opcode ...</code><dd>
957
957
This is an opcode prefix which modifies the opration of the opcode
958
958
following it on the same line. nofor specifies that forward translation
959
959
is not to use the information on this line.
960
960
 
961
 
     <p><a name="index-compbrl-61"></a><a name="index-literal-62"></a><a name="compbrl-opcode"></a>
962
 
<a name="literal-opcode"></a>
963
 
<br><dt><code>compbrl characters</code><dt><code>literal characters</code><dd>
 
961
     <p><a name="index-compbrl-62"></a><a name="index-literal-63"></a><a name="compbrl-opcode"></a><a name="literal-opcode"></a><br><dt><code>compbrl characters</code><dt><code>literal characters</code><dd>
964
962
These two opcodes are synonyms. If the characters are found within a
965
963
block of text surrounded by whitespace the entire block is translated
966
964
according to the default braille representations defined by the
969
967
<code>comp6</code> opcode (see <a href="#comp6-opcode">comp6</a>), if 6-dot computer braille is enabled. For example:
970
968
 
971
969
     <pre class="example">          compbrl www translate URLs in computer braille
972
 
     </pre>
973
 
     <p><a name="index-comp6-63"></a><a name="comp6-opcode"></a>
974
 
<br><dt><code>comp6 character dots</code><dd>
 
970
</pre>
 
971
     <p><a name="index-comp6-64"></a><a name="comp6-opcode"></a><br><dt><code>comp6 character dots</code><dd>
975
972
This opcode specifies the translation of characters in 6-dot computer
976
973
braille. It is necessary because the translation of a single character
977
974
may require more than one cell. The first operand must be a character
980
977
of a misnomer, since any dots, not just dots 1 through 6, can be
981
978
specified. This even includes virtual dots.
982
979
 
983
 
     <p><a name="index-nocont-64"></a><a name="nocont-opcode"></a>
984
 
<br><dt><code>nocont characters</code><dd>
 
980
     <p><a name="index-nocont-65"></a><a name="nocont-opcode"></a><br><dt><code>nocont characters</code><dd>
985
981
Like <code>compbrl</code>, except that the string is uncontracted. 
986
982
<code>prepunc</code> opcode (see <a href="#prepunc-opcode">prepunc</a>) and <code>postpunc</code> opcode (see <a href="#postpunc-opcode">postpunc</a>) rules are applied,
987
983
however. This is useful for specifying that foreign words should not
988
984
be contracted in an entire document.
989
985
 
990
 
     <p><a name="index-replace-65"></a><a name="replace-opcode"></a>
991
 
<br><dt><code>replace characters {characters}</code><dd>
 
986
     <p><a name="index-replace-66"></a><a name="replace-opcode"></a><br><dt><code>replace characters {characters}</code><dd>
992
987
Replace the first set of characters, no matter where they appear, with
993
988
the second. Note that the second operand is <em>NOT</em> a dot pattern. 
994
989
It is also optional. If it is omitted the character(s) in the first
997
992
translation indirectly. Therefore, it is preferable to use
998
993
<code>correct</code> opcode (see <a href="#correct-opcode">correct</a>).
999
994
 
1000
 
     <p><a name="index-always-66"></a><a name="always-opcode"></a>
1001
 
<br><dt><code>always characters dots</code><dd>
 
995
     <p><a name="index-always-67"></a><a name="always-opcode"></a><br><dt><code>always characters dots</code><dd>
1002
996
Replace the characters with the dot pattern no matter where they
1003
997
appear. Do <em>NOT</em> use an entry such as <code>always a 1</code>. Use the
1004
998
<code>uplow</code>, <code>letter</code>, etc. character definition opcodes
1005
999
instead. For example:
1006
1000
 
1007
1001
     <pre class="example">          always world 456-2456 unconditional translation
1008
 
     </pre>
1009
 
     <p><a name="index-repeated-67"></a><a name="repeated-opcode"></a>
1010
 
<br><dt><code>repeated characters dots</code><dd>
 
1002
</pre>
 
1003
     <p><a name="index-repeated-68"></a><a name="repeated-opcode"></a><br><dt><code>repeated characters dots</code><dd>
1011
1004
Replace the characters with the dot pattern no matter where they
1012
1005
appear. Ignore any consecutive repetitions of the same character
1013
1006
sequence. This is useful for shortening long strings of spaces or
1014
1007
hyphens or periods. For example:
1015
1008
 
1016
1009
     <pre class="example">          repeated --- 36-36-36 shorten separator lines made with hyphens
1017
 
     </pre>
1018
 
     <p><a name="index-repword-68"></a><a name="repword-opcode"></a>
1019
 
<br><dt><code>repword characters dots</code><dd>
 
1010
</pre>
 
1011
     <p><a name="index-repword-69"></a><a name="repword-opcode"></a><br><dt><code>repword characters dots</code><dd>
1020
1012
When characters are encountered check to see if the word before this
1021
1013
string matches the word after it. If so, replace characters with dots
1022
1014
and eliminate the second word and any word following another occurence
1024
1016
braille. In this case the rule is:
1025
1017
 
1026
1018
     <pre class="example">          repword - 123456
1027
 
     </pre>
1028
 
     <p><a name="index-largesign-69"></a><a name="largesign-opcode"></a>
1029
 
<br><dt><code>largesign characters dots</code><dd>
 
1019
</pre>
 
1020
     <p><a name="index-largesign-70"></a><a name="largesign-opcode"></a><br><dt><code>largesign characters dots</code><dd>
1030
1021
Replace the characters with the dot pattern no matter where they
1031
1022
appear. In addition, if two words defined as large signs follow each
1032
1023
other, remove the space between them. For example, in
1033
 
<samp><span class="file">en-us-g2.ctb</span></samp> the words `<samp><span class="samp">and</span></samp>' and `<samp><span class="samp">the</span></samp>' are both
1034
 
defined as large signs. Thus, in the phrase `<samp><span class="samp">the cat and the dog</span></samp>'
1035
 
the space would be deleted between `<samp><span class="samp">and</span></samp>' and `<samp><span class="samp">the</span></samp>', with the
1036
 
result `<samp><span class="samp">the cat andthe dog</span></samp>'. Of course, `<samp><span class="samp">and</span></samp>' and `<samp><span class="samp">the</span></samp>'
 
1024
<samp><span class="file">en-us-g2.ctb</span></samp> the words &lsquo;<samp><span class="samp">and</span></samp>&rsquo; and &lsquo;<samp><span class="samp">the</span></samp>&rsquo; are both
 
1025
defined as large signs. Thus, in the phrase &lsquo;<samp><span class="samp">the cat and the dog</span></samp>&rsquo;
 
1026
the space would be deleted between &lsquo;<samp><span class="samp">and</span></samp>&rsquo; and &lsquo;<samp><span class="samp">the</span></samp>&rsquo;, with the
 
1027
result &lsquo;<samp><span class="samp">the cat andthe dog</span></samp>&rsquo;. Of course, &lsquo;<samp><span class="samp">and</span></samp>&rsquo; and &lsquo;<samp><span class="samp">the</span></samp>&rsquo;
1037
1028
would be properly contracted. The term <code>largesign</code> is a bit of
1038
1029
braille jargon that pleases braille experts.
1039
1030
 
1040
 
     <p><a name="index-word-70"></a><a name="word-opcode"></a>
1041
 
<br><dt><code>word characters dots</code><dd>
 
1031
     <p><a name="index-word-71"></a><a name="word-opcode"></a><br><dt><code>word characters dots</code><dd>
1042
1032
Replace the characters with the dot pattern if they are a word, that
1043
1033
is, are surrounded by whitespace and/or punctuation.
1044
1034
 
1045
 
     <p><a name="index-syllable-71"></a><a name="syllable-opcode"></a>
1046
 
<br><dt><code>syllable characters dots</code><dd>
 
1035
     <p><a name="index-syllable-72"></a><a name="syllable-opcode"></a><br><dt><code>syllable characters dots</code><dd>
1047
1036
As its name indicates, this opcode defines a "syllable" which must be
1048
1037
represented by exactly the dot patterns given. Contractions may not
1049
1038
cross the boundaries of this "syllable" either from left or right. The
1053
1042
within the sequence is to be used (see <a href="#Translation-Opcodes">Translation Opcodes</a>):
1054
1043
 
1055
1044
     <pre class="example">          syllable horse = sawhorse, horseradish
1056
 
     </pre>
1057
 
     <p><a name="index-nocross-72"></a><a name="nocross-opcode"></a>
1058
 
<br><dt><code>nocross characters dots</code><dd>
 
1045
</pre>
 
1046
     <p><a name="index-nocross-73"></a><a name="nocross-opcode"></a><br><dt><code>nocross characters dots</code><dd>
1059
1047
Replace the characters with the dot pattern if the characters are all
1060
1048
in one syllable (do not cross a syllable boundary). For this opcode to
1061
1049
work, a hyphenation table must be included. If this is not done,
1062
1050
<code>nocross</code> behaves like the <code>always</code> opcode (see <a href="#always-opcode">always</a>). For example, if
1063
1051
the English Grade 2 table is being used and the appropriate
1064
1052
hyphenation table has been included <code>nocross sh 146</code> will cause
1065
 
the `<samp><span class="samp">sh</span></samp>' in `<samp><span class="samp">monkshood</span></samp>' not to be contracted.
 
1053
the &lsquo;<samp><span class="samp">sh</span></samp>&rsquo; in &lsquo;<samp><span class="samp">monkshood</span></samp>&rsquo; not to be contracted.
1066
1054
 
1067
 
     <p><a name="index-joinword-73"></a><a name="joinword-opcode"></a>
1068
 
<br><dt><code>joinword characters dots</code><dd>
 
1055
     <p><a name="index-joinword-74"></a><a name="joinword-opcode"></a><br><dt><code>joinword characters dots</code><dd>
1069
1056
Replace the characters with the dot pattern if they are a word which
1070
1057
is followed by whitespace and a letter. In addition remove the
1071
1058
whitespace. For example, <samp><span class="file">en-us-g2.ctb</span></samp> has <code>joinword to
1072
 
235</code>. This means that if the word `<samp><span class="samp">to</span></samp>' is followed by another
 
1059
235</code>. This means that if the word &lsquo;<samp><span class="samp">to</span></samp>&rsquo; is followed by another
1073
1060
word the contraction is to be used and the space is to be omitted. If
1074
1061
these conditions are not met, the word is translated according to any
1075
1062
other opcodes that may apply to it.
1076
1063
 
1077
 
     <p><a name="index-lowword-74"></a><a name="lowword-opcode"></a>
1078
 
<br><dt><code>lowword characters dots</code><dd>
 
1064
     <p><a name="index-lowword-75"></a><a name="lowword-opcode"></a><br><dt><code>lowword characters dots</code><dd>
1079
1065
Replace the characters with the dot pattern if they are a word
1080
1066
preceded and followed by whitespace. No punctuation either before or
1081
1067
after the word is allowed. The term <code>lowword</code> derives from the
1083
1069
of the cell. For example:
1084
1070
 
1085
1071
     <pre class="example">          lowword were 2356
1086
 
     </pre>
1087
 
     <p><a name="index-contraction-75"></a><a name="contraction-opcode"></a>
1088
 
<br><dt><code>contraction characters</code><dd>
 
1072
</pre>
 
1073
     <p><a name="index-contraction-76"></a><a name="contraction-opcode"></a><br><dt><code>contraction characters</code><dd>
1089
1074
If you look at <samp><span class="file">en-us-g2.ctb</span></samp> you will see that some words are
1090
1075
actually contracted into some of their own letters. A famous example
1091
 
among braille transcribers is `<samp><span class="samp">also</span></samp>', which is contracted as
1092
 
`<samp><span class="samp">al</span></samp>'. But this is also the name of a person. To take another
1093
 
example, `<samp><span class="samp">altogether</span></samp>' is contracted as `<samp><span class="samp">alt</span></samp>', but this is
 
1076
among braille transcribers is &lsquo;<samp><span class="samp">also</span></samp>&rsquo;, which is contracted as
 
1077
&lsquo;<samp><span class="samp">al</span></samp>&rsquo;. But this is also the name of a person. To take another
 
1078
example, &lsquo;<samp><span class="samp">altogether</span></samp>&rsquo; is contracted as &lsquo;<samp><span class="samp">alt</span></samp>&rsquo;, but this is
1094
1079
the abbreviation for the alternate key on a computer keyboard. 
1095
 
Similarly `<samp><span class="samp">could</span></samp>' is contracted into `<samp><span class="samp">cd</span></samp>', but this is the
 
1080
Similarly &lsquo;<samp><span class="samp">could</span></samp>&rsquo; is contracted into &lsquo;<samp><span class="samp">cd</span></samp>&rsquo;, but this is the
1096
1081
abbreviation for compact disk. To prevent confusion in such cases, the
1097
1082
letter sign (see <code>letsign</code> opcode (see <a href="#letsign-opcode">letsign</a>)) is placed before such letter
1098
1083
combinations when they actually are abbreviations, not contractions. 
1099
1084
The <code>contraction</code> opcode tells the translator to do this.
1100
1085
 
1101
 
     <p><a name="index-sufword-76"></a><a name="sufword-opcode"></a>
1102
 
<br><dt><code>sufword characters dots</code><dd>
 
1086
     <p><a name="index-sufword-77"></a><a name="sufword-opcode"></a><br><dt><code>sufword characters dots</code><dd>
1103
1087
Replace the characters with the dot pattern if they are either a word
1104
1088
or at the beginning of a word.
1105
1089
 
1106
 
     <p><a name="index-prfword-77"></a><a name="prfword-opcode"></a>
1107
 
<br><dt><code>prfword characters dots</code><dd>
 
1090
     <p><a name="index-prfword-78"></a><a name="prfword-opcode"></a><br><dt><code>prfword characters dots</code><dd>
1108
1091
Replace the characters with the dot pattern if they are either a word
1109
1092
or at the end of a word.
1110
1093
 
1111
 
     <p><a name="index-begword-78"></a><a name="begword-opcode"></a>
1112
 
<br><dt><code>begword characters dots</code><dd>
 
1094
     <p><a name="index-begword-79"></a><a name="begword-opcode"></a><br><dt><code>begword characters dots</code><dd>
1113
1095
Replace the characters with the dot pattern if they are at the
1114
1096
beginning of a word.
1115
1097
 
1116
 
     <p><a name="index-begmidword-79"></a><a name="begmidword-opcode"></a>
1117
 
<br><dt><code>begmidword characters dots</code><dd>
 
1098
     <p><a name="index-begmidword-80"></a><a name="begmidword-opcode"></a><br><dt><code>begmidword characters dots</code><dd>
1118
1099
Replace the characters with the dot pattern if they are either at the
1119
1100
beginning or in the middle of a word.
1120
1101
 
1121
 
     <p><a name="index-midword-80"></a><a name="midword-opcode"></a>
1122
 
<br><dt><code>midword characters dots</code><dd>
 
1102
     <p><a name="index-midword-81"></a><a name="midword-opcode"></a><br><dt><code>midword characters dots</code><dd>
1123
1103
Replace the characters with the dot pattern if they are in the middle
1124
1104
of a word.
1125
1105
 
1126
 
     <p><a name="index-midendword-81"></a><a name="midendword-opcode"></a>
1127
 
<br><dt><code>midendword characters dots</code><dd>
 
1106
     <p><a name="index-midendword-82"></a><a name="midendword-opcode"></a><br><dt><code>midendword characters dots</code><dd>
1128
1107
Replace the characters with the dot pattern if they are either in the
1129
1108
middle or at the end of a word.
1130
1109
 
1131
 
     <p><a name="index-endword-82"></a><a name="endword-opcode"></a>
1132
 
<br><dt><code>endword characters dots</code><dd>
 
1110
     <p><a name="index-endword-83"></a><a name="endword-opcode"></a><br><dt><code>endword characters dots</code><dd>
1133
1111
Replace the characters with the dot pattern if they are at the end of
1134
1112
a word.
1135
1113
 
1136
 
     <p><a name="index-partword-83"></a><a name="partword-opcode"></a>
1137
 
<br><dt><code>partword characters dots</code><dd>
 
1114
     <p><a name="index-partword-84"></a><a name="partword-opcode"></a><br><dt><code>partword characters dots</code><dd>
1138
1115
Replace the characters with the dot pattern if the characters are
1139
1116
anywhere in a word, that is, if they are proceeded or followed by a
1140
1117
letter.
1141
1118
 
1142
 
     <p><a name="index-exactdots-84"></a><a name="exactdots-opcode"></a>
1143
 
<br><dt><code>exactdots @dots</code><dd>
1144
 
Note that the operand must begin with an at sign (`<samp><span class="samp">@</span></samp>'). The dot
 
1119
     <p><a name="index-exactdots-85"></a><a name="exactdots-opcode"></a><br><dt><code>exactdots @dots</code><dd>
 
1120
Note that the operand must begin with an at sign (&lsquo;<samp><span class="samp">@</span></samp>&rsquo;). The dot
1145
1121
pattern following it is evaluated for validity. If it is valid,
1146
1122
whenever an at sign followed by this dot pattern appears in the source
1147
1123
document it is replaced by the characters corresponding to the dot
1150
1126
mathematical codes. For example:
1151
1127
 
1152
1128
     <pre class="example">          exactdots @4-46-12356
1153
 
     </pre>
 
1129
</pre>
1154
1130
     <p>will produce the characters with these dot patterns in the output.
1155
1131
 
1156
 
     <p><a name="index-prepunc-85"></a><a name="prepunc-opcode"></a>
1157
 
<br><dt><code>prepunc characters dots</code><dd>
 
1132
     <p><a name="index-prepunc-86"></a><a name="prepunc-opcode"></a><br><dt><code>prepunc characters dots</code><dd>
1158
1133
Replace the characters with the dot pattern if they are part of
1159
1134
punctuation at the beginning of a word.
1160
1135
 
1161
 
     <p><a name="index-postpunc-86"></a><a name="postpunc-opcode"></a>
1162
 
<br><dt><code>postpunc characters dots</code><dd>
 
1136
     <p><a name="index-postpunc-87"></a><a name="postpunc-opcode"></a><br><dt><code>postpunc characters dots</code><dd>
1163
1137
Replace the characters with the dot pattern if they are part of
1164
1138
punctuation at the end of a word.
1165
1139
 
1166
 
     <p><a name="index-begnum-87"></a><a name="begnum-opcode"></a>
1167
 
<br><dt><code>begnum characters dots</code><dd>
 
1140
     <p><a name="index-begnum-88"></a><a name="begnum-opcode"></a><br><dt><code>begnum characters dots</code><dd>
1168
1141
Replace the characters with the dot pattern if they are at the
1169
1142
beginning of a number, that is, before all its digits. For example, in
1170
1143
<samp><span class="file">en-us-g1.ctb</span></samp> we have <code>begnum # 4</code>.
1171
1144
 
1172
 
     <p><a name="index-midnum-88"></a><a name="midnum-opcode"></a>
1173
 
<br><dt><code>midnum characters dots</code><dd>
 
1145
     <p><a name="index-midnum-89"></a><a name="midnum-opcode"></a><br><dt><code>midnum characters dots</code><dd>
1174
1146
Replace the characters with the dot pattern if they are in the middle
1175
1147
of a number. For example, <samp><span class="file">en-us-g1.ctb</span></samp> has <code>midnum . 46</code>. 
1176
1148
This is because the decimal point has a different dot pattern than the
1177
1149
period.
1178
1150
 
1179
 
     <p><a name="index-endnum-89"></a><a name="endnum-opcode"></a>
1180
 
<br><dt><code>endnum characters dots</code><dd>
 
1151
     <p><a name="index-endnum-90"></a><a name="endnum-opcode"></a><br><dt><code>endnum characters dots</code><dd>
1181
1152
Replace the characters with the dot pattern if they are at the end of
1182
1153
a number. For example <samp><span class="file">en-us-g1.ctb</span></samp> has <code>endnum th 1456</code>. 
1183
 
This handles things like `<samp><span class="samp">4th</span></samp>'. A letter sign is <em>NOT</em>
 
1154
This handles things like &lsquo;<samp><span class="samp">4th</span></samp>&rsquo;. A letter sign is <em>NOT</em>
1184
1155
inserted.
1185
1156
 
1186
 
     <p><a name="index-joinnum-90"></a><a name="joinnum-opcode"></a>
1187
 
<br><dt><code>joinnum characters dots</code><dd>
 
1157
     <p><a name="index-joinnum-91"></a><a name="joinnum-opcode"></a><br><dt><code>joinnum characters dots</code><dd>
1188
1158
Replace the characters with the dot pattern. In addition, if
1189
1159
whitespace and a number follows omit the whitespace.
1190
1160
 
1212
1182
<br><dt><code>lowercase</code><dd>Lowercase alphabetic characters
1213
1183
<br><dt><code>uppercase</code><dd>Uppercase alphabetic characters
1214
1184
<br><dt><code>punctuation</code><dd>Punctuation marks
1215
 
<br><dt><code>sign</code><dd>Signs such as percent (`<samp><span class="samp">%</span></samp>')
 
1185
<br><dt><code>sign</code><dd>Signs such as percent (&lsquo;<samp><span class="samp">%</span></samp>&rsquo;)
1216
1186
<br><dt><code>math</code><dd>Mathematical symbols
1217
1187
<br><dt><code>litdigit</code><dd>Literary digit
1218
1188
<br><dt><code>undefined</code><dd>Not properly defined
1223
1193
For examples see <samp><span class="file">fr-abrege.ctb</span></samp>.
1224
1194
 
1225
1195
     
1226
 
<a name="index-class-91"></a>
1227
 
<dl><a name="class-opcode"></a>
1228
 
<dt><code>class name characters</code><dd>
 
1196
<a name="index-class-92"></a>
 
1197
<dl><a name="class-opcode"></a><dt><code>class name characters</code><dd>
1229
1198
Define a new character class. The characters operand must be specified
1230
1199
as a string. A character class may not be used until it has been
1231
1200
defined.
1232
1201
 
1233
 
     <p><a name="index-after-92"></a><a name="after-opcode"></a>
1234
 
<br><dt><code>after class opcode ...</code><dd>
 
1202
     <p><a name="index-after-93"></a><a name="after-opcode"></a><br><dt><code>after class opcode ...</code><dd>
1235
1203
The specified opcode is further constrained in that the matched
1236
1204
character sequence must be immediately preceded by a character
1237
1205
belonging to the specified class. If this opcode is used more than
1238
1206
once on the same line then the union of the characters in all the
1239
1207
classes is used.
1240
1208
 
1241
 
     <p><a name="index-before-93"></a><a name="before-opcode"></a>
1242
 
<br><dt><code>before class opcode ...</code><dd>
 
1209
     <p><a name="index-before-94"></a><a name="before-opcode"></a><br><dt><code>before class opcode ...</code><dd>
1243
1210
The specified opcode is further constrained in that the matched
1244
1211
character sequence must be immediately followed by a character
1245
1212
belonging to the specified class. If this opcode is used more than
1262
1229
are separated by commas and may contain more than one cell.
1263
1230
 
1264
1231
     
1265
 
<a name="index-swapcd-94"></a>
1266
 
<dl><a name="swapcd-opcode"></a>
1267
 
<dt><code>swapcd name characters dots, dots, dots, ...</code><dd>
 
1232
<a name="index-swapcd-95"></a>
 
1233
<dl><a name="swapcd-opcode"></a><dt><code>swapcd name characters dots, dots, dots, ...</code><dd>
1268
1234
See above paragraph for explanation. For example:
1269
1235
 
1270
1236
     <pre class="example">          swapcd dropped 0123456789 356,2,23,...
1271
 
     </pre>
1272
 
     <p><a name="index-swapdd-95"></a><a name="swapdd-opcode"></a>
1273
 
<br><dt><code>swapdd name dots, dots, dots ... dotpattern1, dotpattern2, dotpattern3, ...</code><dd>
 
1237
</pre>
 
1238
     <p><a name="index-swapdd-96"></a><a name="swapdd-opcode"></a><br><dt><code>swapdd name dots, dots, dots ... dotpattern1, dotpattern2, dotpattern3, ...</code><dd>
1274
1239
The <code>swapdd</code> opcode defines substitutions for the multipass
1275
1240
opcodes. In the second operand the dot patterns must be single cells,
1276
1241
but in the third operand multi-cell dot patterns are allowed. This is
1277
1242
because multi-cell patterns in the second operand would lead to
1278
1243
ambiguities.
1279
1244
 
1280
 
     <p><a name="index-swapcc-96"></a><a name="swapcc-opcode"></a>
1281
 
<br><dt><code>swapcc name characters characters</code><dd>
 
1245
     <p><a name="index-swapcc-97"></a><a name="swapcc-opcode"></a><br><dt><code>swapcc name characters characters</code><dd>
1282
1246
The <code>swapcc</code> opcode swaps characters in its second operand for
1283
1247
characters in the corresponding places in its third operand. It is
1284
1248
intended for use with <code>correct</code> opcodes and can solve problems
1291
1255
<h3 class="section">3.10 The Context and Multipass Opcodes</h3>
1292
1256
 
1293
1257
     <dl>
1294
 
<a name="context-opcode"></a>
1295
 
<a name="index-context-97"></a><a name="index-pass2-98"></a><a name="index-pass3-99"></a><a name="index-pass4-100"></a><dt><code>context test action</code><dt><code>pass2 test action</code><dt><code>pass3 test action</code><dt><code>pass4 test action</code><dd>
 
1258
<a name="context-opcode"></a><a name="index-context-98"></a><a name="index-pass2-99"></a><a name="index-pass3-100"></a><a name="index-pass4-101"></a><dt><code>context test action</code><dt><code>pass2 test action</code><dt><code>pass3 test action</code><dt><code>pass4 test action</code><dd>
1296
1259
The <code>context</code> and multipass opcodes (<code>pass2</code>, <code>pass3</code>
1297
1260
and <code>pass4</code>) provide translation capabilities beyond those of the
1298
1261
basic translation opcodes (see <a href="#Translation-Opcodes">Translation Opcodes</a>) discussed
1305
1268
format of all these opcodes is:
1306
1269
 
1307
1270
     <pre class="example">          opcode test action
1308
 
     </pre>
 
1271
</pre>
1309
1272
     <p>The <code>test</code> and <code>action</code> operands have suboperands. Each
1310
1273
suboperand begins with a non-alphanumeric character and ends when
1311
1274
another non-alphanumeric character is encountered. The suboperands and
1315
1278
<dt><kbd>" (double quote)</kbd><dd>a string of characters. This string must be terminated by another
1316
1279
double quote. It may contain any characters. If a double quote is
1317
1280
needed within the string, it must be preceded by a backslash
1318
 
(`<samp><span class="samp">\</span></samp>'). If a space is needed, it must be represented by the escape
 
1281
(&lsquo;<samp><span class="samp">\</span></samp>&rsquo;). If a space is needed, it must be represented by the escape
1319
1282
sequence \s. This suboperand is valid only in the test part of the
1320
1283
<code>context</code> opcode.
1321
1284
 
1323
1286
This suboperand is not valid in the test part of the context and
1324
1287
correct opcodes.
1325
1288
 
1326
 
          <br><dt><kbd>$ (dollar sign)</kbd><dd>a string of attributes, such as `<samp><span class="samp">d</span></samp>' for digit, `<samp><span class="samp">l</span></samp>' for
 
1289
          <br><dt><kbd>$ (dollar sign)</kbd><dd>a string of attributes, such as &lsquo;<samp><span class="samp">d</span></samp>&rsquo; for digit, &lsquo;<samp><span class="samp">l</span></samp>&rsquo; for
1327
1290
letter, etc. More than one attribute can be given. If you wish to
1328
 
check characters with any attribute, use the letter `<samp><span class="samp">a</span></samp>'. Input
 
1291
check characters with any attribute, use the letter &lsquo;<samp><span class="samp">a</span></samp>&rsquo;. Input
1329
1292
characters are checked to see if they have at least one of the
1330
1293
attributes. The attribute string can be followed by numbers specifying
1331
1294
how many characters are to be checked. If no numbers are given, 1 is
1417
1380
<h3 class="section">3.11 The correct Opcode</h3>
1418
1381
 
1419
1382
     
1420
 
<a name="index-correct-101"></a>
1421
 
<dl><a name="correct-opcode"></a>
1422
 
<dt><code>correct test action</code><dd>
 
1383
<a name="index-correct-102"></a>
 
1384
<dl><a name="correct-opcode"></a><dt><code>correct test action</code><dd>
1423
1385
Because some input (such as that from an OCR program) may contain
1424
1386
systematic errors, it is sometimes advantageous to use a
1425
1387
pre-translation pass to remove them. The errors and their corrections
1437
1399
          correct "*" ? Get rid of stray asterisks
1438
1400
          correct "|" ? ditto for vertical bars
1439
1401
          correct "\s?" "?" drop space before question mark
1440
 
     </pre>
 
1402
</pre>
1441
1403
     <p>Note that if the <code>correct</code> opcode is used and the
1442
1404
<code>pass1Only</code> mode bit (see <a href="#lou_005ftranslateString">lou_translateString</a>) is not set
1443
1405
input and output positions may be incorrect.
1449
1411
<h3 class="section">3.12 Miscellaneous Opcodes</h3>
1450
1412
 
1451
1413
     
1452
 
<a name="index-include-102"></a>
1453
 
<dl><a name="include-opcode"></a>
1454
 
<dt><code>include filename</code><dd>
 
1414
<a name="index-include-103"></a>
 
1415
<dl><a name="include-opcode"></a><dt><code>include filename</code><dd>
1455
1416
Read the file indicated by <code>filename</code> and incorporate or include
1456
1417
its entries into the table. Included files can include other files,
1457
1418
which can include other files, etc. For an example, see what files are
1459
1420
<samp><span class="file">en-us-g2.ctb</span></samp>. If the included file is not in the same directory
1460
1421
as the main table, use a full pathname for filename.
1461
1422
 
1462
 
     <p><a name="index-locale-103"></a><a name="locale-opcode"></a>
1463
 
<br><dt><code>locale characters</code><dd>
 
1423
     <p><a name="index-locale-104"></a><a name="locale-opcode"></a><br><dt><code>locale characters</code><dd>
1464
1424
Not implemented, but recognized and ignored for backward
1465
1425
compatibility.
1466
1426
 
1467
 
     <p><a name="index-display-104"></a><a name="display-opcode"></a>
1468
 
<br><dt><code>display character dots</code><dd>
 
1427
     <p><a name="index-display-105"></a><a name="display-opcode"></a><br><dt><code>display character dots</code><dd>
1469
1428
Associates dot patterns with the characters which will be sent to a
1470
1429
braille embosser, display or screen font. The character must be in the
1471
1430
range 0-255 and the dots must specify a single cell. Here are some
1473
1432
 
1474
1433
     <pre class="example">          display a 1 When the character a is sent to the embosser or display,
1475
1434
          it # will produce a dot 1.
1476
 
     </pre>
 
1435
</pre>
1477
1436
     <pre class="example">          display L 123 When the character L is sent to the display or embosser
1478
1437
          # produces dots 1-2-3.
1479
 
     </pre>
 
1438
</pre>
1480
1439
     <p>The display opcode is optional. It is used when the embosser or
1481
1440
display has a different mapping of characters to dot patterns than
1482
1441
that given in <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a>. If used, display
1483
1442
entries must proceed character-definition entries.
1484
1443
 
1485
 
     <p><a name="index-multind-105"></a><a name="multind-opcode"></a>
1486
 
<br><dt><code>multind dots opcode opcode ...</code><dd>
 
1444
     <p><a name="index-multind-106"></a><a name="multind-opcode"></a><br><dt><code>multind dots opcode opcode ...</code><dd>
1487
1445
the multind opcode tells the back-translator that a sequence of
1488
1446
braille cells represents more than one braille indicator. For example,
1489
1447
in <samp><span class="file">en-us-g1.ctb</span></samp> we have <code>multind 56-6 letsign capsign</code>. 
1605
1563
 
1606
1564
<p>The data structure <code>TranslationTableHeader</code> is defined by a
1607
1565
<code>typedef</code> statement in <samp><span class="file">louis.h</span></samp>. To find the beginning,
1608
 
search for the word `<samp><span class="samp">header</span></samp>'. As its name implies, this is
 
1566
search for the word &lsquo;<samp><span class="samp">header</span></samp>&rsquo;. As its name implies, this is
1609
1567
actually the table header. Data are placed in the <code>ruleArea</code>
1610
1568
array, which is the last item defined in this structure. This array is
1611
1569
declared with a length of 1 and is expanded as needed. The table
1650
1608
 
1651
1609
   <p>Next is an array of size 256 which maps characters in this range to
1652
1610
dot patterns which may consist of multiple cells. It is used, for
1653
 
example, to map `<samp><span class="samp">{</span></samp>' to dots 456-246. These mappings are created
 
1611
example, to map &lsquo;<samp><span class="samp">{</span></samp>&rsquo; to dots 456-246. These mappings are created
1654
1612
<!-- FIXME: the compdots opcode should be documented -->
1655
1613
<!-- by the @opcoderef{compdots} -->
1656
1614
by the <code>compdots</code>
1674
1632
 
1675
1633
<h3 class="section">5.4 lou_version</h3>
1676
1634
 
1677
 
<p><a name="index-lou_005fversion-106"></a>
 
1635
<p><a name="index-lou_005fversion-107"></a>
1678
1636
<pre class="example">     char *lou_version ()
1679
1637
</pre>
1680
1638
   <p>This function returns a pointer to a character string containing the
1686
1644
 
1687
1645
<h3 class="section">5.5 lou_translateString</h3>
1688
1646
 
1689
 
<p><a name="index-lou_005ftranslateString-107"></a>
 
1647
<p><a name="index-lou_005ftranslateString-108"></a>
1690
1648
<pre class="example">     int lou_translateString (
1691
1649
         const char *const trantab,
1692
1650
         const widechar *const inbuf,
1705
1663
is indicated by the character-definition and display opcodes in the
1706
1664
translation table.
1707
1665
 
1708
 
   <p><a name="translation_002dtables"></a>
1709
 
The <code>trantab</code> parameter points to a list of translation tables
 
1666
   <p><a name="translation_002dtables"></a>The <code>trantab</code> parameter points to a list of translation tables
1710
1667
separated by commas. If only one table is given, no comma should be
1711
1668
used after it. It is these tables which control just how the
1712
1669
translation is made, whether in Grade 2, Grade 1, or something else. 
1764
1721
 
1765
1722
<h3 class="section">5.6 lou_translate</h3>
1766
1723
 
1767
 
<p><a name="index-lou_005ftranslate-108"></a>
 
1724
<p><a name="index-lou_005ftranslate-109"></a>
1768
1725
<pre class="example">     int lou_translate (
1769
1726
         const char *const trantab,
1770
1727
         const widechar * const inbuf,
1801
1758
 
1802
1759
<h3 class="section">5.7 lou_backTranslateString</h3>
1803
1760
 
1804
 
<p><a name="index-lou_005fbackTranslateString-109"></a>
 
1761
<p><a name="index-lou_005fbackTranslateString-110"></a>
1805
1762
<pre class="example">     int lou_backTranslateString (
1806
1763
         const char *const trantab,
1807
1764
         const widechar *const inbuf,
1827
1784
 
1828
1785
<h3 class="section">5.8 lou_backTranslate</h3>
1829
1786
 
1830
 
<p><a name="index-lou_005fbackTranslate-110"></a>
 
1787
<p><a name="index-lou_005fbackTranslate-111"></a>
1831
1788
<pre class="example">     int lou_backTranslate (
1832
1789
         const char *const trantab,
1833
1790
         const widechar *const inbufx,
1848
1805
 
1849
1806
<h3 class="section">5.9 lou_hyphenate</h3>
1850
1807
 
1851
 
<p><a name="index-lou_005fhyphenate-111"></a>
 
1808
<p><a name="index-lou_005fhyphenate-112"></a>
1852
1809
<pre class="example">     int lou_hyphenate (
1853
1810
         const char *const trantab,
1854
1811
         const widechar * const inbuf,
1882
1839
 
1883
1840
<h3 class="section">5.10 lou_logFile</h3>
1884
1841
 
1885
 
<p><a name="index-lou_005flogFile-112"></a>
 
1842
<p><a name="index-lou_005flogFile-113"></a>
1886
1843
<pre class="example">     void lou_logFile (char *fileName);
1887
1844
</pre>
1888
1845
   <p>This function is used when it is not convenient either to let messages
1896
1853
 
1897
1854
<h3 class="section">5.11 lou_logPrint</h3>
1898
1855
 
1899
 
<p><a name="index-lou_005flogPrint-113"></a>
 
1856
<p><a name="index-lou_005flogPrint-114"></a>
1900
1857
<pre class="example">     void lou_logPrint (char *format, ...);
1901
1858
</pre>
1902
1859
   <p>This function is called like <code>fprint</code>. It can be used by other
1909
1866
 
1910
1867
<h3 class="section">5.12 lou_getTable</h3>
1911
1868
 
1912
 
<p><a name="index-lou_005fgetTable-114"></a>
 
1869
<p><a name="index-lou_005fgetTable-115"></a>
1913
1870
<pre class="example">     void *lou_getTable (char *tablelist);
1914
1871
</pre>
1915
1872
   <p><code>tablelist</code> is a list of names of table files separated by
1925
1882
 
1926
1883
<h3 class="section">5.13 lou_readCharFromFile</h3>
1927
1884
 
1928
 
<p><a name="index-lou_005freadCharFromFile-115"></a>
 
1885
<p><a name="index-lou_005freadCharFromFile-116"></a>
1929
1886
<pre class="example">     int lou_readCharFromFile (const char *fileName, int *mode);
1930
1887
</pre>
1931
1888
   <p>This function is provided for situations where it is necessary to read
1942
1899
 
1943
1900
<h3 class="section">5.14 lou_free</h3>
1944
1901
 
1945
 
<p><a name="index-lou_005ffree-116"></a>
 
1902
<p><a name="index-lou_005ffree-117"></a>
1946
1903
<pre class="example">     void lou_free ();
1947
1904
</pre>
1948
1905
   <p>This function should be called at the end of the application to free
1965
1922
<h2 class="unnumbered">Opcode Index</h2>
1966
1923
 
1967
1924
<ul class="index-opcode" compact>
1968
 
<li><a href="#index-after-92">after</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
1969
 
<li><a href="#index-always-66">always</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1970
 
<li><a href="#index-before-93">before</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
1971
 
<li><a href="#index-begbold-39">begbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1972
 
<li><a href="#index-begcaps-17">begcaps</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
1973
 
<li><a href="#index-begcomp-54">begcomp</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1974
 
<li><a href="#index-begital-29">begital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1975
 
<li><a href="#index-begmidword-79">begmidword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1976
 
<li><a href="#index-begnum-87">begnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1977
 
<li><a href="#index-begunder-49">begunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1978
 
<li><a href="#index-begword-78">begword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1979
 
<li><a href="#index-boldsign-36">boldsign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1980
 
<li><a href="#index-capsign-16">capsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
1981
 
<li><a href="#index-capsnocont-58">capsnocont</a>: <a href="#Special-Processing-Opcodes">Special Processing Opcodes</a></li>
1982
 
<li><a href="#index-class-91">class</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
1983
 
<li><a href="#index-comp6-63">comp6</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1984
 
<li><a href="#index-compbrl-61">compbrl</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1985
 
<li><a href="#index-context-97">context</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
1986
 
<li><a href="#index-contraction-75">contraction</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1987
 
<li><a href="#index-correct-101">correct</a>: <a href="#The-correct-Opcode">The correct Opcode</a></li>
1988
 
<li><a href="#index-decpoint-56">decpoint</a>: <a href="#Special-Symbol-Opcodes">Special Symbol Opcodes</a></li>
1989
 
<li><a href="#index-digit-7">digit</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
1990
 
<li><a href="#index-display-104">display</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
1991
 
<li><a href="#index-endbold-41">endbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1992
 
<li><a href="#index-endcaps-18">endcaps</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
1993
 
<li><a href="#index-endcomp-55">endcomp</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1994
 
<li><a href="#index-endital-31">endital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1995
 
<li><a href="#index-endnum-89">endnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1996
 
<li><a href="#index-endunder-51">endunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
1997
 
<li><a href="#index-endword-82">endword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1998
 
<li><a href="#index-exactdots-84">exactdots</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
1999
 
<li><a href="#index-firstletterbold-38">firstletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2000
 
<li><a href="#index-firstletterital-28">firstletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2001
 
<li><a href="#index-firstletterunder-48">firstletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2002
 
<li><a href="#index-firstwordbold-34">firstwordbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2003
 
<li><a href="#index-firstwordital-24">firstwordital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2004
 
<li><a href="#index-firstwordunder-44">firstwordunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2005
 
<li><a href="#index-grouping-9">grouping</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2006
 
<li><a href="#index-hyphen-57">hyphen</a>: <a href="#Special-Symbol-Opcodes">Special Symbol Opcodes</a></li>
2007
 
<li><a href="#index-include-102">include</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
2008
 
<li><a href="#index-italsign-26">italsign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2009
 
<li><a href="#index-joinnum-90">joinnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2010
 
<li><a href="#index-joinword-73">joinword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2011
 
<li><a href="#index-largesign-69">largesign</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2012
 
<li><a href="#index-lastletterbold-40">lastletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2013
 
<li><a href="#index-lastletterital-30">lastletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2014
 
<li><a href="#index-lastletterunder-50">lastletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2015
 
<li><a href="#index-lastwordboldafter-37">lastwordboldafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2016
 
<li><a href="#index-lastwordboldbefore-35">lastwordboldbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2017
 
<li><a href="#index-lastworditalafter-27">lastworditalafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2018
 
<li><a href="#index-lastworditalbefore-25">lastworditalbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2019
 
<li><a href="#index-lastwordunderafter-47">lastwordunderafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2020
 
<li><a href="#index-lastwordunderbefore-45">lastwordunderbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2021
 
<li><a href="#index-lenboldphrase-43">lenboldphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2022
 
<li><a href="#index-lenitalphrase-33">lenitalphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2023
 
<li><a href="#index-lenunderphrase-53">lenunderphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2024
 
<li><a href="#index-letsign-19">letsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
2025
 
<li><a href="#index-letter-10">letter</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2026
 
<li><a href="#index-litdigit-13">litdigit</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2027
 
<li><a href="#index-literal-62">literal</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2028
 
<li><a href="#index-locale-103">locale</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
2029
 
<li><a href="#index-lowercase-11">lowercase</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2030
 
<li><a href="#index-lowword-74">lowword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2031
 
<li><a href="#index-math-15">math</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2032
 
<li><a href="#index-midendword-81">midendword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2033
 
<li><a href="#index-midnum-88">midnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2034
 
<li><a href="#index-midword-80">midword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2035
 
<li><a href="#index-multind-105">multind</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
2036
 
<li><a href="#index-noback-59">noback</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2037
 
<li><a href="#index-nocont-64">nocont</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2038
 
<li><a href="#index-nocross-72">nocross</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2039
 
<li><a href="#index-nofor-60">nofor</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2040
 
<li><a href="#index-noletsign-20">noletsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
2041
 
<li><a href="#index-noletsignafter-22">noletsignafter</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
2042
 
<li><a href="#index-noletsignbefore-21">noletsignbefore</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
2043
 
<li><a href="#index-numsign-23">numsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
2044
 
<li><a href="#index-partword-83">partword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2045
 
<li><a href="#index-pass2-98">pass2</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
2046
 
<li><a href="#index-pass3-99">pass3</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
2047
 
<li><a href="#index-pass4-100">pass4</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
2048
 
<li><a href="#index-postpunc-86">postpunc</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2049
 
<li><a href="#index-prepunc-85">prepunc</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2050
 
<li><a href="#index-prfword-77">prfword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2051
 
<li><a href="#index-punctuation-6">punctuation</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2052
 
<li><a href="#index-repeated-67">repeated</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2053
 
<li><a href="#index-replace-65">replace</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2054
 
<li><a href="#index-repword-68">repword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2055
 
<li><a href="#index-sign-14">sign</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2056
 
<li><a href="#index-singleletterbold-42">singleletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2057
 
<li><a href="#index-singleletterital-32">singleletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2058
 
<li><a href="#index-singleletterunder-52">singleletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2059
 
<li><a href="#index-space-5">space</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2060
 
<li><a href="#index-sufword-76">sufword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2061
 
<li><a href="#index-swapcc-96">swapcc</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
2062
 
<li><a href="#index-swapcd-94">swapcd</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
2063
 
<li><a href="#index-swapdd-95">swapdd</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
2064
 
<li><a href="#index-syllable-71">syllable</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2065
 
<li><a href="#index-undersign-46">undersign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
2066
 
<li><a href="#index-uplow-8">uplow</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2067
 
<li><a href="#index-uppercase-12">uppercase</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
2068
 
<li><a href="#index-word-70">word</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1925
<li><a href="#index-after-93">after</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
 
1926
<li><a href="#index-always-67">always</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1927
<li><a href="#index-before-94">before</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
 
1928
<li><a href="#index-begbold-40">begbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1929
<li><a href="#index-begcaps-18">begcaps</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1930
<li><a href="#index-begcomp-55">begcomp</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1931
<li><a href="#index-begital-30">begital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1932
<li><a href="#index-begmidword-80">begmidword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1933
<li><a href="#index-begnum-88">begnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1934
<li><a href="#index-begunder-50">begunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1935
<li><a href="#index-begword-79">begword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1936
<li><a href="#index-boldsign-37">boldsign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1937
<li><a href="#index-capsign-17">capsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1938
<li><a href="#index-capsnocont-59">capsnocont</a>: <a href="#Special-Processing-Opcodes">Special Processing Opcodes</a></li>
 
1939
<li><a href="#index-class-92">class</a>: <a href="#Character_002dClass-Opcodes">Character-Class Opcodes</a></li>
 
1940
<li><a href="#index-comp6-64">comp6</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1941
<li><a href="#index-compbrl-62">compbrl</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1942
<li><a href="#index-context-98">context</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
 
1943
<li><a href="#index-contraction-76">contraction</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1944
<li><a href="#index-correct-102">correct</a>: <a href="#The-correct-Opcode">The correct Opcode</a></li>
 
1945
<li><a href="#index-decpoint-57">decpoint</a>: <a href="#Special-Symbol-Opcodes">Special Symbol Opcodes</a></li>
 
1946
<li><a href="#index-digit-8">digit</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1947
<li><a href="#index-display-105">display</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
 
1948
<li><a href="#index-endbold-42">endbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1949
<li><a href="#index-endcaps-19">endcaps</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1950
<li><a href="#index-endcomp-56">endcomp</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1951
<li><a href="#index-endital-32">endital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1952
<li><a href="#index-endnum-90">endnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1953
<li><a href="#index-endunder-52">endunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1954
<li><a href="#index-endword-83">endword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1955
<li><a href="#index-exactdots-85">exactdots</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1956
<li><a href="#index-firstletterbold-39">firstletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1957
<li><a href="#index-firstletterital-29">firstletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1958
<li><a href="#index-firstletterunder-49">firstletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1959
<li><a href="#index-firstwordbold-35">firstwordbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1960
<li><a href="#index-firstwordital-25">firstwordital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1961
<li><a href="#index-firstwordunder-45">firstwordunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1962
<li><a href="#index-grouping-10">grouping</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1963
<li><a href="#index-hyphen-58">hyphen</a>: <a href="#Special-Symbol-Opcodes">Special Symbol Opcodes</a></li>
 
1964
<li><a href="#index-include-103">include</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
 
1965
<li><a href="#index-italsign-27">italsign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1966
<li><a href="#index-joinnum-91">joinnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1967
<li><a href="#index-joinword-74">joinword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1968
<li><a href="#index-largesign-70">largesign</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1969
<li><a href="#index-lastletterbold-41">lastletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1970
<li><a href="#index-lastletterital-31">lastletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1971
<li><a href="#index-lastletterunder-51">lastletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1972
<li><a href="#index-lastwordboldafter-38">lastwordboldafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1973
<li><a href="#index-lastwordboldbefore-36">lastwordboldbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1974
<li><a href="#index-lastworditalafter-28">lastworditalafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1975
<li><a href="#index-lastworditalbefore-26">lastworditalbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1976
<li><a href="#index-lastwordunderafter-48">lastwordunderafter</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1977
<li><a href="#index-lastwordunderbefore-46">lastwordunderbefore</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1978
<li><a href="#index-lenboldphrase-44">lenboldphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1979
<li><a href="#index-lenitalphrase-34">lenitalphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1980
<li><a href="#index-lenunderphrase-54">lenunderphrase</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
1981
<li><a href="#index-letsign-20">letsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1982
<li><a href="#index-letter-11">letter</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1983
<li><a href="#index-litdigit-14">litdigit</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1984
<li><a href="#index-literal-63">literal</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1985
<li><a href="#index-locale-104">locale</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
 
1986
<li><a href="#index-lowercase-12">lowercase</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1987
<li><a href="#index-lowword-75">lowword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1988
<li><a href="#index-math-16">math</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
1989
<li><a href="#index-midendword-82">midendword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1990
<li><a href="#index-midnum-89">midnum</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1991
<li><a href="#index-midword-81">midword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1992
<li><a href="#index-multind-106">multind</a>: <a href="#Miscellaneous-Opcodes">Miscellaneous Opcodes</a></li>
 
1993
<li><a href="#index-noback-60">noback</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1994
<li><a href="#index-nocont-65">nocont</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1995
<li><a href="#index-nocross-73">nocross</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1996
<li><a href="#index-nofor-61">nofor</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
1997
<li><a href="#index-noletsign-21">noletsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1998
<li><a href="#index-noletsignafter-23">noletsignafter</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
1999
<li><a href="#index-noletsignbefore-22">noletsignbefore</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
2000
<li><a href="#index-numsign-24">numsign</a>: <a href="#Braille-Indicator-Opcodes">Braille Indicator Opcodes</a></li>
 
2001
<li><a href="#index-partword-84">partword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2002
<li><a href="#index-pass2-99">pass2</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
 
2003
<li><a href="#index-pass3-100">pass3</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
 
2004
<li><a href="#index-pass4-101">pass4</a>: <a href="#The-Context-and-Multipass-Opcodes">The Context and Multipass Opcodes</a></li>
 
2005
<li><a href="#index-postpunc-87">postpunc</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2006
<li><a href="#index-prepunc-86">prepunc</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2007
<li><a href="#index-prfword-78">prfword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2008
<li><a href="#index-punctuation-7">punctuation</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
2009
<li><a href="#index-repeated-68">repeated</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2010
<li><a href="#index-replace-66">replace</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2011
<li><a href="#index-repword-69">repword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2012
<li><a href="#index-sign-15">sign</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
2013
<li><a href="#index-singleletterbold-43">singleletterbold</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
2014
<li><a href="#index-singleletterital-33">singleletterital</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
2015
<li><a href="#index-singleletterunder-53">singleletterunder</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
2016
<li><a href="#index-space-6">space</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
2017
<li><a href="#index-sufword-77">sufword</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2018
<li><a href="#index-swapcc-97">swapcc</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
 
2019
<li><a href="#index-swapcd-95">swapcd</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
 
2020
<li><a href="#index-swapdd-96">swapdd</a>: <a href="#Swap-Opcodes">Swap Opcodes</a></li>
 
2021
<li><a href="#index-syllable-72">syllable</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
 
2022
<li><a href="#index-undersign-47">undersign</a>: <a href="#Emphasis-Opcodes">Emphasis Opcodes</a></li>
 
2023
<li><a href="#index-uplow-9">uplow</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
2024
<li><a href="#index-uppercase-13">uppercase</a>: <a href="#Character_002dDefinition-Opcodes">Character-Definition Opcodes</a></li>
 
2025
<li><a href="#index-word-71">word</a>: <a href="#Translation-Opcodes">Translation Opcodes</a></li>
2069
2026
   </ul><p><a name="Function-Index"></a>
2070
2027
 
2071
2028
<h2 class="unnumbered">Function Index</h2>
2073
2030
 
2074
2031
 
2075
2032
<ul class="index-fn" compact>
2076
 
<li><a href="#index-lou_005fbackTranslate-110"><code>lou_backTranslate</code></a>: <a href="#lou_005fbackTranslate">lou_backTranslate</a></li>
2077
 
<li><a href="#index-lou_005fbackTranslateString-109"><code>lou_backTranslateString</code></a>: <a href="#lou_005fbackTranslateString">lou_backTranslateString</a></li>
2078
 
<li><a href="#index-lou_005ffree-116"><code>lou_free</code></a>: <a href="#lou_005ffree">lou_free</a></li>
2079
 
<li><a href="#index-lou_005fgetTable-114"><code>lou_getTable</code></a>: <a href="#lou_005fgetTable">lou_getTable</a></li>
2080
 
<li><a href="#index-lou_005fhyphenate-111"><code>lou_hyphenate</code></a>: <a href="#lou_005fhyphenate">lou_hyphenate</a></li>
2081
 
<li><a href="#index-lou_005flogFile-112"><code>lou_logFile</code></a>: <a href="#lou_005flogFile">lou_logFile</a></li>
2082
 
<li><a href="#index-lou_005flogPrint-113"><code>lou_logPrint</code></a>: <a href="#lou_005flogPrint">lou_logPrint</a></li>
2083
 
<li><a href="#index-lou_005freadCharFromFile-115"><code>lou_readCharFromFile</code></a>: <a href="#lou_005freadCharFromFile">lou_readCharFromFile</a></li>
2084
 
<li><a href="#index-lou_005ftranslate-108"><code>lou_translate</code></a>: <a href="#lou_005ftranslate">lou_translate</a></li>
2085
 
<li><a href="#index-lou_005ftranslateString-107"><code>lou_translateString</code></a>: <a href="#lou_005ftranslateString">lou_translateString</a></li>
2086
 
<li><a href="#index-lou_005fversion-106"><code>lou_version</code></a>: <a href="#lou_005fversion">lou_version</a></li>
 
2033
<li><a href="#index-lou_005fbackTranslate-111"><code>lou_backTranslate</code></a>: <a href="#lou_005fbackTranslate">lou_backTranslate</a></li>
 
2034
<li><a href="#index-lou_005fbackTranslateString-110"><code>lou_backTranslateString</code></a>: <a href="#lou_005fbackTranslateString">lou_backTranslateString</a></li>
 
2035
<li><a href="#index-lou_005ffree-117"><code>lou_free</code></a>: <a href="#lou_005ffree">lou_free</a></li>
 
2036
<li><a href="#index-lou_005fgetTable-115"><code>lou_getTable</code></a>: <a href="#lou_005fgetTable">lou_getTable</a></li>
 
2037
<li><a href="#index-lou_005fhyphenate-112"><code>lou_hyphenate</code></a>: <a href="#lou_005fhyphenate">lou_hyphenate</a></li>
 
2038
<li><a href="#index-lou_005flogFile-113"><code>lou_logFile</code></a>: <a href="#lou_005flogFile">lou_logFile</a></li>
 
2039
<li><a href="#index-lou_005flogPrint-114"><code>lou_logPrint</code></a>: <a href="#lou_005flogPrint">lou_logPrint</a></li>
 
2040
<li><a href="#index-lou_005freadCharFromFile-116"><code>lou_readCharFromFile</code></a>: <a href="#lou_005freadCharFromFile">lou_readCharFromFile</a></li>
 
2041
<li><a href="#index-lou_005ftranslate-109"><code>lou_translate</code></a>: <a href="#lou_005ftranslate">lou_translate</a></li>
 
2042
<li><a href="#index-lou_005ftranslateString-108"><code>lou_translateString</code></a>: <a href="#lou_005ftranslateString">lou_translateString</a></li>
 
2043
<li><a href="#index-lou_005fversion-107"><code>lou_version</code></a>: <a href="#lou_005fversion">lou_version</a></li>
2087
2044
   </ul><p><a name="Program-Index"></a>
2088
2045
 
2089
2046
<h2 class="unnumbered">Program Index</h2>
2092
2049
 
2093
2050
<ul class="index-pg" compact>
2094
2051
<li><a href="#index-lou_005fallround-3"><code>lou_allround</code></a>: <a href="#lou_005fallround">lou_allround</a></li>
 
2052
<li><a href="#index-lou_005fcheckhyphens-5"><code>lou_checkhyphens</code></a>: <a href="#lou_005fcheckhyphens">lou_checkhyphens</a></li>
2095
2053
<li><a href="#index-lou_005fchecktable-2"><code>lou_checktable</code></a>: <a href="#lou_005fchecktable">lou_checktable</a></li>
2096
2054
<li><a href="#index-lou_005fdebug-1"><code>lou_debug</code></a>: <a href="#lou_005fdebug">lou_debug</a></li>
2097
 
<li><a href="#index-lou_005ftranslate-4"><code>lou_translate</code></a>: <a href="#lou_005ftranslate-_002df-_007c-_002db-tablename">lou_translate -f | -b tablename</a></li>
 
2055
<li><a href="#index-lou_005ftranslate-4"><code>lou_translate</code></a>: <a href="#lou_005ftranslate-_0028program_0029">lou_translate (program)</a></li>
2098
2056
   </ul></body></html>
2099
2057