Mercurial > hgrepos > hgweb.cgi > yatex
comparison docs/yatexe.tex @ 20:b6127058e365
Change the YaTeX-math-mode's prefix from `,' to `;'.
Add YaTeX-apropos, YaTeX-what-column, YaTeX-beginning-of-environment,
YaTeX-end-of-environment.
Add variables YaTeX-default-pop-window-height, YaTeX-close-paren-always,
YaTeX-no-begend-shortcut, YaTeX-auto-math-mode.
Remove Greek letters from maketitle-type.
Make YaTeX-inner-environment two times faster and more reliable.
C-u for [prefix] k kills contents too.
Fix the detection of the range of section-type commands when nested.
Add \end{ completion.
Add YaTeX-generate-simple.
Refine documents(using Texinfo).
%#REQUIRE for sub-preambles.
author | yuuji |
---|---|
date | Thu, 07 Jul 1994 16:37:05 +0000 |
parents | |
children | 0f8b77d22c8a |
comparison
equal
deleted
inserted
replaced
19:6b0fab5e8eea | 20:b6127058e365 |
---|---|
1 \input texinfo.tex | |
2 @setfilename yatexe | |
3 @settitle Yet Another tex-mode for Emacs | |
4 | |
5 @iftex | |
6 @syncodeindex fn cp | |
7 @syncodeindex vr cp | |
8 @end iftex | |
9 | |
10 @titlepage | |
11 @sp 10 | |
12 @center | |
13 @subtitle Yet Another tex-mode for emacs | |
14 @title Wild Bird | |
15 @subtitle // YaTeX // | |
16 @author @copyright{} 1991-1994 by HIROSE, Yuuji [yuuji@@ae.keio.ac.jp] | |
17 @end titlepage | |
18 | |
19 @node Top, What is YaTeX?, (dir), (dir) | |
20 @comment node-name, next, previous, up | |
21 @cindex Demacs | |
22 @cindex Mule | |
23 @cindex LaTeX | |
24 @cindex YaTeX | |
25 | |
26 @menu | |
27 * What is YaTeX?:: | |
28 * Main features:: | |
29 * Installation:: | |
30 * Typesetting:: | |
31 * %# notation:: | |
32 * Completion:: | |
33 * Commenting out:: | |
34 * Cursor jump:: | |
35 * Changing and Deleting:: | |
36 * Filling an item:: | |
37 * Local dictionaries:: | |
38 * Updation of @code{\includeonly}:: | |
39 * What column?:: | |
40 * Online help:: | |
41 * Cooperation with other packages:: | |
42 * Customizations:: | |
43 * Etcetera:: | |
44 * Copying:: | |
45 | |
46 --- The Detailed Node Listing --- | |
47 | |
48 %# notation | |
49 | |
50 * Changing typesetter:: | |
51 * Static region for typesetting:: | |
52 * Lpr format:: | |
53 * Editing %# notation:: | |
54 | |
55 Completion | |
56 | |
57 * Begin-type completion:: | |
58 * Section-type completion:: | |
59 * Large-type completion:: | |
60 * Maketitle-type completion:: | |
61 * Arbitrary completion:: | |
62 * End completion:: | |
63 * Accent completion:: | |
64 * Image completion:: | |
65 * Greek letters completion:: | |
66 | |
67 Section-type completion | |
68 | |
69 * view-sectioning:: | |
70 | |
71 Customizations | |
72 | |
73 * Lisp variables:: | |
74 * Add-in functions:: | |
75 | |
76 Lisp variables | |
77 | |
78 * All customizable variables:: | |
79 * Sample definitions:: | |
80 * Hook variables:: | |
81 * Hook file:: | |
82 @end menu | |
83 | |
84 @node What is YaTeX?, Main features, Top, Top | |
85 @comment node-name, next, previous, up | |
86 @chapter What is YaTeX? | |
87 | |
88 YaTeX automates typesetting and previewing of LaTeX and enables | |
89 completing input of LaTeX mark-up command such as | |
90 @code{\begin@{@}}..@code{\end@{@}}. | |
91 | |
92 YaTeX also supports Demacs which runs on MS-DOS(386), Mule (Multi | |
93 Language Enhancement to GNU Emacs), and latex on DOS. | |
94 | |
95 @node Main features, Installation, What is YaTeX?, Top | |
96 @comment node-name, next, previous, up | |
97 @chapter Main features | |
98 | |
99 @itemize | |
100 @item Invocation of typesetter, previewer and related programs(C-c t) | |
101 @item Typesetting on static region which is independent from point | |
102 @item Semiautomatic replacing of @code{\include only} | |
103 @item Jumping to error line(@kbd{C-c '}) | |
104 @item Completing-read of La@TeX{} commands such as @code{\begin@{@}}, | |
105 @code{\section} etc. | |
106 (@kbd{C-c b}, @kbd{C-c s}, @kbd{C-c l}, @kbd{C-c m}) | |
107 @item Enclosing text into La@TeX{} environments or commands | |
108 (@kbd{C-u} @var{AboveKeyStrokes}) | |
109 @item Learning unknown/new La@TeX{} commands for the next completion | |
110 @item Argument reading with a guide for complicated La@TeX{} commands | |
111 @item Generating argument-readers for new/unsupported commands(@file{yatexgen}) | |
112 @item Quick changing or deleting of La@TeX{} commands(@kbd{C-c c}, @kbd{C-c k}) | |
113 @item Jumping from and to inter-file, begin<->end, ref<->label(@kbd{C-c g}) | |
114 @item Blanket commenting out or uncommenting | |
115 (@kbd{C-c >}, @kbd{C-c <}, @kbd{C-c ,}, @kbd{C-c .}) | |
116 @item Easy input of accent mark, math-mode's commands and Greek letters | |
117 (@kbd{C-c a}, @kbd{;}, @kbd{/}) | |
118 @item Online help for the popular La@TeX{} commands | |
119 (@kbd{C-c ?}, @kbd{C-c /})(English help is not yet supported) | |
120 @end itemize | |
121 | |
122 @node Installation, Typesetting, Main features, Top | |
123 @comment node-name, next, previous, up | |
124 @chapter Installation | |
125 @cindex installation | |
126 @cindex .emacs | |
127 @cindex auto-mode-alist | |
128 @cindex autoload | |
129 | |
130 Put next two expressions into your @file{~/.emacs}. | |
131 | |
132 @lisp | |
133 (setq auto-mode-alist | |
134 (cons (cons "\\.tex$" 'yatex-mode) auto-mode-alist)) | |
135 (autoload 'yatex-mode "yatex" "Yet Another La@TeX{} mode" t) | |
136 @end lisp | |
137 | |
138 Next, add certain path name where you put files of YaTeX to your | |
139 load-path. If you want to put them in @file{~/src/emacs}, write | |
140 | |
141 @lisp | |
142 (setq load-path | |
143 (cons (expand-file-name "~/src/emacs") load-path)) | |
144 @end lisp | |
145 | |
146 @noindent | |
147 in your @file{~/.emacs} | |
148 | |
149 Then, yatex-mode will be automatically loaded when you visit a | |
150 file which has extension @file{.tex}. If yatex-mode is successfully | |
151 loaded, mode string on mode line will be turned to "YaTeX". | |
152 | |
153 | |
154 @node Typesetting, %# notation, Installation, Top | |
155 @comment node-name, next, previous, up | |
156 @chapter Typesetting | |
157 @cindex typesetting | |
158 @cindex previewer | |
159 @cindex typesetter | |
160 @cindex latex | |
161 @cindex printing out | |
162 | |
163 The prefix key stroke of yatex-mode is @kbd{C-c} (Press 'C' with Control | |
164 key) by default. If you don't intend to change the prefix key stroke, | |
165 assume all @kbd{[prefix]} as @kbd{C-c} in this document. These key | |
166 strokes execute typeset or preview command. | |
167 | |
168 @table @kbd | |
169 @item [prefix] tj | |
170 @dots{} invoke latex | |
171 @item [prefix] tr | |
172 @dots{} invoke latex on region | |
173 @item [prefix] tk | |
174 @dots{} kill current typesetting process | |
175 @item [prefix] tb | |
176 @dots{} invoke bibtex | |
177 @item [prefix] tp | |
178 @dots{} preview | |
179 @item [prefix] tl | |
180 @dots{} lpr dvi-file | |
181 @end table | |
182 | |
183 The current editing window will be divided horizontally when you | |
184 invoke latex command, and log message of La@TeX{} typesetting will be | |
185 displayed in the other window; called typesetting buffer. The | |
186 typesetting buffer automatically scrolls up and traces La@TeX{} | |
187 warnings and error messages. If you see latex stopping by an | |
188 error, you can send string to latex in the typesetting buffer. | |
189 | |
190 If an error stops the La@TeX{} typesetting, this key stroke will | |
191 move the cursor to the line where La@TeX{} error is detected. | |
192 | |
193 @table @kbd | |
194 @item [prefix] ' | |
195 @itemx ([prefix]+single quotation) | |
196 | |
197 @dots{} jump to the previous error or warning | |
198 @end table | |
199 | |
200 If you find a noticeable error, move to the typesetting buffer and move | |
201 the cursor on the line of error message and type @kbd{SPACE} key. This | |
202 makes the cursor move to corresponding source line. | |
203 | |
204 Since @kbd{[prefix] tr} pastes the region into the file | |
205 @file{texput.tex} in the current directory, you should be careful of | |
206 overwriting. The method of specification of the region is shown in the | |
207 section @xref{%#NOTATION}. | |
208 | |
209 The documentstyle for typeset-region is the same as that of editing | |
210 file if you edit one file, and is the same as main file's if you | |
211 edit splitting files. | |
212 | |
213 YaTeX asks you the range of dvi-printing by default. You can | |
214 skip this by invoking it with universal-argument as follows: | |
215 | |
216 @example | |
217 C-u [prefix] tl | |
218 @end example | |
219 | |
220 @node %# notation, Completion, Typesetting, Top | |
221 @comment node-name, next, previous, up | |
222 @chapter %# notation | |
223 @cindex %# notation | |
224 | |
225 You can control the typesetting process by describing @code{%#} | |
226 notations in the source text. | |
227 | |
228 @menu | |
229 * Changing typesetter:: | |
230 * Static region for typesetting:: | |
231 * Lpr format:: | |
232 * Editing %# notation:: | |
233 @end menu | |
234 | |
235 @node Changing typesetter, Static region for typesetting, %# notation, %# notation | |
236 @comment node-name, next, previous, up | |
237 @section To change the `latex' command or to split a source text. | |
238 @cindex typesetter | |
239 | |
240 To change the typesetting command, write | |
241 | |
242 @example | |
243 %#!latex-big | |
244 @end example | |
245 | |
246 @noindent | |
247 anywhere in the source text. And if you split the source text and | |
248 edit subfile that should be included from main text. | |
249 | |
250 @example | |
251 %#!latex main.tex | |
252 @end example | |
253 | |
254 @noindent | |
255 will be helpful to execute latex on main file from sub text buffer. Since | |
256 this command line after @kbd{%#!} will be sent to shell literally, next | |
257 description makes it convenient to use ghostview as dvi-previewer. | |
258 | |
259 @example | |
260 %#!latex main ; dvi2ps main.dvi > main | |
261 @end example | |
262 | |
263 @noindent | |
264 Note that YaTeX assumes the component before the last period of | |
265 the last word in this line as base name of the main La@TeX{} source. | |
266 | |
267 Here are the restrictions on splitting sources. | |
268 | |
269 @itemize | |
270 @item All the file name should be different. | |
271 @item You can put split texts in sub directory, but not in | |
272 sub directory of sub directory. | |
273 @item In the main text,specify the file with relative path name | |
274 such as \include{chap1/sub}, when you include the file in | |
275 a sub-directory. | |
276 @item In a sub-text, write @code{%#!latex main.tex} even if @file{main.tex} | |
277 is in the parent directory(not %#!latex ../main.tex). | |
278 @end itemize | |
279 | |
280 @node Static region for typesetting, Lpr format, Changing typesetter, %# notation | |
281 @comment node-name, next, previous, up | |
282 @section Static region | |
283 @cindex static region | |
284 @cindex Fixed region | |
285 | |
286 Typeset-region by @kbd{[prefix] tr} passes the region between point and | |
287 mark to typesetting command by default. But when you want to typeset | |
288 static region, enclose the region by @code{%#BEGIN} and @code{%#END} as | |
289 follows. | |
290 | |
291 @example | |
292 %#BEGIN | |
293 TheRegionYouWantToTypesetManyTimes | |
294 %#END | |
295 @end example | |
296 | |
297 This is the rule of deciding the region. | |
298 | |
299 @enumerate | |
300 @item | |
301 If there exists %#BEGIN before point, | |
302 | |
303 @enumerate | |
304 @item | |
305 If there exists %#END after %#BEGIN, | |
306 @itemize | |
307 @item From %#BEGIN to %#END. | |
308 @end itemize | |
309 | |
310 @item | |
311 If %#END does not exist after %#BEGIN, | |
312 @itemize | |
313 @item From %#BEGIN to the end of buffer. | |
314 @end itemize | |
315 @end enumerate | |
316 | |
317 @item | |
318 If there does not exist %#BEGIN before point, | |
319 @itemize | |
320 @item Between point and mark(standard method of Emacs). | |
321 @end itemize | |
322 @end enumerate | |
323 | |
324 It is useful to write @code{%#BEGIN} in the previous line of \begin and | |
325 @code{%#END} in the next line of \@code{end} when you try complex | |
326 environment such as `tabular' many times. It is also useful to put only | |
327 @code{%#BEGIN} alone at the middle of very long text. Do not forget to | |
328 erase @code{%#BEGIN} @code{%#END} pair. | |
329 | |
330 @node Lpr format, Editing %# notation, Static region for typesetting, %# notation | |
331 @comment node-name, next, previous, up | |
332 @section Lpr format | |
333 @cindex lpr format | |
334 | |
335 Lpr format is specified by three Lisp variables. Here are the | |
336 default values of them. | |
337 | |
338 @table @code | |
339 @item (1)dviprint-command-format | |
340 @code{"dvi2ps %f %t %s | lpr"} | |
341 @item (2)dviprint-from-format | |
342 @code{"-f %b"} | |
343 @item (3)dviprint-to-format | |
344 @code{"-t %e"} | |
345 @end table | |
346 | |
347 On YaTeX-lpr, @code{%s} in (1) is replaced by the file name of main | |
348 text, @code{%f} by contents of (2), %t by contents of (3). At these | |
349 replacements, @code{%b} in (2) is also replaced by the number of beginning | |
350 page, @code{%e} in (3) is replaced by the number of ending page. But | |
351 @code{%f} and @code{%t} are ignored when you omit the range of print-out | |
352 by @kbd{C-u [prefix] tl}. | |
353 | |
354 If you want to change this lpr format temporarily, put a command | |
355 such as follows somewhere in the text: | |
356 | |
357 @example | |
358 %#LPR dvi2ps %f %t %s | 4up -page 4 | texfix | lpr -Plp2 | |
359 @end example | |
360 | |
361 And if you want YaTeX not to ask you the range of printing | |
362 out, the next example may be helpful. | |
363 | |
364 @example | |
365 %#LPR dvi2ps %s | lpr | |
366 @end example | |
367 | |
368 @node Editing %# notation, , Lpr format, %# notation | |
369 @comment node-name, next, previous, up | |
370 @section Editing %# notation | |
371 | |
372 To edit @code{%#} notation described above, type | |
373 | |
374 @table @kbd | |
375 @item [prefix] % | |
376 @dots{} editing %# notation menu | |
377 @end table | |
378 | |
379 @noindent | |
380 and select one of the entry of the menu as follows. | |
381 | |
382 @example | |
383 !)Edit-%#! B)EGIN-END-region L)Edit-%#LPR | |
384 @end example | |
385 | |
386 @noindent | |
387 Type @kbd{!} to edit @code{%#!} entry, @code{b} to enclose the region with | |
388 @code{%#BEGIN} and @code{%#END}, and @code{l} to edit @code{%#LPR} entry. | |
389 When you type @kbd{b}, all @code{%#BEGIN} and @code{%#END} are | |
390 automatically erased. | |
391 | |
392 @node Completion, Commenting out, %# notation, Top | |
393 @comment node-name, next, previous, up | |
394 @chapter Completion | |
395 @cindex completion | |
396 | |
397 YaTeX makes it easy to input the La@TeX{} commands. There are several | |
398 kinds of completion type, begin-type, section-type, large-type, etc... | |
399 | |
400 @menu | |
401 * Begin-type completion:: | |
402 * Section-type completion:: | |
403 * Large-type completion:: | |
404 * Maketitle-type completion:: | |
405 * Arbitrary completion:: | |
406 * End completion:: | |
407 * Accent completion:: | |
408 * Image completion:: | |
409 * Greek letters completion:: | |
410 @end menu | |
411 | |
412 @node Begin-type completion, Section-type completion, Completion, Completion | |
413 @comment node-name, next, previous, up | |
414 @section Begin-type completion | |
415 @cindex begin-type completion | |
416 @cindex environment | |
417 @cindex prefix b | |
418 | |
419 "Begin-type completion" completes commands of @code{\begin@{env@}} ... | |
420 @code{\end@{env@}}. All of the begin-type completions begin with this key | |
421 sequence. | |
422 | |
423 @table @kbd | |
424 @item [prefix] b | |
425 @dots{} start begin-type completion | |
426 @end table | |
427 | |
428 @noindent | |
429 An additional key stroke immediately completes a frequently used | |
430 La@TeX{} @code{\begin@{@}}...@code{\@code{end}@{@}} environment. | |
431 | |
432 @table @kbd | |
433 @item [prefix] b c | |
434 @dots{} @code{\begin@{center@}...\end@{center@}} | |
435 @item [prefix] b d | |
436 @dots{} @code{\begin@{document@}...\end@{document@}} | |
437 @item [prefix] b D | |
438 @dots{} @code{\begin@{description@}...\end@{description@}} | |
439 @item [prefix] b e | |
440 @dots{} @code{\begin@{enumerate@}...\end@{enumerate@}} | |
441 @item [prefix] b E | |
442 @dots{} @code{\begin@{equation@}...\end@{equation@}} | |
443 @item [prefix] b i | |
444 @dots{} @code{\begin@{itemize@}...\end@{itemize@}} | |
445 @item [prefix] b l | |
446 @dots{} @code{\begin@{flushleft@}...\end@{flushleft@}} | |
447 @item [prefix] b m | |
448 @dots{} @code{\begin@{minipage@}...\end@{minipage@}} | |
449 @item [prefix] b t | |
450 @dots{} @code{\begin@{tabbing@}...\end@{tabbing@}} | |
451 @item [prefix] b T | |
452 @dots{} @code{\begin@{tabular@}...\end@{tabular@}} | |
453 @item [prefix] b^T | |
454 @dots{} @code{\begin@{table@}...\end@{table@}} | |
455 @item [prefix] b p | |
456 @dots{} @code{\begin@{picture@}...\end@{picture@}} | |
457 @item [prefix] b q | |
458 @dots{} @code{\begin@{quote@}...\end@{quote@}} | |
459 @item [prefix] b Q | |
460 @dots{} @code{\begin@{quotation@}...\end@{quotation@}} | |
461 @item [prefix] b r | |
462 @dots{} @code{\begin@{flushright@}...\end@{flushright@}} | |
463 @item [prefix] b v | |
464 @dots{} @code{\begin@{verbatim@}...\end@{verbatim@}} | |
465 @item [prefix] b V | |
466 @dots{} @code{\begin@{verse@}...\end@{verse@}} | |
467 @end table | |
468 | |
469 Any other La@TeX{} environments are made by completing-read of the | |
470 Emacs function. | |
471 | |
472 @table @kbd | |
473 @item [prefix] b SPACE | |
474 @dots{} begin-type completion | |
475 @end table | |
476 | |
477 @noindent | |
478 The next message will show up in the minibuffer | |
479 | |
480 @example | |
481 Begin environment(default document): | |
482 @end example | |
483 | |
484 @noindent | |
485 by typing @kbd{[prefix] b}. Put the wishing environment with completion | |
486 in the minibuffer, and @code{\begin@{env@}}...\@code{\end@{env@}} will be | |
487 inserted in the La@TeX{} source text. If the environment you want to put | |
488 does not exist in the YaTeX completion table, it will be registered in the | |
489 user completion table. YaTeX automatically saves the user completion | |
490 table in the user dictionary file at exiting of emacs. | |
491 | |
492 If you want to enclose some paragraphs which have already been | |
493 written, invoke the begin-type completion with changing the case | |
494 of @kbd{b} of key sequence upper(or invoke it with universal argument | |
495 by @kbd{C-u} prefix). | |
496 @cindex enclose region into environment | |
497 | |
498 The following example encloses a region with `description' | |
499 environment. | |
500 | |
501 @table @kbd | |
502 @item [prefix] B D | |
503 @itemx (or ESC 1 [prefix] b D) | |
504 @itemx (or C-u [prefix] b D) | |
505 | |
506 @dots{} begin-type completion for region | |
507 @end table | |
508 | |
509 This enclosing holds good for the completing input by @kbd{[prefix] b | |
510 SPC}. @kbd{[prefix] B SPC} enclose a region with the environment selected | |
511 by completing-read. | |
512 | |
513 @node Section-type completion, Large-type completion, Begin-type completion, Completion | |
514 @comment node-name, next, previous, up | |
515 @section Section-type completion | |
516 @cindex section-type completion | |
517 @cindex prefix s | |
518 | |
519 "Section-type completion" completes section-type commands which take an | |
520 argument or more such as @code{\section@{foo@}}. To invoke section-type | |
521 completion, type | |
522 | |
523 @table @kbd | |
524 @item [prefix] s | |
525 @dots{} section-type completion | |
526 @end table | |
527 | |
528 @noindent | |
529 then the prompt | |
530 | |
531 @example | |
532 (C-v for view) \???@{@} (default documentstyle): | |
533 @end example | |
534 | |
535 @noindent | |
536 will show up in the minibuffer. Section-type La@TeX{} commands are | |
537 completed by space key, and the default value is selected when you | |
538 type nothing in the minibuffer. | |
539 | |
540 Next, | |
541 | |
542 @example | |
543 \section@{???@}: | |
544 @end example | |
545 | |
546 @noindent | |
547 prompts you the argument of section-type La@TeX{} command. For | |
548 example, the following inputs | |
549 | |
550 @example | |
551 \???@{@} (default documentstyle): section | |
552 \section{???}: Hello world. | |
553 @end example | |
554 | |
555 @noindent | |
556 will insert the string | |
557 | |
558 @example | |
559 \section@{Hello world.@} | |
560 @end example | |
561 | |
562 in your La@TeX{} source. When you neglect argument such as | |
563 | |
564 @example | |
565 (C-v for view) \???@{@} (default section): vspace* | |
566 \vspace*@{???@}: | |
567 @end example | |
568 | |
569 YaTeX puts | |
570 | |
571 @example | |
572 \vspace*@{@} | |
573 @end example | |
574 | |
575 @noindent | |
576 and move the cursor in the braces. | |
577 | |
578 In La@TeX{} command, there are commands which take more than one | |
579 arguments such as @code{\addtolength{\topmargin}{8mm}}. To complete these | |
580 commands, invoke section-type completion with universal argument as, | |
581 @cindex number of argument | |
582 | |
583 @example | |
584 C-u 2 [prefix] s (or ESC 2 [prefix] s) | |
585 @end example | |
586 | |
587 @noindent | |
588 and make answers in minibuffer like this. | |
589 | |
590 @example | |
591 (C-v for view) \???@{@} (default vspace*): addtolength | |
592 \addtolength@{???@}: \topmargin | |
593 Argument 2: 8mm | |
594 @end example | |
595 | |
596 @code{\addtolength} and the first argument @code{\topmargin} can be typed | |
597 easily by completing read. Since YaTeX also learns the number of | |
598 arguments of section-type command and will ask that many arguments in | |
599 future completion, you had better tell the number of arguments to YaTeX at | |
600 the first completion of the new word. But you can change the number of | |
601 arguments by calling the completion with different universal argument | |
602 again. | |
603 | |
604 The special number of argument 0 makes YaTeX use read-string to | |
605 read the first argument instead of completing-read. It is more | |
606 comfortable to enter first argument without completion when you | |
607 put section title which contains space character. Normally, such | |
608 sectioning commands as chapter, section, paragraph..., have | |
609 argument 0 in the completion table. | |
610 | |
611 Invoking section-type completion with @code{[Prefix] S} (Capital `S') | |
612 includes the region as the first argument of section-type command. | |
613 | |
614 The section/large/maketitle type completion can work at the | |
615 prompt for the argument of other section-type completion. | |
616 Nested La@TeX{} commands are efficiently read with the recursive | |
617 completion by typing YaTeX's completion key sequence in the | |
618 minibuffer. | |
619 | |
620 @menu | |
621 * view-sectioning:: | |
622 @end menu | |
623 | |
624 @node view-sectioning, , Section-type completion, Section-type completion | |
625 @comment node-name, next, previous, up | |
626 @subsection view-sectioning | |
627 @cindex view sectioning | |
628 @cindex outline | |
629 | |
630 In the minibuffer at the prompt of section-type command completion, | |
631 typing @kbd{C-v} shows a list of sectioning commands in source text(The | |
632 line with @code{<<--} mark is the nearest sectioning command). Then, | |
633 default sectioning command appears in the minibuffer. You can go up/down | |
634 sectioning command by typing @kbd{C-p}/@kbd{C-n}, can scrolls up/down the | |
635 listing buffer by @kbd{C-v}/@kbd{M-v}, and can hide sectioning commands | |
636 under certain level by 0 through 6. Type @kbd{?} in the minibuffer of | |
637 sectioning prompt for more information. | |
638 | |
639 @node Large-type completion, Maketitle-type completion, Section-type completion, Completion | |
640 @comment node-name, next, previous, up | |
641 @section Large-type completion | |
642 | |
643 "Large-type completion" inputs the font or size changing | |
644 descriptions such as @code{@{\large @}}. When you type | |
645 | |
646 @table @kbd | |
647 @item [prefix] l | |
648 @dots{} large-type completion | |
649 @end table | |
650 | |
651 @noindent | |
652 the message in the minibuffer | |
653 | |
654 @example | |
655 @{\??? @} (default large): | |
656 @end example | |
657 | |
658 prompts prompts you large-type command with completing-read. There are | |
659 TeX commands to change fonts or sizes, @code{it}, @code{huge} and so on, | |
660 in the completion table. | |
661 | |
662 Region-based completion is also invoked by changing the letter after | |
663 prefix key stroke as @kbd{[prefix] L}. It encloses the region by braces | |
664 with large-type command. | |
665 | |
666 @node Maketitle-type completion, Arbitrary completion, Large-type completion, Completion | |
667 @comment node-name, next, previous, up | |
668 @section Maketitle-type completion | |
669 @cindex maketitle-type completion | |
670 | |
671 We call it "maketitle-type completion" which completes commands such as | |
672 @code{\maketitle}. Take notice that maketitle-type commands take no | |
673 arguments. Then, typing | |
674 | |
675 @table @kbd | |
676 @item [prefix] m | |
677 @dots{} maketitle-type completion | |
678 @end table | |
679 | |
680 @noindent | |
681 begins maketitle-completion. Above mentioned method is true for | |
682 maketitle-completion, and there are La@TeX{} commands with no | |
683 arguments in completion table. | |
684 | |
685 @node Arbitrary completion, End completion, Maketitle-type completion, Completion | |
686 @comment node-name, next, previous, up | |
687 @section Arbitrary completion | |
688 @cindex arbitrary completion | |
689 | |
690 @noindent | |
691 You can complete certain La@TeX{} command anywhere without typical | |
692 completing method as described, by typing | |
693 | |
694 @table @kbd | |
695 @item [prefix] SPC | |
696 @dots{} arbitrary completion | |
697 @end table | |
698 | |
699 @noindent | |
700 after the initial string of La@TeX{} command that is preceded by @code{\}. | |
701 | |
702 @node End completion, Accent completion, Arbitrary completion, Completion | |
703 @comment node-name, next, previous, up | |
704 @section End completion | |
705 @cindex end completion | |
706 | |
707 @noindent | |
708 YaTeX automatically detects the opened environment and close it with | |
709 \@code{\end@{environment@}}. Though proficient YaTeX users never fail to | |
710 make environment with begin-type completion, some may begin an environment | |
711 manually. In that case, type | |
712 | |
713 @table @kbd | |
714 @item [prefix] e | |
715 @dots{} @code{end} completion | |
716 @end table | |
717 | |
718 @noindent | |
719 at the end of the opened environment. | |
720 | |
721 @node Accent completion, Image completion, End completion, Completion | |
722 @comment node-name, next, previous, up | |
723 @section Accent completion | |
724 @cindex accent completion | |
725 | |
726 When you want to write the European accent marks(like @code{\`@{o@}}), | |
727 | |
728 @table @kbd | |
729 @item [prefix] a | |
730 @dots{} accent completion | |
731 @end table | |
732 | |
733 @noindent | |
734 shows the menu | |
735 | |
736 @example | |
737 1:` 2:' 3:^ 4:" 5:~ 6:= 7:. u v H t c d b | |
738 @end example | |
739 | |
740 @noindent | |
741 in the minibuffer. Chose one character or corresponding numeric, | |
742 and you will see | |
743 | |
744 @example | |
745 \`{} | |
746 @end example | |
747 | |
748 @noindent | |
749 in the editing buffer with the cursor positioned in braces. Type | |
750 one more character `o' for example, then | |
751 | |
752 @example | |
753 \`{o} | |
754 @end example | |
755 | |
756 @noindent | |
757 will be completed, and the cursor gets out from braces. | |
758 | |
759 @node Image completion, Greek letters completion, Accent completion, Completion | |
760 @comment node-name, next, previous, up | |
761 @section Image completion of mathematical sign | |
762 @cindex image completion | |
763 @cindex math-mode | |
764 @cindex sigma | |
765 @cindex leftarrow | |
766 @cindex ; | |
767 | |
768 Arrow marks, sigma mark and those signs mainly used in the | |
769 TeX's math environment are completed by key sequences which | |
770 imitate the corresponding symbols graphically. This completion | |
771 only works in the math environment. YaTeX automatically detects | |
772 whether the cursor located in math environment or not, and | |
773 change the behavior of key strokes @kbd{;} and @kbd{/}. | |
774 | |
775 By the way, we often express the leftarrow mark by `<-' for example. | |
776 Considering such image, you can write @code{\leftarrow} by typing @kbd{<-} | |
777 after @kbd{;} (semicolon) as a prefix. In the same way, | |
778 @code{\longleftarrow} (@code{<--}) is completed by typing @kbd{;<--}, | |
779 infinity mark which is imitated by @code{oo} is completed by typing | |
780 @kbd{;oo}. | |
781 | |
782 Here are the sample operations in YaTeX math-mode. | |
783 | |
784 @example | |
785 INPUT Completed La@TeX{} commands | |
786 ; < - @code{\leftarrow} | |
787 ; < - - @code{\longleftarrow} | |
788 ; < - - > @code{\longleftrightarrow} | |
789 ; o @code{\circ} | |
790 ; o o @code{\infty} | |
791 @end example | |
792 | |
793 In any case, you can quit from image completion and can move | |
794 to the next editing operation if the La@TeX{} command you want is | |
795 shown in the buffer. | |
796 | |
797 @code{;} itself in math-environment is inserted by @kbd{;;}. Typing | |
798 @kbd{TAB} in the midst of image completion shows all of the La@TeX{} | |
799 commands that start with the same name as string you previously typed in. | |
800 In this menu buffer, press @kbd{RET} after moving the cursor (by @kbd{n}, | |
801 @kbd{p}, @kbd{b}, @kbd{f}) to insert the La@TeX{} command. | |
802 | |
803 To know all of the completion table, type @kbd{TAB} just after @kbd{;}. | |
804 And here is the sample menu by @kbd{TAB} after @kbd{;<}. | |
805 | |
806 @example | |
807 KEY LaTeX sequence sign | |
808 < \leq < | |
809 ~ | |
810 << \ll << | |
811 <- \leftarrow <- | |
812 <= \Leftarrow <= | |
813 @end example | |
814 | |
815 You can define your favorite key-vs-sequence completion table in the | |
816 Emacs-Lisp variable @code{YaTeX-math-sign-alist-private}. See also | |
817 @file{yatexmth.el} for the information of the structure of this variable. | |
818 | |
819 @node Greek letters completion, , Image completion, Completion | |
820 @comment node-name, next, previous, up | |
821 @section Greek letters completion | |
822 @cindex Greek letters completion | |
823 @cindex / | |
824 | |
825 Math-mode of YaTeX provides another image completion, Greek letters | |
826 completion in the same method. After prefix @kbd{/}, typing @kbd{a} makes | |
827 @code{\alpha}, @kbd{b} makes @code{\beta} and @kbd{g} makes @code{\gamma} | |
828 and so on. First, type @kbd{/TAB} to know all the correspondence of | |
829 alphabets v.s. Greek letters. | |
830 | |
831 If you will find @kbd{;} or @kbd{/} doesn't work in correct position of | |
832 math environment, it may be a bug of YaTeX. Please send me a bug report | |
833 with the configuration of your text, and avoid it temporarily by typing | |
834 @kbd{;} or @kbd{/} after universal-argument(@kbd{C-u}) which forces | |
835 @kbd{;} and @kbd{/} to work as math-prefix. | |
836 | |
837 @node Commenting out, Cursor jump, Completion, Top | |
838 @comment node-name, next, previous, up | |
839 @chapter Commenting out | |
840 @cindex commenting out | |
841 @cindex prefix > | |
842 @cindex prefix < | |
843 @cindex prefix , | |
844 @cindex prefix . | |
845 | |
846 You may want to comment out some region. | |
847 | |
848 @table @kbd | |
849 @item [prefix] > | |
850 @dots{} comment out region by % | |
851 @item [prefix] < | |
852 @dots{} uncomment region | |
853 @end table | |
854 | |
855 @noindent | |
856 cause an operation to the region between point and mark. | |
857 | |
858 @table @kbd | |
859 @item [prefix] . | |
860 @dots{} comment out current paragraph | |
861 @item [prefix] , | |
862 @dots{} uncomment current paragraph | |
863 @end table | |
864 | |
865 @noindent | |
866 comments or uncomments the paragraph where the cursor belongs. | |
867 This `paragraph' means the region marked by the function | |
868 mark-paragraph, bound to @kbd{ESC h} by default. It is NOT | |
869 predictable what will happen when you continuously comment out | |
870 some paragraph many times. | |
871 | |
872 You can also comment out an environment between @code{\begin} and | |
873 @code{\end}, or a @code{\begin}-\@code{\end} pair themselves, by making the | |
874 following key strokes on the line where @code{\begin@{@}} or | |
875 @code{\end@{@}} exists. | |
876 | |
877 @table @kbd | |
878 @item [prefix] > | |
879 @dots{} comment out from \begin to \@code{end} | |
880 @item [prefix] < | |
881 @dots{} uncomment from \begin to \@code{end} | |
882 @end table | |
883 | |
884 @noindent | |
885 comment whole the contents of environment. Moreover, | |
886 | |
887 @table @kbd | |
888 @item [prefix] . | |
889 @dots{} comment out \begin and \@code{end} | |
890 @item [prefix] , | |
891 @dots{} uncomment \begin and \@code{end} | |
892 @end table | |
893 | |
894 @noindent | |
895 (un)comments out only environment declaration: @code{\begin@{@}} and | |
896 @code{\end@{@}}. NOTE that even if you intend to comment out some region, | |
897 invoking @kbd{[prefix] >} on the @code{\begin},@code{\end} line decides to | |
898 work in `commenting out from @code{\begin} to @code{\end}' mode. | |
899 | |
900 | |
901 @node Cursor jump, Changing and Deleting, Commenting out, Top | |
902 @comment node-name, next, previous, up | |
903 @chapter Cursor jump | |
904 @cindex cursor jump | |
905 @cindex prefix g | |
906 | |
907 On a @code{\begin},@code{\end} line, the key stroke | |
908 | |
909 @table @kbd | |
910 @item [prefix] g | |
911 @dots{} go to corresponding object | |
912 @end table | |
913 | |
914 @noindent | |
915 moves the cursor to the corresponding @code{\end},@code{\begin} line, if | |
916 its partner really exists. It is also applicable to A @code{%#BEGIN} and | |
917 @code{%#END} pair. | |
918 | |
919 If you type @code{[prefix] g} on the line of @code{\include@{chap1@}}, | |
920 maybe in main text, YaTeX switches buffer to @file{chap1.tex}. On the | |
921 contrary, the key strokes | |
922 | |
923 @table @kbd | |
924 @item [prefix] ^ | |
925 @dots{} visit main file | |
926 @item [prefix] 4^ | |
927 @dots{} visit main file in other buffer | |
928 @end table | |
929 @cindex prefix ^ | |
930 @cindex prefix 4 ^ | |
931 | |
932 in a sub text switch the buffer to the main text specified by | |
933 @code{%#!} notation. | |
934 | |
935 And these are the functions which work on the current La@TeX{} | |
936 environment: | |
937 | |
938 @table @kbd | |
939 @item M-C-a | |
940 @dots{} beginning of environment | |
941 @item M-C-e | |
942 @dots{} @code{end} of environment | |
943 @item M-C-@@ | |
944 @dots{} mark environment | |
945 @end table | |
946 @cindex M-C-a | |
947 @cindex M-C-e | |
948 @cindex M-C-@@ | |
949 | |
950 @node Changing and Deleting, Filling an item, Cursor jump, Top | |
951 @comment node-name, next, previous, up | |
952 @chapter Changing and Deleting | |
953 | |
954 These functions are for change or deletion of La@TeX{} commands | |
955 already entered. | |
956 | |
957 @table @kbd | |
958 @item [prefix] c | |
959 @dots{} change La@TeX{} command | |
960 @item [prefix] k | |
961 @dots{} kill La@TeX{} command | |
962 @end table | |
963 @cindex prefix c | |
964 @cindex prefix k | |
965 | |
966 @kbd{[prefix] c} can change the name of the corresponding environment | |
967 declaration. @kbd{[prefix] k} works as follows: | |
968 | |
969 @example | |
970 [Invoking position] [action] | |
971 \begin,\end line kill \begin,\end pairs | |
972 %BEGIN, %END line kill %BEGIN,%END pairs | |
973 on a Section-type command kill section-type command | |
974 on a parenthesis kill parentheses | |
975 @end example | |
976 | |
977 While all operations above are to kill `containers' which surround some | |
978 text, universal argument (@kbd{C-u}) for these commands kills not only | |
979 `containers' but also `contents' of them. See below as a sample. | |
980 | |
981 @example | |
982 Original text: [prefix] k C-u [prefix] k | |
983 Main \footnote@{note@} here. Main note here. Main here. | |
984 ~(cursor) | |
985 @end example | |
986 | |
987 @node Filling an item, Local dictionaries, Changing and Deleting, Top | |
988 @comment node-name, next, previous, up | |
989 @chapter Filling an item | |
990 @cindex filling an item | |
991 @cindex prefix i | |
992 | |
993 To fill a term (sentence) of @code{\item}, type | |
994 | |
995 @table @kbd | |
996 @item [prefix] i | |
997 @dots{} fill item | |
998 @end table | |
999 | |
1000 @noindent | |
1001 on that item. | |
1002 | |
1003 YaTeX uses the value of the variable @code{YaTeX-item-regexp} as the | |
1004 regular expression to search item header in itemize environment. | |
1005 If you make a newcommand to itemize terms(eg. @code{\underlineitem}), put | |
1006 | |
1007 @lisp | |
1008 (setq YaTeX-item-regexp | |
1009 "\\(\\\\item\\)\\|\\(\\\\underlineitem\\)") | |
1010 @end lisp | |
1011 @cindex YaTeX-item-regexp | |
1012 | |
1013 in your @file{~/.emacs}. If you are not familiar with regular expression | |
1014 for Emacs-Lisp, name a newcommand for `itemize' beginning with | |
1015 @code{\item} such as @code{\itembf}, not @code{\bfitem}. | |
1016 | |
1017 @node Local dictionaries, Updation of @code{\includeonly}, Filling an item, Top | |
1018 @comment node-name, next, previous, up | |
1019 @chapter Local dictionaries: For nervous users | |
1020 @cindex local dictionaries | |
1021 @cindex nervous users | |
1022 | |
1023 If you have had the experience that you couldn't concentrate on editing | |
1024 because you typed miss-spelled word on completion and the registration of | |
1025 the wrong word to @file{.yatexrc} weighed on your mind. Or if you have | |
1026 thought that you want YaTeX not to register a local newcommand which goes | |
1027 only in current text, into the standard user completion dictionary; | |
1028 @file{.yatexrc}. Write this in your @file{~/.emacs}. | |
1029 | |
1030 @lisp | |
1031 (setq YaTeX-nervous t) | |
1032 @end lisp | |
1033 | |
1034 In addition to `standard table' built in yatex.el and `user table' which | |
1035 is always saved into @file{~/.yatexrc}, the statement above allows you to | |
1036 use `temporary table' for completion. When you enter a word which is | |
1037 never seen in these tables, you can select the table in which you want to | |
1038 save the word; `user table'(UserTable), `temporary table'(TempTable) or | |
1039 discard it(None). | |
1040 | |
1041 But you may want to complete newcommand semi-permanently that is defined | |
1042 in rather large text as graduation thesis, even if the newcommand is a | |
1043 local declaration. After setting @code{YaTeX-nervous} to @code{t}, make | |
1044 an empty file named @file{.yatexrc} (the same name as your user | |
1045 dictionary). YaTeX will use it as the local dictionary to keep the | |
1046 contents of temporary completion table. This local dictionary will be | |
1047 loaded only when you edit the file which exists in the same directory. | |
1048 | |
1049 @node Updation of @code{\includeonly}, What column?, Local dictionaries, Top | |
1050 @comment node-name, next, previous, up | |
1051 @chapter Updation of @code{\includeonly} | |
1052 @cindex includeonly | |
1053 | |
1054 When you edit splitting source texts, the notation | |
1055 | |
1056 @example | |
1057 \includeonly@{CurrentEditingFileName@} | |
1058 @end example | |
1059 | |
1060 @noindent | |
1061 in the main file reduces the time of typesetting. If you want | |
1062 to hack other file a little however, you have to rewrite it to | |
1063 | |
1064 @example | |
1065 \includeonly@{OtherFileNameYouWantToFix@} | |
1066 @end example | |
1067 | |
1068 @noindent | |
1069 in the main file. YaTeX automatically detects that the current | |
1070 edited text is not in includeonly list and prompts you | |
1071 | |
1072 @example | |
1073 A)dd R)eplace %)comment? | |
1074 @end example | |
1075 | |
1076 in the minibuffer. Type @kbd{a} if you want to add the current file name | |
1077 to @code{\includeonly} list, @kbd{r} to replace \@code{includeonly} list | |
1078 by the current file, and type @kbd{%} to comment out the | |
1079 @code{\includeonly} line. | |
1080 | |
1081 @node What column?, Online help, Updation of @code{\includeonly}, Top | |
1082 @comment node-name, next, previous, up | |
1083 @chapter What column? | |
1084 @cindex what column | |
1085 @cindex complex tabular | |
1086 @cindex prefix & | |
1087 | |
1088 We are often get tired of finding the corresponding column in | |
1089 large tabulars. For example, | |
1090 | |
1091 @example | |
1092 \begin@{tabular@}@{|c|c|c|c|c|c|c|c|@}\hline | |
1093 Name&Position&Post No.&Addr.&Phone No.&FAX No.& | |
1094 Home Addr.&Home Phone\\ \hline | |
1095 Thunder Bird & 6 & 223 & LA & xxx-yyy & | |
1096 zzz-www & Japan & 9876-54321 \\ | |
1097 & 2 & \multicolumn@{2@}@{c|@}@{Unknown@} | |
1098 &&&(???) | |
1099 \\ \hline | |
1100 \end@{tabular@} | |
1101 @end example | |
1102 | |
1103 Suppose you have the cursor located at @code{(???)} mark, can you tell | |
1104 which column it is belonging at once? Maybe no. In such case, | |
1105 type | |
1106 | |
1107 @table @kbd | |
1108 @item [prefix] & | |
1109 @dots{} What column | |
1110 @end table | |
1111 | |
1112 @noindent | |
1113 in that position. YaTeX tells you the column header of the | |
1114 current field. Since YaTeX assumes the first line of tabular | |
1115 environment as a row of column headers, you can create a row of | |
1116 virtual column headers by putting them in the first line and | |
1117 commenting that line with @code{%}. | |
1118 | |
1119 @node Online help, Cooperation with other packages, What column?, Top | |
1120 @comment node-name, next, previous, up | |
1121 @chapter Online help | |
1122 @cindex online help | |
1123 @cindex prefix ? | |
1124 @cindex prefix / | |
1125 @cindex apropos | |
1126 @cindex keyword search | |
1127 | |
1128 YaTeX provides you the online help with popular La@TeX{} commands. | |
1129 | |
1130 Here are the key strokes for the online help. | |
1131 | |
1132 @table @kbd | |
1133 @item [prefix] ? | |
1134 @dots{} Online help | |
1135 @item [prefix] / | |
1136 @dots{} Online apropos | |
1137 @end table | |
1138 | |
1139 @section Online help | |
1140 | |
1141 `Online help' shows the documentation for the popular La@TeX{} | |
1142 commands(defaults to the commands on the cursor) in the next buffer. | |
1143 There are two help file, `global help' and `private help'. The former | |
1144 file contains the descriptions on the standard La@TeX{} command and is | |
1145 specified its name by variable @code{YaTeX-help-file}. Usually, the | |
1146 global help file should be located in public space (@code{$EMACSEXECPATH} | |
1147 by default) and should be world writable so that anyone can update it to | |
1148 enrich its contents. The latter file contains descriptions on | |
1149 non-standard or personal command definitions and is specified by | |
1150 @code{YaTeX-help-file-private}. This file should be put into private | |
1151 directory. | |
1152 | |
1153 @section Online apropos | |
1154 | |
1155 `Online apropos' is an equivalent of GNU Emacs's apropos. It | |
1156 shows all the documentations that contains the keyword entered by | |
1157 the user. | |
1158 | |
1159 @section When no descriptions are found... | |
1160 | |
1161 If there is no description on a command in help files, YaTeX | |
1162 requires you to write a description on that command. If you are | |
1163 willing to do, determine which help file to add and write the | |
1164 description on it referring your manual of (La)TeX. Please send | |
1165 me your additional descriptions if you describe the help on some | |
1166 standard commands. I might want to include it in the next | |
1167 distribution. | |
1168 | |
1169 @node Cooperation with other packages, Customizations, Online help, Top | |
1170 @comment node-name, next, previous, up | |
1171 @chapter Cooperation with other packages | |
1172 | |
1173 YaTeX works better with other brilliant packages. | |
1174 | |
1175 @section gmhist | |
1176 @cindex gmhist | |
1177 @cindex command history | |
1178 @cindex minibuffer history | |
1179 | |
1180 When you are loading @file{gmhist.el} and @file{gmhist-mh.el}, you can | |
1181 use independent command history list at the prompt of preview command | |
1182 (@kbd{[prefix] tp}) and print command (@kbd{[prefix] tl}). On each | |
1183 prompt, you can enter the previous command line string repeatedly by | |
1184 typing @kbd{M-p}. | |
1185 | |
1186 @section min-out | |
1187 @cindex min-out | |
1188 | |
1189 @file{min-out}, the outline minor mode, can be used in yatex-mode | |
1190 buffers. If you want to use it with YaTeX, please refer the | |
1191 file @file{yatexm-o.el} as an example. | |
1192 | |
1193 @node Customizations, Etcetera, Cooperation with other packages, Top | |
1194 @comment node-name, next, previous, up | |
1195 @chapter Customizations | |
1196 @cindex customizations | |
1197 | |
1198 You can customize YaTeX by setting Emacs-Lisp variables and by making | |
1199 add-in functions. | |
1200 | |
1201 @menu | |
1202 * Lisp variables:: | |
1203 * Add-in functions:: | |
1204 @end menu | |
1205 | |
1206 @node Lisp variables, Add-in functions, Customizations, Customizations | |
1207 @comment node-name, next, previous, up | |
1208 @section Lisp variables | |
1209 @cindex customizable variables | |
1210 | |
1211 You can change the key assignments or make completion more | |
1212 comfortable by setting the values of various variables which | |
1213 control the movement of yatex-mode. | |
1214 | |
1215 For example, if you want to change the prefix key stroke from @kbd{C-c} | |
1216 to any other sequence, set YaTeX-prefix to whatever you want to use. If | |
1217 you don't want to use the key sequence @kbd{C-c letter} which is assumed | |
1218 to be the user reserved sequence in Emacs world, set | |
1219 @code{YaTeX-inhibit-prefix-letter} to @code{t}, and all of the default key | |
1220 bind of @kbd{C-c letter} will turn to the corresponding @kbd{C-c C-letter} | |
1221 (but the region based completions that is invoked with @kbd{C-c | |
1222 Capital-letter} remain valid, if you want to disable those bindings, set | |
1223 that variable to 1 instead of @code{t}). | |
1224 | |
1225 @menu | |
1226 * All customizable variables:: | |
1227 * Sample definitions:: | |
1228 * Hook variables:: | |
1229 * Hook file:: | |
1230 @end menu | |
1231 | |
1232 @node All customizable variables, Sample definitions, Lisp variables, Lisp variables | |
1233 @comment node-name, next, previous, up | |
1234 @subsection All customizable variables | |
1235 @cindex all customizable variables | |
1236 | |
1237 Here are the customizable variables of yatex-mode. Each value setq-ed | |
1238 in @file{~/.emacs} is preferred and that of defined in @file{yatex.el} is | |
1239 neglected. Parenthesized contents stands for the default value. | |
1240 | |
1241 @table @samp | |
1242 @item YaTeX-prefix | |
1243 | |
1244 Prefix key stroke (@kbd{C-c}) | |
1245 | |
1246 @item YaTeX-inhibit-prefix-letter | |
1247 | |
1248 Change key stroke from @kbd{C-c letter} to @kbd{C-c C-letter} | |
1249 (@code{nil}) | |
1250 | |
1251 @item YaTeX-fill-prefix | |
1252 | |
1253 Fill-prefix used in yatex-mode (@code{nil}) | |
1254 | |
1255 @item YaTeX-open-lines | |
1256 | |
1257 Number of blank lines between cursor and @code{\begin@{@}}, | |
1258 @code{\@code{end}@{@}} (0) | |
1259 | |
1260 @item YaTeX-user-completion-table | |
1261 | |
1262 Name of user dictionary where learned completion table will be stored. | |
1263 (@code{"~/.yatexrc"}) | |
1264 | |
1265 @item YaTeX-item-regexp | |
1266 | |
1267 Regular expression of item command(@code{"\\\\item"}) | |
1268 | |
1269 @item tex-command | |
1270 | |
1271 La@TeX{} typesetter command (@code{"latex"}) | |
1272 | |
1273 @item dvi2-command | |
1274 | |
1275 Preview command | |
1276 (@code{"xdvi -geo +0+0 -s 4 -display (getenv"DISPLAY")"}) | |
1277 | |
1278 @item dviprint-command-format | |
1279 | |
1280 Command format to print dvi file (@code{"dvi2ps %f %t %s | lpr"}) | |
1281 | |
1282 @item dviprint-from-format | |
1283 | |
1284 Start page format of above %f. %b will turn to start page | |
1285 (@code{"-f %b"}) | |
1286 | |
1287 @item dviprint-to-format | |
1288 | |
1289 End page format of above %t. %e will turn to @code{end} page | |
1290 (@code{"-t %e"}) | |
1291 | |
1292 @item section-name | |
1293 | |
1294 Initial default value at the first section-type completion | |
1295 (@code{"documentstyle"}) | |
1296 | |
1297 @item env-name | |
1298 | |
1299 Initial default value at the first begin-type completion | |
1300 (@code{"document"}) | |
1301 | |
1302 @item fontsize-name | |
1303 | |
1304 Ditto of large-type (@code{"large"}) | |
1305 | |
1306 @item single-command | |
1307 | |
1308 Ditto of maketitle-type (@code{"maketitle"}) | |
1309 | |
1310 @item YaTeX-need-nonstop | |
1311 | |
1312 Put @code{\nonstopmode@{@}} or not (@code{nil}) | |
1313 | |
1314 @item latex-warning-regexp | |
1315 | |
1316 Regular expression of warning message latex command puts out | |
1317 (@code{"line.* [0-9]*"}) | |
1318 | |
1319 @item latex-error-regexp | |
1320 | |
1321 Regular expression of error message (@code{"l\\.[1-9][0-9]*"}) | |
1322 | |
1323 @item latex-dos-emergency-message | |
1324 | |
1325 Message latex command running on DOS puts at abort | |
1326 (@code{"Emergency stop"}) | |
1327 | |
1328 @item YaTeX-item-regexp | |
1329 | |
1330 Regexp of La@TeX{} itemization command (@code{"\\\\(sub\\)*item"}) | |
1331 | |
1332 @item YaTeX-nervous | |
1333 | |
1334 T for using local dictionary (@code{t}) | |
1335 | |
1336 @item YaTeX-sectioning-regexp | |
1337 | |
1338 Regexp of La@TeX{} sectioning command | |
1339 | |
1340 (@code{"part\\|chapter\\|\\(sub\\)*\\(section\\|paragraph\\)"}) | |
1341 | |
1342 @item YaTeX-fill-inhibit-environments | |
1343 | |
1344 Inhibit fill in these environments (@code{'("verbatim" "tabular")}) | |
1345 | |
1346 @item YaTeX-uncomment-once | |
1347 | |
1348 @code{T} for deleting all preceding @code{%} (@code{nil}) | |
1349 | |
1350 @item YaTeX-close-paren-always | |
1351 | |
1352 @code{T} for always close all parenthesis automatically, | |
1353 @code{nil} for only eol(@code{t}) | |
1354 | |
1355 @item YaTeX-auto-math-mode | |
1356 | |
1357 Switch math-mode automatically(@code{t}) | |
1358 | |
1359 @item YaTeX-default-pop-window-height | |
1360 | |
1361 Initial height of typesetting buffer when one-window. | |
1362 Number for the lines of the buffer, numerical string for | |
1363 the percentage of the screen-height. | |
1364 @code{nil} for half height(10) | |
1365 | |
1366 @item YaTeX-help-file | |
1367 | |
1368 Global online help file name (@file{$EMACS/etc/YATEXHLP.jp}) | |
1369 | |
1370 @item YaTeX-help-file-private | |
1371 | |
1372 Private online help file name (@file{"~/YATEXHLP.jp"}) | |
1373 | |
1374 @item YaTeX-no-begend-shortcut | |
1375 | |
1376 Disable [prefix] b ?? shortcut (@code{nil)} | |
1377 @end table | |
1378 | |
1379 @node Sample definitions, Hook variables, All customizable variables, Lisp variables | |
1380 @comment node-name, next, previous, up | |
1381 @subsection Sample definitions | |
1382 @cindex prefix key stroke | |
1383 @cindex fill-prefix | |
1384 | |
1385 For instance, to change the prefix key stroke to @kbd{ESC}, and name of | |
1386 the user dictionary @file{~/src/emacs/yatexrc}, and set @code{fill-prefix} | |
1387 to single TAB character, add the following @code{setq} to @file{~/.emacs}. | |
1388 | |
1389 @lisp | |
1390 (setq YaTeX-prefix "\e" | |
1391 YaTeX-user-completion-table "~/src/emacs/yatexrc" | |
1392 YaTeX-fill-prefix " ") | |
1393 @end lisp | |
1394 | |
1395 @node Hook variables, Hook file, Sample definitions, Lisp variables | |
1396 @comment node-name, next, previous, up | |
1397 @subsection Hook variables | |
1398 @cindex hook variables | |
1399 | |
1400 More customizations will be done by the hook-function defined in | |
1401 hook-variable @code{yatex-mode-hook}. This is useful to define a shortcut | |
1402 key sequence to enter some environments other than @code{document} and | |
1403 @code{enumerate} etc. The following statement defines @code{[prefix] ba} | |
1404 to enter @code{\begin@{abstract@}} ... @code{=end@{abstract@}} | |
1405 immediately. | |
1406 | |
1407 @lisp | |
1408 (setq yatex-mode-hook | |
1409 '(lambda() (YaTeX-define-begend-key "ba" "abstract"))) | |
1410 @end lisp | |
1411 | |
1412 You should use functions @code{YaTeX-define-key}, or | |
1413 @code{YaTeX-define-begend-key} to define all the key sequences of | |
1414 yatex-mode. | |
1415 | |
1416 @node Hook file, , Hook variables, Lisp variables | |
1417 @comment node-name, next, previous, up | |
1418 @subsection Hook file | |
1419 @cindex hook file | |
1420 | |
1421 You can stuff all of YaTeX relating expressions into a file named | |
1422 @file{yatexhks.el} if you have a lot of codes. YaTeX automatically load | |
1423 this file at the initialization of itself. Using @file{yatexhks.el} | |
1424 makes @code{yatex-mode-load-hook} unnecessary. | |
1425 | |
1426 @node Add-in functions, , Lisp variables, Customizations | |
1427 @comment node-name, next, previous, up | |
1428 @section Add-in functions | |
1429 @cindex add-in functions | |
1430 | |
1431 You can easily define a function to input detailed arguments | |
1432 with completion according to La@TeX{} environments or commands. To | |
1433 know the way to define these functions, see also @file{yatexadd.doc} in | |
1434 this package please. | |
1435 | |
1436 | |
1437 @node Etcetera, Copying, Customizations, Top | |
1438 @comment node-name, next, previous, up | |
1439 @chapter Etcetera | |
1440 | |
1441 The standard completion tables provided in @file{yatex.el} contain a | |
1442 few La@TeX{} commands I frequently use. This is to lessen the key | |
1443 strokes to complete entire word, because too many candidates | |
1444 rarely used often cause too many hits. Therefore always try to | |
1445 use completion in order to enrich your dictionary, and you will | |
1446 also find `Wild Bird' growing suitable for your La@TeX{} style. | |
1447 | |
1448 | |
1449 @node Copying, , Etcetera, Top | |
1450 @comment node-name, next, previous, up | |
1451 @chapter Copying | |
1452 | |
1453 This program is distributed as a free software. You can | |
1454 redistribute this software freely but with NO warranty to anything | |
1455 as a result of using this software. However, any reports and | |
1456 suggestions are welcome as long as I feel interests in this | |
1457 software. My possible e-mail address is `yuuji@@ae.keio.ac.jp'. | |
1458 (up to Mar.1993 at least) | |
1459 | |
1460 The specification of this software will be surely modified | |
1461 (depending on my feelings) without notice :-p. | |
1462 | |
1463 | |
1464 @flushright | |
1465 HIROSE Yuuji | |
1466 @end flushright | |
1467 @bye | |
1468 | |
1469 Local variables: | |
1470 mode: texinfo | |
1471 fill-prefix: nil | |
1472 fill-column: 74 | |
1473 End: |