]> git.lyx.org Git - lyx.git/blob - lib/examples/Braille.lyx
add a module for typesetting Braille
[lyx.git] / lib / examples / Braille.lyx
1 #LyX 1.6.0svn created this file. For more info see http://www.lyx.org/
2 \lyxformat 310
3 \begin_document
4 \begin_header
5 \textclass article
6 \begin_preamble
7 % color greyed-out notes blue
8 \renewenvironment{lyxgreyedout}
9  {\textcolor{blue}\bgroup}{\egroup}
10 \end_preamble
11 \begin_modules
12 Braille
13 \end_modules
14 \language english
15 \inputencoding utf8
16 \font_roman default
17 \font_sans default
18 \font_typewriter default
19 \font_default_family default
20 \font_sc false
21 \font_osf false
22 \font_sf_scale 100
23 \font_tt_scale 100
24 \graphics default
25 \paperfontsize default
26 \spacing single
27 \use_hyperref true
28 \pdf_title "How to write Braille with LyX"
29 \pdf_author "Uwe Stöhr"
30 \pdf_bookmarks true
31 \pdf_bookmarksnumbered false
32 \pdf_bookmarksopen false
33 \pdf_bookmarksopenlevel 1
34 \pdf_breaklinks false
35 \pdf_pdfborder true
36 \pdf_colorlinks true
37 \pdf_backref false
38 \pdf_pagebackref false
39 \pdf_pdfusetitle true
40 \papersize default
41 \use_geometry true
42 \use_amsmath 1
43 \use_esint 1
44 \cite_engine basic
45 \use_bibtopic false
46 \paperorientation portrait
47 \leftmargin 2.5cm
48 \rightmargin 2.5cm
49 \secnumdepth 3
50 \tocdepth 3
51 \paragraph_separation skip
52 \defskip medskip
53 \quotes_language english
54 \papercolumns 1
55 \papersides 1
56 \paperpagestyle default
57 \tracking_changes false
58 \output_changes false
59 \author "" 
60 \author "" 
61 \end_header
62
63 \begin_body
64
65 \begin_layout Title
66 How to write Braille with LyX
67 \end_layout
68
69 \begin_layout Author
70 Uwe Stöhr
71 \newline
72
73 \begin_inset CommandInset href
74 LatexCommand href
75 target "uwestoehr@web.de"
76 type "mailto:"
77
78 \end_inset
79
80
81 \end_layout
82
83 \begin_layout Standard
84 First a general note: The Braille you can create with LaTeX is not a professiona
85 l one! Professional Braille can be 6 or 8\InsetSpace \thinspace{}
86 dot, while LaTeX only supports
87  only 6\InsetSpace \thinspace{}
88 dot Braille without accented characters.
89 \end_layout
90
91 \begin_layout Standard
92 To write Braille with LyX, load the module 
93 \family sans
94 Braille
95 \family default
96  in the document settings under 
97 \family sans
98 Document\InsetSpace ~
99 Class
100 \family default
101 .
102  Now select the environment 
103 \family sans
104 Braille\InsetSpace ~
105 (default)
106 \family default
107  or 
108 \family sans
109 Braille\InsetSpace ~
110 (textsize)
111 \family default
112  from the end of LyX's environment selection box and write your text.
113  The other Braille environments are only turn on/off some properties as
114  described below; keep them empty!
115 \end_layout
116
117 \begin_layout Standard
118 Here is an example:
119 \lyxline
120
121 \end_layout
122
123 \begin_layout Standard
124 with Latin letters:
125 \newline
126 This is an example sentence written in Braille.
127 \end_layout
128
129 \begin_layout Standard
130 with Braille letters:
131 \end_layout
132
133 \begin_layout Braille (default)
134 This is an example sentence written in Braille.
135 \end_layout
136
137 \begin_layout Standard
138
139 \lyxline
140
141 \end_layout
142
143 \begin_layout Standard
144 \begin_inset VSpace bigskip
145 \end_inset
146
147 You can see that LaTeX is not able to hyphenate words written in Braille.
148  You have to do this manually.
149 \end_layout
150
151 \begin_layout Standard
152 \begin_inset VSpace bigskip
153 \end_inset
154
155
156 \begin_inset Note Greyedout
157 status open
158
159 \begin_layout Standard
160
161 \series bold
162 Note:
163 \series default
164  Only Latin letters, numbers, punctuations, parentheses, and brackets can
165  be printed in Braille.
166  Special characters like 
167 \begin_inset Quotes eld
168 \end_inset
169
170 @
171 \begin_inset Quotes erd
172 \end_inset
173
174 , or 
175 \begin_inset Quotes eld
176 \end_inset
177
178 $
179 \begin_inset Quotes erd
180 \end_inset
181
182 , accented characters like umlauts, and line breaks are not supported.
183 \end_layout
184
185 \end_inset
186
187
188 \end_layout
189
190 \begin_layout Standard
191 \begin_inset VSpace bigskip
192 \end_inset
193
194
195 \begin_inset Note Greyedout
196 status open
197
198 \begin_layout Standard
199
200 \series bold
201 Note:
202 \series default
203  LyX and LaTeX's proper names 
204 \begin_inset Quotes eld
205 \end_inset
206
207 LaTeX
208 \begin_inset Quotes erd
209 \end_inset
210
211
212 \begin_inset Quotes eld
213 \end_inset
214
215 LaTeX2e
216 \begin_inset Quotes erd
217 \end_inset
218
219
220 \begin_inset Quotes eld
221 \end_inset
222
223 TeX
224 \begin_inset Quotes erd
225 \end_inset
226
227 , and 
228 \begin_inset Quotes eld
229 \end_inset
230
231 LyX
232 \begin_inset Quotes erd
233 \end_inset
234
235  must be inserted as ERT, as in the following example:
236 \end_layout
237
238 \end_inset
239
240
241 \end_layout
242
243 \begin_layout Standard
244
245 \lyxline
246
247 \end_layout
248
249 \begin_layout Standard
250 Latin: 
251 \begin_inset ERT
252 status collapsed
253
254 \begin_layout Standard
255
256 LyX
257 \end_layout
258
259 \end_inset
260
261  is cool!
262 \newline
263 Braille:
264 \end_layout
265
266 \begin_layout Braille (default)
267 \begin_inset ERT
268 status collapsed
269
270 \begin_layout Standard
271
272 LyX
273 \end_layout
274
275 \end_inset
276
277  is cool!
278 \end_layout
279
280 \begin_layout Standard
281
282 \lyxline
283
284 \end_layout
285
286 \begin_layout Standard
287 Here is an overview about the different Braille environments using the example
288  text 
289 \begin_inset Quotes eld
290 \end_inset
291
292 This is Braille.
293 \begin_inset Quotes erd
294 \end_inset
295
296
297 \end_layout
298
299 \begin_layout Standard
300 \begin_inset VSpace bigskip
301 \end_inset
302
303 Default:
304 \end_layout
305
306 \begin_layout Braille (default)
307 This is Braille.
308 \end_layout
309
310 \begin_layout Standard
311 Size that approximately matches the document's text size:
312 \end_layout
313
314 \begin_layout Braille (textsize)
315 This is Braille.
316 \end_layout
317
318 \begin_layout Standard
319 \begin_inset VSpace bigskip
320 \end_inset
321
322 Tiny dots can be displayed at empty positions:
323 \end_layout
324
325 \begin_layout Braille (dots on)
326
327 \end_layout
328
329 \begin_layout Braille (textsize)
330 This is Braille.
331 \end_layout
332
333 \begin_layout Standard
334 \begin_inset VSpace bigskip
335 \end_inset
336
337 The text can be printed mirrored to be later able to for "print" Braille
338  by hand with a needle or another suitable method:
339 \end_layout
340
341 \begin_layout Standard
342 Normal:
343 \end_layout
344
345 \begin_layout Braille (default)
346 This is Braille.
347 \end_layout
348
349 \begin_layout Standard
350 Mirrored:
351 \end_layout
352
353 \begin_layout Braille (mirror on)
354
355 \end_layout
356
357 \begin_layout Braille (default)
358 This is Braille.
359 \end_layout
360
361 \begin_layout Braille (mirror off)
362
363 \end_layout
364
365 \begin_layout Standard
366 \begin_inset VSpace bigskip
367 \end_inset
368
369 Computer Braille that uses 8 dots can be turned on with the command 
370 \series bold
371
372 \backslash
373 brailleeightdotstrue
374 \series default
375 .
376  But the two extra dots are only used when they are accessed with the command
377  
378 \series bold
379
380 \backslash
381 braillebox
382 \series default
383 .
384  For example the command
385 \newline
386
387 \series bold
388
389 \backslash
390 braillebox{8175}
391 \series default
392
393 \newline
394 leads to: 
395 \begin_inset ERT
396 status collapsed
397
398 \begin_layout Standard
399
400
401 \backslash
402 brailleeightdotstrue
403 \end_layout
404
405 \end_inset
406
407  
408 \begin_inset ERT
409 status collapsed
410
411 \begin_layout Standard
412
413
414 \backslash
415 braillebox{8175}
416 \end_layout
417
418 \end_inset
419
420
421 \begin_inset ERT
422 status collapsed
423
424 \begin_layout Standard
425
426
427 \backslash
428 brailleeightdotsfalse
429 \end_layout
430
431 \end_inset
432
433
434 \end_layout
435
436 \begin_layout Standard
437 \begin_inset VSpace bigskip
438 \end_inset
439
440 The size of the default Braille font can be changed by the length 
441 \series bold
442
443 \backslash
444 brailleunit
445 \series default
446 .
447  Its default value is 2.4\InsetSpace \thinspace{}
448 mm.
449  To get e.\InsetSpace \thinspace{}
450 g.\InsetSpace ~
451 double-sized Braille where also the tiny dots have the double
452  size, use this command in ERT in your document:
453 \end_layout
454
455 \begin_layout Standard
456
457 \series bold
458
459 \backslash
460 renewcommand{
461 \backslash
462 braillenormal}[1]
463 \newline
464 \InsetSpace ~
465 {
466 \backslash
467 setlength{
468 \backslash
469 brailleunit}{4.8mm}
470 \backslash
471 braille{#1}}
472 \end_layout
473
474 \begin_layout Standard
475 Double-sized Braille:
476 \begin_inset ERT
477 status collapsed
478
479 \begin_layout Standard
480
481
482 \backslash
483 renewcommand{
484 \backslash
485 braillenormal}[1]
486 \end_layout
487
488 \begin_layout Standard
489
490  {
491 \backslash
492 setlength{
493 \backslash
494 brailleunit}{4mm}
495 \backslash
496 braille{#1}}
497 \end_layout
498
499 \end_inset
500
501
502 \end_layout
503
504 \begin_layout Braille (default)
505 This is Braille.
506 \end_layout
507
508 \begin_layout Standard
509 \begin_inset ERT
510 status collapsed
511
512 \begin_layout Standard
513
514
515 \backslash
516 renewcommand{
517 \backslash
518 braillenormal}[1]
519 \end_layout
520
521 \begin_layout Standard
522
523  {
524 \backslash
525 setlength{
526 \backslash
527 brailleunit}{2mm}
528 \backslash
529 braille{#1}}
530 \end_layout
531
532 \end_inset
533
534
535 \end_layout
536
537 \begin_layout Standard
538 \begin_inset VSpace bigskip
539 \end_inset
540
541 For more informations about the Braille cell dimensions have a look at 
542 \begin_inset CommandInset href
543 LatexCommand href
544 name "Braille cell dimensions"
545 target "http://www.tiresias.org/publications/reports/braille_cell.htm"
546
547 \end_inset
548
549 .
550 \end_layout
551
552 \end_body
553 \end_document