Mercurial > hgrepos > hgweb.cgi > yatex
annotate docs/yatexe.tex @ 69:807c1e7e68b7
yahtml-escape-chars-region
Translate <>"& to entity reference.
And inverse translation to above.
yahtml-translate-hyphens-when-comment-region
yahtml-prefer-upcase-attributes
Inquire .htaccess file to determine the file-coding-system.
Completions for StyleSheet.
---yahtml---
Auto insert of \), \|, \] after corresponding \(, \| \].
[prefix] c for \right\left parens.
author | yuuji |
---|---|
date | Thu, 15 Jul 1999 04:58:26 +0000 |
parents | 0eb6997bee16 |
children | 44e3a5e1e883 |
rev | line source |
---|---|
46 | 1 \def\lang{jp} % -*- texinfo -*- |
20 | 2 \input texinfo.tex |
3 @setfilename yatexe | |
4 @settitle Yet Another tex-mode for Emacs | |
5 | |
6 @iftex | |
46 | 7 @c @syncodeindex fn cp |
20 | 8 @syncodeindex vr cp |
9 @end iftex | |
10 | |
11 @titlepage | |
12 @sp 10 | |
13 @center | |
14 @subtitle Yet Another tex-mode for emacs | |
15 @title Wild Bird | |
16 @subtitle // YaTeX // | |
69 | 17 @author @copyright{} 1991-1996 by HIROSE, Yuuji [yuuji@@gentei.org] |
20 | 18 @end titlepage |
19 | |
20 @node Top, What is YaTeX?, (dir), (dir) | |
21 @comment node-name, next, previous, up | |
22 @cindex Demacs | |
23 @cindex Mule | |
24 @cindex LaTeX | |
25 @cindex YaTeX | |
26 | |
27 @menu | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
28 * What is YaTeX?:: |
51 | 29 * Main features:: What YaTeX can do |
30 * Installation:: Guide to install | |
31 * Typesetting:: Call typesetting processes | |
68 | 32 * %#notation:: |
51 | 33 * Completion:: Input LaTeX commands with completion |
34 * Local dictionaries:: Directory dependent completion | |
35 * Commenting out:: Commenting/uncommenting text | |
36 * Cursor jump:: Jumping to related position | |
37 * Changing and Deleting:: Changing/deleting certain unit of text | |
38 * Filling:: Filling an item or paragraph | |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
39 * Updation of includeonly:: Free from maintaining includeonly |
59 | 40 * What column:: Check what table-column the cursor belong |
51 | 41 * Intelligent newline:: Guess requisites of new line |
42 * Online help:: On-line documentation of LaTeX | |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
43 * Browsing file hierarchy:: Walking through file hierarchy |
51 | 44 * Cooperation with other packages:: Work well with gmhist, min-out |
45 * Customizations:: How to breed `Wild Bird' | |
46 * Etcetera:: YaTeX is acquisitive. | |
47 * Copying:: Redistribution | |
20 | 48 |
49 --- The Detailed Node Listing --- | |
50 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
51 Typesetting |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
52 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
53 * Calling typesetter:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
54 * Calling previewer:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
55 * Printing out:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
56 |
20 | 57 %# notation |
58 | |
59 * Changing typesetter:: | |
60 * Static region for typesetting:: | |
61 * Lpr format:: | |
62 * Editing %# notation:: | |
63 | |
64 Completion | |
65 | |
66 * Begin-type completion:: | |
67 * Section-type completion:: | |
68 * Large-type completion:: | |
69 * Maketitle-type completion:: | |
70 * Arbitrary completion:: | |
71 * End completion:: | |
72 * Accent completion:: | |
73 * Image completion:: | |
74 * Greek letters completion:: | |
75 | |
76 Section-type completion | |
77 | |
78 * view-sectioning:: | |
79 | |
68 | 80 Cursor jump |
81 | |
82 * Jump to corresponding object:: | |
83 * Invoking image processor:: | |
84 * Jump to main file:: | |
85 * Jumping around the environment:: | |
86 * Jumping to last completion position:: | |
87 | |
49 | 88 Changing and Deleting |
89 | |
68 | 90 * Changing LaTeX commands:: |
91 * Killing LaTeX commands:: | |
49 | 92 |
20 | 93 Customizations |
94 | |
95 * Lisp variables:: | |
96 * Add-in functions:: | |
49 | 97 * Add-in generator:: |
20 | 98 |
99 Lisp variables | |
100 | |
101 * All customizable variables:: | |
102 * Sample definitions:: | |
103 * Hook variables:: | |
104 * Hook file:: | |
49 | 105 |
106 Procedure | |
107 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
108 * How the add-in function works:: |
49 | 109 * How the function is called:: |
110 * Useful functions for creating add-in:: | |
111 * Contribution:: | |
112 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
113 How the add-in function works |
49 | 114 |
68 | 115 * Defining option-add-in:: |
116 * Defining argument-add-in:: | |
20 | 117 @end menu |
118 | |
119 @node What is YaTeX?, Main features, Top, Top | |
120 @comment node-name, next, previous, up | |
121 @chapter What is YaTeX? | |
122 | |
123 YaTeX automates typesetting and previewing of LaTeX and enables | |
124 completing input of LaTeX mark-up command such as | |
125 @code{\begin@{@}}..@code{\end@{@}}. | |
126 | |
127 YaTeX also supports Demacs which runs on MS-DOS(386), Mule (Multi | |
128 Language Enhancement to GNU Emacs), and latex on DOS. | |
129 | |
130 @node Main features, Installation, What is YaTeX?, Top | |
131 @comment node-name, next, previous, up | |
132 @chapter Main features | |
133 | |
134 @itemize | |
46 | 135 @item Invocation of typesetter, previewer and related programs(@kbd{C-c t}) |
20 | 136 @item Typesetting on static region which is independent from point |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
137 @item Semiautomatic replacing of @code{\includeonly} |
20 | 138 @item Jumping to error line(@kbd{C-c '}) |
139 @item Completing-read of La@TeX{} commands such as @code{\begin@{@}}, | |
140 @code{\section} etc. | |
141 (@kbd{C-c b}, @kbd{C-c s}, @kbd{C-c l}, @kbd{C-c m}) | |
142 @item Enclosing text into La@TeX{} environments or commands | |
143 (@kbd{C-u} @var{AboveKeyStrokes}) | |
59 | 144 @item Displaying the structure of text at entering sectioning commands |
145 @item Lump shifting of sectioning commands (@ref{view-sectioning}) | |
20 | 146 @item Learning unknown/new La@TeX{} commands for the next completion |
147 @item Argument reading with a guide for complicated La@TeX{} commands | |
148 @item Generating argument-readers for new/unsupported commands(@file{yatexgen}) | |
149 @item Quick changing or deleting of La@TeX{} commands(@kbd{C-c c}, @kbd{C-c k}) | |
150 @item Jumping from and to inter-file, begin<->end, ref<->label(@kbd{C-c g}) | |
151 @item Blanket commenting out or uncommenting | |
152 (@kbd{C-c >}, @kbd{C-c <}, @kbd{C-c ,}, @kbd{C-c .}) | |
153 @item Easy input of accent mark, math-mode's commands and Greek letters | |
52 | 154 (@kbd{C-c a}, @kbd{;}, @kbd{:}) |
20 | 155 @item Online help for the popular La@TeX{} commands |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
156 (@kbd{C-c ?}, @kbd{C-c /}) |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
157 @item Document files hierarchy browser (@kbd{C-c d}) |
20 | 158 @end itemize |
159 | |
160 @node Installation, Typesetting, Main features, Top | |
161 @comment node-name, next, previous, up | |
162 @chapter Installation | |
163 @cindex installation | |
164 @cindex .emacs | |
165 @cindex auto-mode-alist | |
166 @cindex autoload | |
167 | |
168 Put next two expressions into your @file{~/.emacs}. | |
169 | |
170 @lisp | |
171 (setq auto-mode-alist | |
46 | 172 (cons (cons "\\.tex$" 'yatex-mode) auto-mode-alist)) |
20 | 173 (autoload 'yatex-mode "yatex" "Yet Another La@TeX{} mode" t) |
174 @end lisp | |
175 | |
176 Next, add certain path name where you put files of YaTeX to your | |
177 load-path. If you want to put them in @file{~/src/emacs}, write | |
178 | |
179 @lisp | |
180 (setq load-path | |
181 (cons (expand-file-name "~/src/emacs") load-path)) | |
182 @end lisp | |
183 | |
184 @noindent | |
185 in your @file{~/.emacs} | |
186 | |
187 Then, yatex-mode will be automatically loaded when you visit a | |
188 file which has extension @file{.tex}. If yatex-mode is successfully | |
189 loaded, mode string on mode line will be turned to "YaTeX". | |
190 | |
191 | |
68 | 192 @node Typesetting, %#notation, Installation, Top |
20 | 193 @comment node-name, next, previous, up |
194 @chapter Typesetting | |
195 @cindex typesetting | |
196 @cindex previewer | |
197 @cindex typesetter | |
198 @cindex latex | |
199 @cindex printing out | |
200 | |
201 The prefix key stroke of yatex-mode is @kbd{C-c} (Press 'C' with Control | |
202 key) by default. If you don't intend to change the prefix key stroke, | |
203 assume all @kbd{[prefix]} as @kbd{C-c} in this document. These key | |
204 strokes execute typeset or preview command. | |
205 | |
206 @table @kbd | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
207 @item [prefix] t j |
46 | 208 @dots{} invoke latex |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
209 @item [prefix] t r |
46 | 210 @dots{} invoke latex on region |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
211 @item [prefix] t k |
46 | 212 @dots{} kill current typesetting process |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
213 @item [prefix] t b |
46 | 214 @dots{} invoke bibtex |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
215 @item [prefix] t p |
46 | 216 @dots{} preview |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
217 @item [prefix] t l |
46 | 218 @dots{} lpr dvi-file |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
219 @item [prefix] t s |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
220 @dots{} search current string on xdvi-remote |
20 | 221 @end table |
222 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
223 @menu |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
224 * Calling typesetter:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
225 * Calling previewer:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
226 * Printing out:: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
227 @end menu |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
228 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
229 @node Calling typesetter, Calling previewer, Typesetting, Typesetting |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
230 @comment node-name, next, previous, up |
68 | 231 @section Calling typesetter |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
232 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
233 Typing @kbd{[prefix] t j}, the current editing window will be divided |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
234 horizontally when you invoke latex command, and log message of La@TeX{} |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
235 typesetting will be displayed in the other window; called typesetting |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
236 buffer. The typesetting buffer automatically scrolls up and traces |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
237 La@TeX{} warnings and error messages. If you see latex stopping by an |
20 | 238 error, you can send string to latex in the typesetting buffer. |
239 | |
240 If an error stops the La@TeX{} typesetting, this key stroke will | |
241 move the cursor to the line where La@TeX{} error is detected. | |
242 | |
243 @table @kbd | |
244 @item [prefix] ' | |
245 @itemx ([prefix]+single quotation) | |
246 | |
46 | 247 @dots{} jump to the previous error or warning |
20 | 248 @end table |
249 | |
250 If you find a noticeable error, move to the typesetting buffer and move | |
251 the cursor on the line of error message and type @kbd{SPACE} key. This | |
252 makes the cursor move to corresponding source line. | |
253 | |
254 Since @kbd{[prefix] tr} pastes the region into the file | |
255 @file{texput.tex} in the current directory, you should be careful of | |
256 overwriting. The method of specification of the region is shown in the | |
68 | 257 section @xref{%#notation}. |
20 | 258 |
259 The documentstyle for typeset-region is the same as that of editing | |
260 file if you edit one file, and is the same as main file's if you | |
261 edit splitting files. | |
262 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
263 @node Calling previewer, Printing out, Calling typesetter, Typesetting |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
264 @comment node-name, next, previous, up |
68 | 265 @section Calling previewer |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
266 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
267 @kbd{[prefix] t p} invokes the TeX previewer. And if you are using |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
268 xdvi-remote, which can be controled from other terminals, @kbd{[prefix] t |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
269 s} enables you to search current string at the cursor on the running xdvi |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
270 window. You can get xdvi with `-remote feature' from; |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
271 @code{ftp://ftp.ae.keio.ac.jp/pub/text/xdvi/xdvi-remote}. |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
272 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
273 @node Printing out, , Calling previewer, Typesetting |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
274 @comment node-name, next, previous, up |
68 | 275 @section Printing out |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
276 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
277 When you type @code{[preifx] t l}, YaTeX asks you the range of |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
278 dvi-printing by default. You can skip this by invoking it with |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
279 universal-argument as follows: |
20 | 280 |
281 @example | |
49 | 282 C-u [prefix] tl |
20 | 283 @end example |
284 | |
68 | 285 @node %#notation, Completion, Typesetting, Top |
20 | 286 @comment node-name, next, previous, up |
287 @chapter %# notation | |
288 @cindex %# notation | |
289 | |
290 You can control the typesetting process by describing @code{%#} | |
291 notations in the source text. | |
292 | |
293 @menu | |
294 * Changing typesetter:: | |
295 * Static region for typesetting:: | |
296 * Lpr format:: | |
297 * Editing %# notation:: | |
298 @end menu | |
299 | |
68 | 300 @node Changing typesetter, Static region for typesetting, %#notation, %#notation |
20 | 301 @comment node-name, next, previous, up |
302 @section To change the `latex' command or to split a source text. | |
303 @cindex typesetter | |
304 | |
305 To change the typesetting command, write | |
306 | |
307 @example | |
46 | 308 %#!latex-big |
20 | 309 @end example |
310 | |
311 @noindent | |
51 | 312 anywhere in the source text. This is useful for changing |
313 typesetter. | |
314 | |
68 | 315 @node Splitting input files, Static region for typesetting, Changing typesetter, %#notation |
51 | 316 @comment node-name, next, previous, up |
317 | |
318 And if you split the source text and | |
20 | 319 edit subfile that should be included from main text. |
320 | |
321 @example | |
46 | 322 %#!latex main.tex |
20 | 323 @end example |
324 | |
325 @noindent | |
326 will be helpful to execute latex on main file from sub text buffer. Since | |
327 this command line after @kbd{%#!} will be sent to shell literally, next | |
328 description makes it convenient to use ghostview as dvi-previewer. | |
329 | |
330 @example | |
46 | 331 %#!latex main ; dvi2ps main.dvi > main |
20 | 332 @end example |
333 | |
334 @noindent | |
335 Note that YaTeX assumes the component before the last period of | |
336 the last word in this line as base name of the main La@TeX{} source. | |
337 | |
51 | 338 To make best use of the feature of inter-file jumping by |
339 @kbd{[prefix] g} (see @ref{Cursor jump}), take described below into | |
340 consideration. | |
20 | 341 |
342 @itemize | |
343 @item You can put split texts in sub directory, but not in | |
344 sub directory of sub directory. | |
51 | 345 @item In the main text, specify the child file name with relative path name |
20 | 346 such as \include{chap1/sub}, when you include the file in |
347 a sub-directory. | |
348 @item In a sub-text, write @code{%#!latex main.tex} even if @file{main.tex} | |
349 is in the parent directory(not %#!latex ../main.tex). | |
350 @end itemize | |
351 | |
68 | 352 @node Static region for typesetting, Lpr format, Changing typesetter, %#notation |
20 | 353 @comment node-name, next, previous, up |
354 @section Static region | |
355 @cindex static region | |
356 @cindex Fixed region | |
357 | |
358 Typeset-region by @kbd{[prefix] tr} passes the region between point and | |
359 mark to typesetting command by default. But when you want to typeset | |
360 static region, enclose the region by @code{%#BEGIN} and @code{%#END} as | |
361 follows. | |
362 | |
363 @example | |
46 | 364 %#BEGIN |
365 TheRegionYouWantToTypesetManyTimes | |
366 %#END | |
20 | 367 @end example |
368 | |
369 This is the rule of deciding the region. | |
370 | |
371 @enumerate | |
372 @item | |
373 If there exists %#BEGIN before point, | |
374 | |
375 @enumerate | |
376 @item | |
377 If there exists %#END after %#BEGIN, | |
378 @itemize | |
379 @item From %#BEGIN to %#END. | |
380 @end itemize | |
381 | |
382 @item | |
383 If %#END does not exist after %#BEGIN, | |
384 @itemize | |
385 @item From %#BEGIN to the end of buffer. | |
386 @end itemize | |
387 @end enumerate | |
388 | |
389 @item | |
390 If there does not exist %#BEGIN before point, | |
391 @itemize | |
392 @item Between point and mark(standard method of Emacs). | |
393 @end itemize | |
394 @end enumerate | |
395 | |
396 It is useful to write @code{%#BEGIN} in the previous line of \begin and | |
397 @code{%#END} in the next line of \@code{end} when you try complex | |
398 environment such as `tabular' many times. It is also useful to put only | |
399 @code{%#BEGIN} alone at the middle of very long text. Do not forget to | |
400 erase @code{%#BEGIN} @code{%#END} pair. | |
401 | |
68 | 402 @node Lpr format, Editing %# notation, Static region for typesetting, %#notation |
20 | 403 @comment node-name, next, previous, up |
404 @section Lpr format | |
405 @cindex lpr format | |
406 | |
407 Lpr format is specified by three Lisp variables. Here are the | |
408 default values of them. | |
409 | |
410 @table @code | |
411 @item (1)dviprint-command-format | |
46 | 412 @code{"dvi2ps %f %t %s | lpr"} |
20 | 413 @item (2)dviprint-from-format |
46 | 414 @code{"-f %b"} |
20 | 415 @item (3)dviprint-to-format |
46 | 416 @code{"-t %e"} |
20 | 417 @end table |
418 | |
419 On YaTeX-lpr, @code{%s} in (1) is replaced by the file name of main | |
420 text, @code{%f} by contents of (2), %t by contents of (3). At these | |
421 replacements, @code{%b} in (2) is also replaced by the number of beginning | |
422 page, @code{%e} in (3) is replaced by the number of ending page. But | |
423 @code{%f} and @code{%t} are ignored when you omit the range of print-out | |
424 by @kbd{C-u [prefix] tl}. | |
425 | |
426 If you want to change this lpr format temporarily, put a command | |
427 such as follows somewhere in the text: | |
428 | |
429 @example | |
46 | 430 %#LPR dvi2ps %f %t %s | 4up -page 4 | texfix | lpr -Plp2 |
20 | 431 @end example |
432 | |
433 And if you want YaTeX not to ask you the range of printing | |
434 out, the next example may be helpful. | |
435 | |
436 @example | |
46 | 437 %#LPR dvi2ps %s | lpr |
20 | 438 @end example |
439 | |
68 | 440 @node Editing %# notation, , Lpr format, %#notation |
20 | 441 @comment node-name, next, previous, up |
442 @section Editing %# notation | |
443 | |
444 To edit @code{%#} notation described above, type | |
445 | |
446 @table @kbd | |
447 @item [prefix] % | |
46 | 448 @dots{} editing %# notation menu |
20 | 449 @end table |
450 | |
451 @noindent | |
452 and select one of the entry of the menu as follows. | |
453 | |
454 @example | |
46 | 455 !)Edit-%#! B)EGIN-END-region L)Edit-%#LPR |
20 | 456 @end example |
457 | |
458 @noindent | |
459 Type @kbd{!} to edit @code{%#!} entry, @code{b} to enclose the region with | |
460 @code{%#BEGIN} and @code{%#END}, and @code{l} to edit @code{%#LPR} entry. | |
461 When you type @kbd{b}, all @code{%#BEGIN} and @code{%#END} are | |
462 automatically erased. | |
463 | |
68 | 464 @node Completion, Local dictionaries, %#notation, Top |
20 | 465 @comment node-name, next, previous, up |
466 @chapter Completion | |
467 @cindex completion | |
468 | |
469 YaTeX makes it easy to input the La@TeX{} commands. There are several | |
470 kinds of completion type, begin-type, section-type, large-type, etc... | |
471 | |
472 @menu | |
473 * Begin-type completion:: | |
474 * Section-type completion:: | |
475 * Large-type completion:: | |
476 * Maketitle-type completion:: | |
477 * Arbitrary completion:: | |
478 * End completion:: | |
479 * Accent completion:: | |
480 * Image completion:: | |
481 * Greek letters completion:: | |
482 @end menu | |
483 | |
33 | 484 @node Begin-type completion, Section-type completion, Completion, Completion |
20 | 485 @comment node-name, next, previous, up |
486 @section Begin-type completion | |
487 @cindex begin-type completion | |
488 @cindex environment | |
489 @cindex prefix b | |
490 | |
491 "Begin-type completion" completes commands of @code{\begin@{env@}} ... | |
492 @code{\end@{env@}}. All of the begin-type completions begin with this key | |
493 sequence. | |
494 | |
495 @table @kbd | |
496 @item [prefix] b | |
46 | 497 @dots{} start begin-type completion |
20 | 498 @end table |
499 | |
500 @noindent | |
501 An additional key stroke immediately completes a frequently used | |
502 La@TeX{} @code{\begin@{@}}...@code{\@code{end}@{@}} environment. | |
503 | |
504 @table @kbd | |
505 @item [prefix] b c | |
46 | 506 @dots{} @code{\begin@{center@}...\end@{center@}} |
20 | 507 @item [prefix] b d |
46 | 508 @dots{} @code{\begin@{document@}...\end@{document@}} |
20 | 509 @item [prefix] b D |
46 | 510 @dots{} @code{\begin@{description@}...\end@{description@}} |
20 | 511 @item [prefix] b e |
46 | 512 @dots{} @code{\begin@{enumerate@}...\end@{enumerate@}} |
20 | 513 @item [prefix] b E |
46 | 514 @dots{} @code{\begin@{equation@}...\end@{equation@}} |
20 | 515 @item [prefix] b i |
46 | 516 @dots{} @code{\begin@{itemize@}...\end@{itemize@}} |
20 | 517 @item [prefix] b l |
46 | 518 @dots{} @code{\begin@{flushleft@}...\end@{flushleft@}} |
20 | 519 @item [prefix] b m |
46 | 520 @dots{} @code{\begin@{minipage@}...\end@{minipage@}} |
20 | 521 @item [prefix] b t |
46 | 522 @dots{} @code{\begin@{tabbing@}...\end@{tabbing@}} |
20 | 523 @item [prefix] b T |
46 | 524 @dots{} @code{\begin@{tabular@}...\end@{tabular@}} |
20 | 525 @item [prefix] b^T |
46 | 526 @dots{} @code{\begin@{table@}...\end@{table@}} |
20 | 527 @item [prefix] b p |
46 | 528 @dots{} @code{\begin@{picture@}...\end@{picture@}} |
20 | 529 @item [prefix] b q |
46 | 530 @dots{} @code{\begin@{quote@}...\end@{quote@}} |
20 | 531 @item [prefix] b Q |
46 | 532 @dots{} @code{\begin@{quotation@}...\end@{quotation@}} |
20 | 533 @item [prefix] b r |
46 | 534 @dots{} @code{\begin@{flushright@}...\end@{flushright@}} |
20 | 535 @item [prefix] b v |
46 | 536 @dots{} @code{\begin@{verbatim@}...\end@{verbatim@}} |
20 | 537 @item [prefix] b V |
46 | 538 @dots{} @code{\begin@{verse@}...\end@{verse@}} |
20 | 539 @end table |
540 | |
541 Any other La@TeX{} environments are made by completing-read of the | |
542 Emacs function. | |
543 | |
544 @table @kbd | |
545 @item [prefix] b SPACE | |
46 | 546 @dots{} begin-type completion |
20 | 547 @end table |
548 | |
549 @noindent | |
550 The next message will show up in the minibuffer | |
551 | |
552 @example | |
46 | 553 Begin environment(default document): |
20 | 554 @end example |
555 | |
556 @noindent | |
557 by typing @kbd{[prefix] b}. Put the wishing environment with completion | |
558 in the minibuffer, and @code{\begin@{env@}}...\@code{\end@{env@}} will be | |
559 inserted in the La@TeX{} source text. If the environment you want to put | |
560 does not exist in the YaTeX completion table, it will be registered in the | |
561 user completion table. YaTeX automatically saves the user completion | |
562 table in the user dictionary file at exiting of emacs. | |
563 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
564 At the completion of certain environments, the expected initial entry will |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
565 automatically inserted such as @code{\item} for @code{itemize} |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
566 environment. If you don't want the entry, it can be removed by undoing. |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
567 |
20 | 568 If you want to enclose some paragraphs which have already been |
569 written, invoke the begin-type completion with changing the case | |
570 of @kbd{b} of key sequence upper(or invoke it with universal argument | |
571 by @kbd{C-u} prefix). | |
572 @cindex enclose region into environment | |
573 | |
574 The following example encloses a region with `description' | |
575 environment. | |
576 | |
577 @table @kbd | |
578 @item [prefix] B D | |
579 @itemx (or ESC 1 [prefix] b D) | |
580 @itemx (or C-u [prefix] b D) | |
581 | |
46 | 582 @dots{} begin-type completion for region |
20 | 583 @end table |
584 | |
585 This enclosing holds good for the completing input by @kbd{[prefix] b | |
586 SPC}. @kbd{[prefix] B SPC} enclose a region with the environment selected | |
587 by completing-read. | |
588 | |
589 @node Section-type completion, Large-type completion, Begin-type completion, Completion | |
590 @comment node-name, next, previous, up | |
591 @section Section-type completion | |
592 @cindex section-type completion | |
593 @cindex prefix s | |
594 | |
595 "Section-type completion" completes section-type commands which take an | |
596 argument or more such as @code{\section@{foo@}}. To invoke section-type | |
597 completion, type | |
598 | |
599 @table @kbd | |
600 @item [prefix] s | |
46 | 601 @dots{} section-type completion |
20 | 602 @end table |
603 | |
604 @noindent | |
605 then the prompt | |
606 | |
607 @example | |
46 | 608 (C-v for view) \???@{@} (default documentstyle): |
20 | 609 @end example |
610 | |
611 @noindent | |
612 will show up in the minibuffer. Section-type La@TeX{} commands are | |
613 completed by space key, and the default value is selected when you | |
614 type nothing in the minibuffer. | |
615 | |
616 Next, | |
617 | |
618 @example | |
46 | 619 \section@{???@}: |
20 | 620 @end example |
621 | |
622 @noindent | |
623 prompts you the argument of section-type La@TeX{} command. For | |
624 example, the following inputs | |
625 | |
626 @example | |
46 | 627 \???@{@} (default documentstyle): section |
628 \section{???}: Hello world. | |
20 | 629 @end example |
630 | |
631 @noindent | |
632 will insert the string | |
633 | |
634 @example | |
46 | 635 \section@{Hello world.@} |
20 | 636 @end example |
637 | |
638 in your La@TeX{} source. When you neglect argument such as | |
639 | |
640 @example | |
46 | 641 (C-v for view) \???@{@} (default section): vspace* |
642 \vspace*@{???@}: | |
20 | 643 @end example |
644 | |
645 YaTeX puts | |
646 | |
647 @example | |
46 | 648 \vspace*@{@} |
20 | 649 @end example |
650 | |
651 @noindent | |
652 and move the cursor in the braces. | |
653 | |
654 In La@TeX{} command, there are commands which take more than one | |
655 arguments such as @code{\addtolength{\topmargin}{8mm}}. To complete these | |
656 commands, invoke section-type completion with universal argument as, | |
657 @cindex number of argument | |
658 | |
659 @example | |
49 | 660 C-u 2 [prefix] s (or ESC 2 [prefix] s) |
20 | 661 @end example |
662 | |
663 @noindent | |
664 and make answers in minibuffer like this. | |
665 | |
666 @example | |
46 | 667 (C-v for view) \???@{@} (default vspace*): addtolength |
668 \addtolength@{???@}: \topmargin | |
669 Argument 2: 8mm | |
20 | 670 @end example |
671 | |
672 @code{\addtolength} and the first argument @code{\topmargin} can be typed | |
673 easily by completing read. Since YaTeX also learns the number of | |
674 arguments of section-type command and will ask that many arguments in | |
675 future completion, you had better tell the number of arguments to YaTeX at | |
676 the first completion of the new word. But you can change the number of | |
677 arguments by calling the completion with different universal argument | |
678 again. | |
679 | |
680 | |
681 Invoking section-type completion with @code{[Prefix] S} (Capital `S') | |
682 includes the region as the first argument of section-type command. | |
683 | |
684 The section/large/maketitle type completion can work at the | |
685 prompt for the argument of other section-type completion. | |
686 Nested La@TeX{} commands are efficiently read with the recursive | |
687 completion by typing YaTeX's completion key sequence in the | |
688 minibuffer. | |
689 | |
690 @menu | |
691 * view-sectioning:: | |
692 @end menu | |
693 | |
33 | 694 @node view-sectioning, , Section-type completion, Section-type completion |
20 | 695 @comment node-name, next, previous, up |
696 @subsection view-sectioning | |
697 @cindex view sectioning | |
698 @cindex outline | |
699 | |
700 In the minibuffer at the prompt of section-type command completion, | |
701 typing @kbd{C-v} shows a list of sectioning commands in source text(The | |
702 line with @code{<<--} mark is the nearest sectioning command). Then, | |
703 default sectioning command appears in the minibuffer. You can go up/down | |
704 sectioning command by typing @kbd{C-p}/@kbd{C-n}, can scrolls up/down the | |
705 listing buffer by @kbd{C-v}/@kbd{M-v}, and can hide sectioning commands | |
706 under certain level by 0 through 6. Type @kbd{?} in the minibuffer of | |
707 sectioning prompt for more information. | |
708 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
709 You can generate this listing buffer (@code{*Sectioning Lines*} buffer) |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
710 by typing |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
711 @table @kbd |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
712 @item M-x YaTeX-section-overview |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
713 @dots{} Generate *Sectioning Lines* buffer |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
714 @end table |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
715 @cindex{Generate the listing of sectioning units} |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
716 from the LaTeX source buffer. In this listing buffer, typing @kbd{u} on |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
717 the sectioning command shifts up the corresponding sectioning command in |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
718 source text and @kbd{d} shifts down. After marking lines in the listing |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
719 buffer, typing @kbd{U} shifts up all sectioning commands in the region, |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
720 and @kbd{U} shifts down. Here are all the key bindings of |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
721 @code{*Sectioning Lines*} buffer. |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
722 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
723 @table @kbd |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
724 @item SPC |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
725 @dots{} Jump to corresponding source line |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
726 @item . |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
727 @dots{} Display corresponding source line |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
728 @item u |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
729 @dots{} Shift up a sectioning line |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
730 @item d |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
731 @dots{} Shift down a sectioning line |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
732 @item U |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
733 @dots{} Shift up sectioning lines in region |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
734 @item D |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
735 @dots{} Shift down sectioning lines in region |
68 | 736 @item 0@dots{}6 |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
737 @dots{} Hide sectioning commands whose level is lower than n |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
738 @end table |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
739 |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
740 |
20 | 741 @node Large-type completion, Maketitle-type completion, Section-type completion, Completion |
742 @comment node-name, next, previous, up | |
743 @section Large-type completion | |
744 | |
745 "Large-type completion" inputs the font or size changing | |
746 descriptions such as @code{@{\large @}}. When you type | |
747 | |
748 @table @kbd | |
749 @item [prefix] l | |
46 | 750 @dots{} large-type completion |
20 | 751 @end table |
752 | |
753 @noindent | |
754 the message in the minibuffer | |
755 | |
756 @example | |
46 | 757 @{\??? @} (default large): |
20 | 758 @end example |
759 | |
760 prompts prompts you large-type command with completing-read. There are | |
761 TeX commands to change fonts or sizes, @code{it}, @code{huge} and so on, | |
762 in the completion table. | |
763 | |
764 Region-based completion is also invoked by changing the letter after | |
765 prefix key stroke as @kbd{[prefix] L}. It encloses the region by braces | |
766 with large-type command. | |
767 | |
768 @node Maketitle-type completion, Arbitrary completion, Large-type completion, Completion | |
769 @comment node-name, next, previous, up | |
770 @section Maketitle-type completion | |
771 @cindex maketitle-type completion | |
772 | |
773 We call it "maketitle-type completion" which completes commands such as | |
774 @code{\maketitle}. Take notice that maketitle-type commands take no | |
775 arguments. Then, typing | |
776 | |
777 @table @kbd | |
778 @item [prefix] m | |
46 | 779 @dots{} maketitle-type completion |
20 | 780 @end table |
781 | |
782 @noindent | |
783 begins maketitle-completion. Above mentioned method is true for | |
784 maketitle-completion, and there are La@TeX{} commands with no | |
785 arguments in completion table. | |
786 | |
787 @node Arbitrary completion, End completion, Maketitle-type completion, Completion | |
788 @comment node-name, next, previous, up | |
789 @section Arbitrary completion | |
790 @cindex arbitrary completion | |
791 | |
792 @noindent | |
793 You can complete certain La@TeX{} command anywhere without typical | |
794 completing method as described, by typing | |
795 | |
796 @table @kbd | |
797 @item [prefix] SPC | |
46 | 798 @dots{} arbitrary completion |
20 | 799 @end table |
800 | |
801 @noindent | |
802 after the initial string of La@TeX{} command that is preceded by @code{\}. | |
803 | |
804 @node End completion, Accent completion, Arbitrary completion, Completion | |
805 @comment node-name, next, previous, up | |
806 @section End completion | |
807 @cindex end completion | |
808 | |
809 @noindent | |
810 YaTeX automatically detects the opened environment and close it with | |
811 \@code{\end@{environment@}}. Though proficient YaTeX users never fail to | |
812 make environment with begin-type completion, some may begin an environment | |
813 manually. In that case, type | |
814 | |
815 @table @kbd | |
816 @item [prefix] e | |
46 | 817 @dots{} @code{end} completion |
20 | 818 @end table |
819 | |
820 @noindent | |
821 at the end of the opened environment. | |
822 | |
823 @node Accent completion, Image completion, End completion, Completion | |
824 @comment node-name, next, previous, up | |
825 @section Accent completion | |
826 @cindex accent completion | |
827 | |
828 When you want to write the European accent marks(like @code{\`@{o@}}), | |
829 | |
830 @table @kbd | |
831 @item [prefix] a | |
46 | 832 @dots{} accent completion |
20 | 833 @end table |
834 | |
835 @noindent | |
836 shows the menu | |
837 | |
838 @example | |
46 | 839 1:` 2:' 3:^ 4:" 5:~ 6:= 7:. u v H t c d b |
20 | 840 @end example |
841 | |
842 @noindent | |
843 in the minibuffer. Chose one character or corresponding numeric, | |
844 and you will see | |
845 | |
846 @example | |
46 | 847 \`{} |
20 | 848 @end example |
849 | |
850 @noindent | |
851 in the editing buffer with the cursor positioned in braces. Type | |
852 one more character `o' for example, then | |
853 | |
854 @example | |
46 | 855 \`{o} |
20 | 856 @end example |
857 | |
858 @noindent | |
859 will be completed, and the cursor gets out from braces. | |
860 | |
861 @node Image completion, Greek letters completion, Accent completion, Completion | |
862 @comment node-name, next, previous, up | |
863 @section Image completion of mathematical sign | |
864 @cindex image completion | |
865 @cindex math-mode | |
866 @cindex sigma | |
867 @cindex leftarrow | |
868 @cindex ; | |
869 | |
870 Arrow marks, sigma mark and those signs mainly used in the | |
871 TeX's math environment are completed by key sequences which | |
872 imitate the corresponding symbols graphically. This completion | |
873 only works in the math environment. YaTeX automatically detects | |
874 whether the cursor located in math environment or not, and | |
52 | 875 change the behavior of key strokes @kbd{;} and @kbd{:}. |
20 | 876 |
877 By the way, we often express the leftarrow mark by `<-' for example. | |
878 Considering such image, you can write @code{\leftarrow} by typing @kbd{<-} | |
879 after @kbd{;} (semicolon) as a prefix. In the same way, | |
880 @code{\longleftarrow} (@code{<--}) is completed by typing @kbd{;<--}, | |
881 infinity mark which is imitated by @code{oo} is completed by typing | |
882 @kbd{;oo}. | |
883 | |
884 Here are the sample operations in YaTeX math-mode. | |
885 | |
886 @example | |
887 INPUT Completed La@TeX{} commands | |
888 ; < - @code{\leftarrow} | |
889 ; < - - @code{\longleftarrow} | |
890 ; < - - > @code{\longleftrightarrow} | |
891 ; o @code{\circ} | |
892 ; o o @code{\infty} | |
893 @end example | |
894 | |
895 In any case, you can quit from image completion and can move | |
896 to the next editing operation if the La@TeX{} command you want is | |
897 shown in the buffer. | |
898 | |
899 @code{;} itself in math-environment is inserted by @kbd{;;}. Typing | |
900 @kbd{TAB} in the midst of image completion shows all of the La@TeX{} | |
901 commands that start with the same name as string you previously typed in. | |
902 In this menu buffer, press @kbd{RET} after moving the cursor (by @kbd{n}, | |
903 @kbd{p}, @kbd{b}, @kbd{f}) to insert the La@TeX{} command. | |
904 | |
905 To know all of the completion table, type @kbd{TAB} just after @kbd{;}. | |
906 And here is the sample menu by @kbd{TAB} after @kbd{;<}. | |
907 | |
908 @example | |
909 KEY LaTeX sequence sign | |
910 < \leq < | |
911 ~ | |
912 << \ll << | |
913 <- \leftarrow <- | |
914 <= \Leftarrow <= | |
915 @end example | |
916 | |
917 You can define your favorite key-vs-sequence completion table in the | |
918 Emacs-Lisp variable @code{YaTeX-math-sign-alist-private}. See also | |
919 @file{yatexmth.el} for the information of the structure of this variable. | |
920 | |
921 @node Greek letters completion, , Image completion, Completion | |
922 @comment node-name, next, previous, up | |
923 @section Greek letters completion | |
924 @cindex Greek letters completion | |
52 | 925 @cindex : |
20 | 926 |
927 Math-mode of YaTeX provides another image completion, Greek letters | |
52 | 928 completion in the same method. After prefix @kbd{:}, typing @kbd{a} makes |
20 | 929 @code{\alpha}, @kbd{b} makes @code{\beta} and @kbd{g} makes @code{\gamma} |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
930 and so on. First, type @kbd{:TAB} to know all the correspondence of |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
931 alphabets vs. Greek letters. |
20 | 932 |
52 | 933 If you will find @kbd{;} or @kbd{:} doesn't work in correct position of |
20 | 934 math environment, it may be a bug of YaTeX. Please send me a bug report |
935 with the configuration of your text, and avoid it temporarily by typing | |
52 | 936 @kbd{;} or @kbd{:} after universal-argument(@kbd{C-u}) which forces |
937 @kbd{;} and @kbd{:} to work as math-prefix. | |
20 | 938 |
49 | 939 @node Local dictionaries, Commenting out, Completion, Top |
940 @comment node-name, next, previous, up | |
941 @chapter Local dictionaries | |
942 @cindex local dictionaries | |
943 @cindex nervous users | |
944 | |
945 Tables for completion consist of three dictionaries; `standard | |
946 dictionary' built in @file{yatex.el}, `user dictionary' for your common | |
947 private commands, and `local dictionary' that is effective in a certain | |
948 directory. | |
949 | |
950 When you input the command unknown to YaTeX at a completion in the | |
951 minibuffer, YaTeX asks you with the following prompt; | |
952 | |
953 @example | |
51 | 954 `foo' is not in table. Register into: U)serDic L)ocalDic N)one D)iscad |
49 | 955 @end example |
956 | |
957 @noindent | |
51 | 958 In this menu, typing @kbd{u} updates your `user dictionary', @kbd{l} |
959 updates your local dictionary, @kbd{n} updates only on-memory dictionary | |
960 which go through only current Emacs session, and @kbd{d} updates no | |
961 dictionary and throws the new word away. | |
49 | 962 |
963 If you find this switching feature meaningless and bothersome, put the | |
964 next expression into your @file{~/.emacs} | |
965 | |
966 @lisp | |
967 (setq YaTeX-nervous nil) | |
968 @end lisp | |
969 | |
970 @node Commenting out, Cursor jump, Local dictionaries, Top | |
20 | 971 @comment node-name, next, previous, up |
972 @chapter Commenting out | |
973 @cindex commenting out | |
974 @cindex prefix > | |
975 @cindex prefix < | |
976 @cindex prefix , | |
977 @cindex prefix . | |
978 | |
979 You may want to comment out some region. | |
980 | |
981 @table @kbd | |
982 @item [prefix] > | |
46 | 983 @dots{} comment out region by % |
20 | 984 @item [prefix] < |
46 | 985 @dots{} uncomment region |
20 | 986 @end table |
987 | |
988 @noindent | |
989 cause an operation to the region between point and mark. | |
990 | |
991 @table @kbd | |
992 @item [prefix] . | |
46 | 993 @dots{} comment out current paragraph |
20 | 994 @item [prefix] , |
46 | 995 @dots{} uncomment current paragraph |
20 | 996 @end table |
997 | |
998 @noindent | |
999 comments or uncomments the paragraph where the cursor belongs. | |
1000 This `paragraph' means the region marked by the function | |
1001 mark-paragraph, bound to @kbd{ESC h} by default. It is NOT | |
1002 predictable what will happen when you continuously comment out | |
1003 some paragraph many times. | |
1004 | |
1005 You can also comment out an environment between @code{\begin} and | |
1006 @code{\end}, or a @code{\begin}-\@code{\end} pair themselves, by making the | |
1007 following key strokes on the line where @code{\begin@{@}} or | |
1008 @code{\end@{@}} exists. | |
1009 | |
1010 @table @kbd | |
1011 @item [prefix] > | |
46 | 1012 @dots{} comment out from \begin to \@code{end} |
20 | 1013 @item [prefix] < |
46 | 1014 @dots{} uncomment from \begin to \@code{end} |
20 | 1015 @end table |
1016 | |
1017 @noindent | |
1018 comment whole the contents of environment. Moreover, | |
1019 | |
1020 @table @kbd | |
1021 @item [prefix] . | |
46 | 1022 @dots{} comment out \begin and \@code{end} |
20 | 1023 @item [prefix] , |
46 | 1024 @dots{} uncomment \begin and \@code{end} |
20 | 1025 @end table |
1026 | |
1027 @noindent | |
1028 (un)comments out only environment declaration: @code{\begin@{@}} and | |
1029 @code{\end@{@}}. NOTE that even if you intend to comment out some region, | |
1030 invoking @kbd{[prefix] >} on the @code{\begin},@code{\end} line decides to | |
1031 work in `commenting out from @code{\begin} to @code{\end}' mode. | |
1032 | |
1033 | |
1034 @node Cursor jump, Changing and Deleting, Commenting out, Top | |
1035 @comment node-name, next, previous, up | |
1036 @chapter Cursor jump | |
1037 @cindex cursor jump | |
1038 @cindex prefix g | |
1039 | |
68 | 1040 |
1041 @menu | |
1042 * Jump to corresponding object:: | |
1043 * Invoking image processor:: | |
1044 * Jump to main file:: | |
1045 * Jumping around the environment:: | |
1046 * Jumping to last completion position:: | |
1047 @end menu | |
1048 | |
1049 @node Jump to corresponding object, Invoking image processor, Cursor jump, Cursor jump | |
1050 @comment node-name, next, previous, up | |
51 | 1051 @section Jump to corresponding object |
1052 | |
48 | 1053 Typing |
20 | 1054 |
1055 @table @kbd | |
1056 @item [prefix] g | |
46 | 1057 @dots{} go to corresponding object |
20 | 1058 @end table |
1059 | |
1060 @noindent | |
48 | 1061 in a certain place move the cursor to the place corresponding to the |
1062 La@TeX{} command of last place. YaTeX recognize the followings as pairs | |
1063 that have relation each other. | |
1064 | |
49 | 1065 @itemize @bullet |
48 | 1066 @item @code{\begin@{@}} <-> @code{\end@{@}} |
1067 @item @code{%#BEGIN} <-> @code{%#END} | |
59 | 1068 @item On the image-including line -> corresponding viewer or drawing tool |
48 | 1069 @item @code{\label@{@}} <-> @code{\ref@{@}} |
1070 @item @code{\include(\input)} -> included file | |
1071 @item @code{\bibitem@{@}} <-> @code{\cite@{@}} | |
49 | 1072 @end itemize |
48 | 1073 |
49 | 1074 On a @code{\begin},@code{\end} line, typing @kbd{[prefix] g} moves the |
1075 cursor to the corresponding @code{\end},@code{\begin} line, if its partner | |
51 | 1076 really exists. The behavior on the line @code{%#BEGIN} and @code{%#END} |
49 | 1077 are the same. Note that if the correspondent of @code{label/ref} or |
51 | 1078 @code{cite/bibitem} exists in another file, that file have to be opened to |
49 | 1079 make a round trip between references by @kbd{[prefix] g}. |
20 | 1080 |
1081 If you type @code{[prefix] g} on the line of @code{\include@{chap1@}}, | |
48 | 1082 typically in the main text, YaTeX switches buffer to @file{chap1.tex}. |
51 | 1083 |
1084 @table @kbd | |
1085 @item [prefix] 4 g | |
1086 @dots{} go to corresponding object in other window | |
1087 @end table | |
1088 | |
1089 @noindent | |
1090 do the same job as @kbd{[prefix] g} except it's done in other window. | |
1091 Note that this function doesn't work on @code{begin/end}, | |
1092 @code{%#BEGIN/%#END} pairs because it is meaningless. | |
1093 | |
68 | 1094 @node Invoking image processor, Jump to main file, Jump to corresponding object, Cursor jump |
1095 @comment node-name, next, previous, up | |
1096 @section Invoking image processor | |
59 | 1097 @cindex{Drawing tool invocation} |
1098 | |
1099 `image-including line' described above means such lines as | |
1100 @code{\epsfile@{file=foo.ps@}}. If you type @kbd{[prefix] g} on that | |
1101 line, YaTeX automatically searches source of `foo.ps' and invokes image | |
1102 viewer or drawing tool correspoinding to it. For example; if you draw | |
1103 an image foo.obj with Tgif and enclose its product named foo.eps by | |
1104 @code{\epsfile} command. Typing @kbd{[prefix] g} on @code{\epsfile} line | |
1105 make YaTeX invoke @code{tgif foo.obj}. How a processor is choosen is as | |
1106 follows. | |
1107 | |
1108 @enumerate | |
1109 @item | |
1110 If there is an expression matching with one of the pattern | |
1111 defined in @code{YaTeX-processed-file-regexp-alist}, extract file name | |
1112 from regexp group surrounded by \\(\\). (Which group corresponds is | |
1113 written in the cdr part of each list.) If no matches were found, do | |
1114 nothing. | |
1115 @item | |
1116 If there is a pattern as `%PROCESSOR' which is defined in the variable | |
1117 @code{YaTeX-file-processor-alist}, call that processor giving the | |
1118 file name with corresponding extension. | |
1119 @item | |
1120 If not, check the existence of each file which is supplied the | |
1121 extension in the cdr part of each list of | |
1122 @code{YaTeX-file-processor-alist}. If any, call the corresponding | |
1123 image viewer or drawing tool. | |
1124 @end enumerate | |
1125 | |
68 | 1126 @node Jump to main file, Jumping around the environment, Invoking image processor, Cursor jump |
1127 @comment node-name, next, previous, up | |
51 | 1128 @section Jump to main file |
1129 | |
1130 Typing | |
20 | 1131 |
1132 @table @kbd | |
1133 @item [prefix] ^ | |
46 | 1134 @dots{} visit main file |
20 | 1135 @item [prefix] 4^ |
46 | 1136 @dots{} visit main file in other buffer |
20 | 1137 @end table |
1138 @cindex prefix ^ | |
1139 @cindex prefix 4 ^ | |
1140 | |
1141 in a sub text switch the buffer to the main text specified by | |
1142 @code{%#!} notation. | |
1143 | |
68 | 1144 @node Jumping around the environment, Jumping to last completion position, Jump to main file, Cursor jump |
1145 @comment node-name, next, previous, up | |
1146 @section Jumping around the environment | |
51 | 1147 |
20 | 1148 And these are the functions which work on the current La@TeX{} |
1149 environment: | |
1150 | |
1151 @table @kbd | |
1152 @item M-C-a | |
46 | 1153 @dots{} beginning of environment |
20 | 1154 @item M-C-e |
46 | 1155 @dots{} @code{end} of environment |
20 | 1156 @item M-C-@@ |
46 | 1157 @dots{} mark environment |
20 | 1158 @end table |
1159 @cindex M-C-a | |
1160 @cindex M-C-e | |
1161 @cindex M-C-@@ | |
1162 | |
68 | 1163 @node Jumping to last completion position, , Jumping around the environment, Cursor jump |
1164 @comment node-name, next, previous, up | |
1165 @section Jumping to last completion position | |
1166 | |
1167 YaTeX always memorize the position of completion into register @code{3}. | |
1168 So every time you make a trip to any other part of text other than you are | |
1169 writing, you can return to the editing paragraph by calling | |
1170 register-to-point with argument YaTeX-current-position-register, which is | |
1171 achieved by typing @kbd{C-x j 3}(by default). | |
1172 | |
51 | 1173 @node Changing and Deleting, Filling, Cursor jump, Top |
20 | 1174 @comment node-name, next, previous, up |
1175 @chapter Changing and Deleting | |
1176 | |
1177 These functions are for change or deletion of La@TeX{} commands | |
1178 already entered. | |
1179 | |
1180 @table @kbd | |
1181 @item [prefix] c | |
46 | 1182 @dots{} change La@TeX{} command |
20 | 1183 @item [prefix] k |
46 | 1184 @dots{} kill La@TeX{} command |
20 | 1185 @end table |
1186 @cindex prefix c | |
1187 @cindex prefix k | |
1188 | |
49 | 1189 @menu |
68 | 1190 * Changing LaTeX commands:: |
1191 * Killing LaTeX commands:: | |
49 | 1192 @end menu |
1193 | |
68 | 1194 @node Changing LaTeX commands, Killing LaTeX commands, Changing and Deleting, Changing and Deleting |
49 | 1195 @comment node-name, next, previous, up |
1196 @section Changing La@TeX{} commands | |
1197 | |
1198 @kbd{[prefix] c} can change the various (La)@TeX{} commands. This can | |
1199 change the followings. | |
1200 @itemize @bullet | |
1201 @item Environment names | |
1202 @item Section-type commands | |
1203 @item Argument of section-type commands | |
1204 @item Optional parameters (enclosed by []) of section-type commands | |
1205 @item Font/size designators | |
52 | 1206 @item Math-mode's maketitle-type commands that can be inputted with |
1207 image completion | |
49 | 1208 @end itemize |
1209 | |
1210 Typing @kbd{[prefix] c} on one of above objects you want to change | |
1211 brings a suitable reading function sometimes with completion. | |
1212 Note: If you want to change the argument of section-type command that | |
1213 contains other La@TeX{} commands, type @kbd{[prefix] c} either of | |
1214 surrounding braces of the argument in order to make YaTeX ignore the | |
1215 internal La@TeX{} sequences as an object of changing. Anyway, it is | |
1216 very difficult to know which argument position the cursor belongs because | |
1217 the La@TeX{} commands can be nested and braces can freely emerge. So keep | |
1218 it mind to put the cursor on a brace when you are thinking of changing a | |
1219 complicated argument. | |
1220 | |
68 | 1221 @node Killing LaTeX commands, , Changing LaTeX commands, Changing and Deleting |
49 | 1222 @comment node-name, next, previous, up |
1223 @section Killing La@TeX{} commands | |
1224 @cindex Killing La@TeX{} commands | |
1225 | |
1226 @kbd{[prefix] k} kills the La@TeX{} commands sometimes with their | |
1227 arguments. Following table illustrates the correspondence of the invoking | |
1228 position and what is killed. | |
20 | 1229 |
1230 @example | |
1231 [Invoking position] [action] | |
49 | 1232 \begin, \end line kill \begin,\end pairs |
1233 %#BEGIN, %#END line kill %#BEGIN,%#END pairs | |
20 | 1234 on a Section-type command kill section-type command |
1235 on a parenthesis kill parentheses | |
1236 @end example | |
1237 | |
49 | 1238 Note that when killing @code{\begin, \end} or @code{%#BEGIN, %#END} pair, |
1239 the lines @code{\begin, \end} or @code{%#BEGIN, %#END} exist will be | |
1240 killed entirely. So take care not to create any line that contains more | |
1241 than one @code{\begin} or so. | |
1242 | |
20 | 1243 While all operations above are to kill `containers' which surround some |
1244 text, universal argument (@kbd{C-u}) for these commands kills not only | |
1245 `containers' but also `contents' of them. See below as a sample. | |
1246 | |
1247 @example | |
46 | 1248 Original text: [prefix] k C-u [prefix] k |
1249 Main \footnote@{note@} here. Main note here. Main here. | |
20 | 1250 ~(cursor) |
1251 @end example | |
1252 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1253 @node Filling, Updation of includeonly, Changing and Deleting, Top |
20 | 1254 @comment node-name, next, previous, up |
51 | 1255 @chapter Filling |
1256 @cindex filling | |
1257 | |
1258 @section Filling an item | |
20 | 1259 @cindex filling an item |
1260 @cindex prefix i | |
1261 | |
51 | 1262 To fill a term (descriptive sentences) of @code{\item}, type |
20 | 1263 |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1264 @c @table @kbd |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1265 @c @item [prefix] i |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1266 @c @dots{} fill item |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1267 @c @end table |
20 | 1268 @table @kbd |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1269 @item M-q |
46 | 1270 @dots{} fill item |
20 | 1271 @end table |
1272 | |
1273 @noindent | |
1274 on that item. | |
1275 | |
1276 YaTeX uses the value of the variable @code{YaTeX-item-regexp} as the | |
1277 regular expression to search item header in itemize environment. | |
51 | 1278 If you make a newcommand to itemize terms(e.g. @code{\underlineitem}), put |
20 | 1279 |
1280 @lisp | |
46 | 1281 (setq YaTeX-item-regexp |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1282 "\\(\\\\\\(sub\\)*item\\)\\|\\(\\\\underlineitem\\)") |
20 | 1283 @end lisp |
1284 @cindex YaTeX-item-regexp | |
1285 | |
1286 in your @file{~/.emacs}. If you are not familiar with regular expression | |
1287 for Emacs-Lisp, name a newcommand for `itemize' beginning with | |
1288 @code{\item} such as @code{\itembf}, not @code{\bfitem}. | |
1289 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1290 This function reformats the @code{\item} into `hang-indented' style. |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1291 For example: |
51 | 1292 |
1293 @example | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1294 itemize, enumerate environment: |
51 | 1295 > |
1296 >\item[foo] `foo' is the typical word for describing an | |
1297 > arbitrarily written.... | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1298 description environment: |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1299 > \item[bar] When the word `for' is used as an arbitrarily |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1300 > word, `bar' is bound to follow it. |
51 | 1301 @end example |
1302 | |
52 | 1303 Note that the indent depth of an @code{\item} word and its descriptive |
51 | 1304 paragraph are the same in latter case. If you want to use different |
1305 depth, invoke fill-paragraph at the beginning of non-whitespace | |
1306 character(see below). | |
1307 | |
1308 @section Filling paragraph | |
1309 @cindex Filling paragraph | |
1310 @cindex M-q | |
1311 | |
1312 Fill-paragraph is little bit adapted for La@TeX{} sources. It retains from | |
1313 filling in certain environments where formatting leads to a disaster such | |
1314 as verbatim, tabular, or so. And it protects @code{\verb} expressions | |
1315 from being folded (The variable @code{YaTeX-verb-regexp} controls this). | |
1316 Besides, putting cursor on the first occurrence of non-whitespace | |
1317 character on a line changes the fill-prefix temporarily to the depth of | |
1318 the line. | |
1319 | |
59 | 1320 @node Updation of includeonly, What column, Filling, Top |
20 | 1321 @comment node-name, next, previous, up |
1322 @chapter Updation of @code{\includeonly} | |
1323 @cindex includeonly | |
1324 | |
1325 When you edit splitting source texts, the notation | |
1326 | |
1327 @example | |
46 | 1328 \includeonly@{CurrentEditingFileName@} |
20 | 1329 @end example |
1330 | |
1331 @noindent | |
1332 in the main file reduces the time of typesetting. If you want | |
1333 to hack other file a little however, you have to rewrite it to | |
1334 | |
1335 @example | |
46 | 1336 \includeonly@{OtherFileNameYouWantToFix@} |
20 | 1337 @end example |
1338 | |
1339 @noindent | |
1340 in the main file. YaTeX automatically detects that the current | |
1341 edited text is not in includeonly list and prompts you | |
1342 | |
1343 @example | |
46 | 1344 A)dd R)eplace %)comment? |
20 | 1345 @end example |
1346 | |
1347 in the minibuffer. Type @kbd{a} if you want to add the current file name | |
1348 to @code{\includeonly} list, @kbd{r} to replace \@code{includeonly} list | |
1349 by the current file, and type @kbd{%} to comment out the | |
1350 @code{\includeonly} line. | |
1351 | |
59 | 1352 @node What column, Intelligent newline, Updation of includeonly, Top |
20 | 1353 @comment node-name, next, previous, up |
1354 @chapter What column? | |
1355 @cindex what column | |
1356 @cindex complex tabular | |
1357 @cindex prefix & | |
1358 | |
1359 We are often get tired of finding the corresponding column in | |
1360 large tabulars. For example, | |
1361 | |
1362 @example | |
1363 \begin@{tabular@}@{|c|c|c|c|c|c|c|c|@}\hline | |
1364 Name&Position&Post No.&Addr.&Phone No.&FAX No.& | |
1365 Home Addr.&Home Phone\\ \hline | |
1366 Thunder Bird & 6 & 223 & LA & xxx-yyy & | |
1367 zzz-www & Japan & 9876-54321 \\ | |
1368 & 2 & \multicolumn@{2@}@{c|@}@{Unknown@} | |
1369 &&&(???) | |
1370 \\ \hline | |
1371 \end@{tabular@} | |
1372 @end example | |
1373 | |
1374 Suppose you have the cursor located at @code{(???)} mark, can you tell | |
1375 which column it is belonging at once? Maybe no. In such case, | |
1376 type | |
1377 | |
1378 @table @kbd | |
1379 @item [prefix] & | |
46 | 1380 @dots{} What column |
20 | 1381 @end table |
1382 | |
1383 @noindent | |
1384 in that position. YaTeX tells you the column header of the | |
1385 current field. Since YaTeX assumes the first line of tabular | |
1386 environment as a row of column headers, you can create a row of | |
1387 virtual column headers by putting them in the first line and | |
1388 commenting that line with @code{%}. | |
1389 | |
59 | 1390 @node Intelligent newline, Online help, What column, Top |
28 | 1391 @comment node-name, next, previous, up |
1392 @chapter Intelligent newline | |
1393 @cindex Intelligent newline | |
1394 @cindex ESC RET | |
1395 @cindex M-C-m | |
1396 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1397 At the end of begin-type completion of tabular[*], array, itemize, |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1398 enumerate or tabbing environment, or typing |
28 | 1399 |
1400 @table @kbd | |
1401 @item ESC RET | |
46 | 1402 @dots{} Intelligent newline |
28 | 1403 @end table |
1404 | |
1405 @noindent | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1406 in these environments inserts the contents corresponding to the current |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1407 environment in the next line. (At the begin-type completion, this |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1408 contents can be removed by `undo'.) In @code{tabular} environment, for |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1409 example, @kbd{ESC RET} inserts the certain number of @code{&} and trailing |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1410 @code{\\}, and @code{\hline} if other @code{\hline} is found in backward. |
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1411 Here are the list of contents vs. environments. |
28 | 1412 |
1413 @itemize | |
1414 @item @code{tabular}, @code{tabular*}, @code{array} | |
1415 | |
46 | 1416 Corresponding number of @code{&} and @code{\\}. |
1417 And @code{\hline} if needed. | |
28 | 1418 |
1419 @item @code{tabbing} | |
1420 | |
46 | 1421 The same number of @code{\>} as @code{\=} in the first line. |
28 | 1422 |
1423 @item @code{itemize}, @code{enumerate}, @code{description}, @code{list} | |
1424 | |
46 | 1425 @code{\item} or @code{item[]}. |
28 | 1426 @end itemize |
1427 | |
1428 Note that since this function works seeing the contents of the first | |
1429 line, please call this after the second line if possible. | |
1430 | |
1431 If you want to apply these trick to other environments, @code{foo} | |
1432 environment for example, define the function named | |
1433 @code{YaTeX-intelligent-newline-foo} to insert corresponding contents. | |
1434 That function will be called at the beginning of the next line after the | |
1435 newline is inserted to the current line. Since the function | |
1436 @code{YaTeX-indent-line} is designed to indent the current line properly, | |
1437 calling this function before your code to insert certain contents must be | |
1438 useful. See the definition of the function | |
1439 @code{YaTeX-intelligent-newline-itemize} as an example. | |
1440 | |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1441 @node Online help, Browsing file hierarchy, Intelligent newline, Top |
20 | 1442 @comment node-name, next, previous, up |
1443 @chapter Online help | |
1444 @cindex online help | |
1445 @cindex prefix ? | |
1446 @cindex prefix / | |
1447 @cindex apropos | |
1448 @cindex keyword search | |
1449 | |
1450 YaTeX provides you the online help with popular La@TeX{} commands. | |
1451 | |
1452 Here are the key strokes for the online help. | |
1453 | |
1454 @table @kbd | |
1455 @item [prefix] ? | |
46 | 1456 @dots{} Online help |
20 | 1457 @item [prefix] / |
46 | 1458 @dots{} Online apropos |
20 | 1459 @end table |
1460 | |
1461 @section Online help | |
1462 | |
1463 `Online help' shows the documentation for the popular La@TeX{} | |
1464 commands(defaults to the commands on the cursor) in the next buffer. | |
1465 There are two help file, `global help' and `private help'. The former | |
1466 file contains the descriptions on the standard La@TeX{} command and is | |
1467 specified its name by variable @code{YaTeX-help-file}. Usually, the | |
1468 global help file should be located in public space (@code{$EMACSEXECPATH} | |
1469 by default) and should be world writable so that anyone can update it to | |
1470 enrich its contents. The latter file contains descriptions on | |
1471 non-standard or personal command definitions and is specified by | |
1472 @code{YaTeX-help-file-private}. This file should be put into private | |
1473 directory. | |
1474 | |
1475 @section Online apropos | |
1476 | |
1477 `Online apropos' is an equivalent of GNU Emacs's apropos. It | |
1478 shows all the documentations that contains the keyword entered by | |
1479 the user. | |
1480 | |
1481 @section When no descriptions are found... | |
1482 | |
1483 If there is no description on a command in help files, YaTeX | |
1484 requires you to write a description on that command. If you are | |
1485 willing to do, determine which help file to add and write the | |
1486 description on it referring your manual of (La)TeX. Please send | |
1487 me your additional descriptions if you describe the help on some | |
1488 standard commands. I might want to include it in the next | |
1489 distribution. | |
1490 | |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1491 @node Browsing file hierarchy, Cooperation with other packages, Online help, Top |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1492 @comment node-name, next, previous, up |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1493 @chapter Browsing file hierarchy |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1494 @cindex hierarchy |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1495 @cindex browsing |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1496 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1497 When you are editing multi-file source, typing |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1498 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1499 @table @kbd |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1500 @item [prefix] d |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1501 @dots{} browse file hierarchy |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1502 @end table |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1503 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1504 @noindent |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1505 asks you the parent-most file (which may be defaulted) and displays the |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1506 documentation hierarchy in the next window. In this buffer, the following |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1507 commands are available. |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1508 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1509 @table @kbd |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1510 @item n |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1511 @dots{} move to the next line and show its contents |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1512 @item p |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1513 @dots{} move to the previous line and show its contents |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1514 @item N |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1515 @dots{} move to the next file in the same inclusion level |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1516 @item P |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1517 @dots{} move to the previous file in the same inclusion level |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1518 @item j |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1519 @dots{} move to the next line |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1520 @item k |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1521 @dots{} move to the previous line |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1522 @item u |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1523 @dots{} move to the parent file |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1524 @item . |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1525 @dots{} show the current files contents in the next window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1526 @item SPC |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1527 @dots{} scroll up the current file window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1528 @item DEL, b |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1529 @dots{} scroll down the current file window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1530 @item < |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1531 @dots{} show the beginning of the current file |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1532 @item > |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1533 @dots{} show the end of the current file |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1534 @item > |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1535 @dots{} return to the previous postion after @kbd{<} or @kbd{>} |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1536 @item RET, g |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1537 @dots{} open the current file in the next window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1538 @item mouse-2 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1539 @dots{} same as RET(available only with window system) |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1540 @item o |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1541 @dots{} other window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1542 @item 1 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1543 @dots{} delete other windows |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1544 @item - |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1545 @dots{} shrink hierarchy buffer window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1546 @item + |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1547 @dots{} enlarge hierarchy buffer window |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1548 @item ? |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1549 @dots{} describe mode |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1550 @item q |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1551 @dots{} quit |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1552 @end table |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1553 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1554 Note that operations on the file contents in the next window do not work |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1555 correctly when you close the corresponding file. |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1556 |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1557 @node Cooperation with other packages, Customizations, Browsing file hierarchy, Top |
20 | 1558 @comment node-name, next, previous, up |
1559 @chapter Cooperation with other packages | |
1560 | |
1561 YaTeX works better with other brilliant packages. | |
1562 | |
1563 @section gmhist | |
1564 @cindex gmhist | |
1565 @cindex command history | |
1566 @cindex minibuffer history | |
1567 | |
1568 When you are loading @file{gmhist.el} and @file{gmhist-mh.el}, you can | |
1569 use independent command history list at the prompt of preview command | |
1570 (@kbd{[prefix] tp}) and print command (@kbd{[prefix] tl}). On each | |
1571 prompt, you can enter the previous command line string repeatedly by | |
1572 typing @kbd{M-p}. | |
1573 | |
1574 @section min-out | |
1575 @cindex min-out | |
1576 | |
1577 @file{min-out}, the outline minor mode, can be used in yatex-mode | |
1578 buffers. If you want to use it with YaTeX, please refer the | |
1579 file @file{yatexm-o.el} as an example. | |
1580 | |
1581 @node Customizations, Etcetera, Cooperation with other packages, Top | |
1582 @comment node-name, next, previous, up | |
1583 @chapter Customizations | |
1584 @cindex customizations | |
1585 | |
1586 You can customize YaTeX by setting Emacs-Lisp variables and by making | |
1587 add-in functions. | |
1588 | |
1589 @menu | |
1590 * Lisp variables:: | |
1591 * Add-in functions:: | |
49 | 1592 * Add-in generator:: |
20 | 1593 @end menu |
1594 | |
33 | 1595 @node Lisp variables, Add-in functions, Customizations, Customizations |
20 | 1596 @comment node-name, next, previous, up |
1597 @section Lisp variables | |
1598 @cindex customizable variables | |
1599 | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1600 You can change the key assignments or make completion more comfortable |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1601 by setting the values of various variables which control the movement of |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1602 yatex-mode. |
20 | 1603 |
1604 For example, if you want to change the prefix key stroke from @kbd{C-c} | |
1605 to any other sequence, set YaTeX-prefix to whatever you want to use. If | |
1606 you don't want to use the key sequence @kbd{C-c letter} which is assumed | |
1607 to be the user reserved sequence in Emacs world, set | |
1608 @code{YaTeX-inhibit-prefix-letter} to @code{t}, and all of the default key | |
1609 bind of @kbd{C-c letter} will turn to the corresponding @kbd{C-c C-letter} | |
1610 (but the region based completions that is invoked with @kbd{C-c | |
1611 Capital-letter} remain valid, if you want to disable those bindings, set | |
1612 that variable to 1 instead of @code{t}). | |
1613 | |
1614 @menu | |
1615 * All customizable variables:: | |
1616 * Sample definitions:: | |
1617 * Hook variables:: | |
1618 * Hook file:: | |
1619 @end menu | |
1620 | |
33 | 1621 @node All customizable variables, Sample definitions, Lisp variables, Lisp variables |
20 | 1622 @comment node-name, next, previous, up |
1623 @subsection All customizable variables | |
1624 @cindex all customizable variables | |
1625 | |
1626 Here are the customizable variables of yatex-mode. Each value setq-ed | |
1627 in @file{~/.emacs} is preferred and that of defined in @file{yatex.el} is | |
49 | 1628 neglected. Parenthesized contents stands for the default value. When you |
1629 are to change some of these variables, see more detailed documentation of | |
1630 the variable by @kbd{M-x describe-variable}. | |
20 | 1631 |
46 | 1632 @defvar YaTeX-prefix |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1633 Prefix key stroke (@kbd{C-c}) |
46 | 1634 @end defvar |
20 | 1635 |
46 | 1636 @defvar YaTeX-inhibit-prefix-letter |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1637 Change key stroke from @kbd{C-c letter} to @kbd{C-c C-letter} (@code{nil}) |
46 | 1638 @end defvar |
20 | 1639 |
46 | 1640 @defvar YaTeX-fill-prefix |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1641 Fill-prefix used in yatex-mode (@code{nil}) |
46 | 1642 @end defvar |
20 | 1643 |
46 | 1644 @defvar YaTeX-user-completion-table |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1645 Name of user dictionary where learned completion table will be stored. |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1646 (@code{"~/.yatexrc"}) |
46 | 1647 @end defvar |
20 | 1648 |
46 | 1649 @defvar tex-command |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1650 La@TeX{} typesetter command (@code{"latex"}) |
46 | 1651 @end defvar |
20 | 1652 |
46 | 1653 @defvar dvi2-command |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1654 Preview command (@code{"xdvi -geo +0+0 -s 4"}) |
46 | 1655 @end defvar |
20 | 1656 |
46 | 1657 @defvar dviprint-command-format |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1658 Command format to print dvi file (@code{"dvi2ps %f %t %s | lpr"}) |
46 | 1659 @end defvar |
20 | 1660 |
46 | 1661 @defvar dviprint-from-format |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1662 Start page format of above %f. %b will turn to start page (@code{"-f %b"}) |
46 | 1663 @end defvar |
20 | 1664 |
46 | 1665 @defvar dviprint-to-format |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1666 End page format of above %t. %e will turn to @code{end} page (@code{"-t %e"}) |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1667 @end defvar |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1668 |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1669 @defvar makeindex-command |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1670 Default makeindex command (@code{"makeindex"} (@code{"makeind"} on MS-DOS)) |
46 | 1671 @end defvar |
20 | 1672 |
46 | 1673 @defvar section-name |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1674 Initial default value at the first section-type completion |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1675 (@code{"documentstyle"}) |
46 | 1676 @end defvar |
20 | 1677 |
46 | 1678 @defvar env-name |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1679 Initial default value at the first begin-type completion (@code{"document"}) |
46 | 1680 @end defvar |
20 | 1681 |
46 | 1682 @defvar fontsize-name |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1683 Ditto of large-type (@code{"large"}) |
46 | 1684 @end defvar |
20 | 1685 |
46 | 1686 @defvar single-command |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1687 Ditto of maketitle-type (@code{"maketitle"}) |
46 | 1688 @end defvar |
20 | 1689 |
46 | 1690 @defvar YaTeX-need-nonstop |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1691 Put @code{\nonstopmode@{@}} or not (@code{nil}) |
46 | 1692 @end defvar |
20 | 1693 |
46 | 1694 @defvar latex-warning-regexp |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1695 Regular expression of warning message latex command puts out |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1696 (@code{"line.* [0-9]*"}) |
46 | 1697 @end defvar |
20 | 1698 |
46 | 1699 @defvar latex-error-regexp |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1700 Regular expression of error message (@code{"l\\.[1-9][0-9]*"}) |
46 | 1701 @end defvar |
20 | 1702 |
46 | 1703 @defvar latex-dos-emergency-message |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1704 Message latex command running on DOS puts at abort (@code{"Emergency stop"}) |
46 | 1705 @end defvar |
20 | 1706 |
46 | 1707 @defvar YaTeX-item-regexp |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1708 Regular expression of item command (@code{"\\\\item"}) |
46 | 1709 @end defvar |
20 | 1710 |
51 | 1711 @defvar YaTeX-verb-regexp |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1712 Regexp of verb family. Omit \\\\. (@code{"verb\\*?\\|path"}) |
51 | 1713 @end defvar |
1714 | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1715 @defvar YaTeX-nervous |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1716 T for using local dictionary (@code{t}) |
46 | 1717 @end defvar |
20 | 1718 |
46 | 1719 @defvar YaTeX-sectioning-regexp |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1720 Regexp of La@TeX{} sectioning command |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1721 (@code{"\\(part\\|chapter\\*?\\|\\(sub\\)*\\(section\\|paragraph\\)\\*?\\)\\b"}) |
46 | 1722 @end defvar |
20 | 1723 |
46 | 1724 @defvar YaTeX-fill-inhibit-environments |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1725 Inhibit fill in these environments |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1726 (@code{'("tabular" "tabular*" "array" "picture" "eqnarray" "eqnarray*" "equation" "math" "displaymath" "verbatim" "verbatim*")}) |
46 | 1727 @end defvar |
20 | 1728 |
46 | 1729 @defvar YaTeX-uncomment-once |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1730 T for deleting all preceding @code{%} (@code{nil}) |
46 | 1731 @end defvar |
20 | 1732 |
46 | 1733 @defvar YaTeX-close-paren-always |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1734 T for always close all parenthesis automatically, @code{nil} for only eol |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1735 (@code{t}) |
46 | 1736 @end defvar |
20 | 1737 |
46 | 1738 @defvar YaTeX-auto-math-mode |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1739 Switch math-mode automatically (@code{t}) |
46 | 1740 @end defvar |
20 | 1741 |
51 | 1742 @defvar YaTeX-math-key-list-private |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1743 User defined alist, math-mode-prefix vs completion alist |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1744 used in image completion (@code{nil}). See @file{yatexmth.el} |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1745 for the information about how to define a completion alist. |
51 | 1746 @end defvar |
1747 | |
46 | 1748 @defvar YaTeX-default-pop-window-height |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1749 Initial height of typesetting buffer when one-window. |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1750 Number for the lines of the buffer, numerical string for |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1751 the percentage of the screen-height. @code{nil} for half height (10) |
46 | 1752 @end defvar |
20 | 1753 |
46 | 1754 @defvar YaTeX-help-file |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1755 Global online help file name (@file{$EMACS/etc/YATEXHLP.jp}) |
46 | 1756 @end defvar |
20 | 1757 |
46 | 1758 @defvar YaTeX-help-file-private |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1759 Private online help file name (@file{"~/YATEXHLP.jp"}) |
46 | 1760 @end defvar |
20 | 1761 |
46 | 1762 @defvar YaTeX-no-begend-shortcut |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1763 Disable [prefix] b ?? shortcut (@code{nil)} |
46 | 1764 @end defvar |
20 | 1765 |
49 | 1766 @defvar YaTeX-hilit-pattern-adjustment-private |
1767 List of the list that contain the regular expression and the symbol of | |
1768 logical meaning of the string that matches the pattern. See also the | |
1769 value from @code{(assq 'yatex-mode hilit-patterns-alist)} and the value of | |
1770 @code{YaTeX-hilit-pattern-adjustment-default} (and even the document of | |
1771 hilit19.el). | |
1772 @end defvar | |
1773 | |
1774 @defvar YaTeX-sectioning-level | |
1775 Alist of LaTeX's sectioning command vs its height. | |
1776 @end defvar | |
1777 | |
53
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1778 @defvar YaTeX-hierarchy-ignore-heading-regexp |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1779 @code{YaTeX-display-hierarchy} searches for sectioning command first, and |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1780 comment line secondary as a file headings. In latter case, ignore lines |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1781 that match with regular expression of this variable. Default value of |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1782 this variable is RCS header expressions and mode specifying line `-*- xxxx |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1783 -*'. |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1784 @end defvar |
5f4b18da14b3
Fix functions relating YaTeX-beginning-of-environment or
yuuji
parents:
52
diff
changeset
|
1785 |
54 | 1786 @defvar YaTeX-skip-default-reader |
1787 Non-nil for this variable skips the default argument reader of | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1788 section-type command when add-in function for it is not defined |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1789 (@code{nil}) |
54 | 1790 @end defvar |
1791 | |
56 | 1792 @defvar YaTeX-create-file-prefix-g |
1793 When typing @kbd{prefix g} on the @code{\include} line, | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1794 open the target file even if the file doesn't exist (@code{nil}) |
56 | 1795 @end defvar |
1796 | |
1797 @defvar YaTeX-simple-messages | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1798 Simplyfy messages of various completions (@code{nil}) |
56 | 1799 @end defvar |
1800 | |
57 | 1801 @defvar YaTeX-hilit-sectioning-face |
1802 When hilit19 and yatex19 is active, YaTeX colors the sectioning commands. | |
1803 This variable specifies the foreground and background color of | |
1804 @code{\part} macro. The default value is @code{'(yellow/dodgerblue | |
1805 yellow/slateblue)}. The first element of this list is for the screen when | |
1806 @code{hilit-background-mode} is @code{'light}, and the second element is | |
1807 for @code{'dark}. You should specify both color as `forecolor/backcolor'. | |
1808 @end defvar | |
1809 | |
1810 @defvar YaTeX-hilit-sectioning-attenuation-rate | |
1811 When color mode, this variable specifies how much attenuate the color | |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1812 density of @code{\subparagraph} compared with that of @code{\chapter} |
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1813 (@code{'(15 40)}) See also @code{YaTeX-hilit-sectioning-face}. |
57 | 1814 @end defvar |
56 | 1815 |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1816 @defvar YaTeX-use-AMS-LaTeX |
60
9e08ed569d80
yahtml: change keystroke of calling browser to [prefix] t p
yuuji
parents:
59
diff
changeset
|
1817 If you use AMS-LaTeX, set to @code{t} (@code{nil}) |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1818 @end defvar |
56 | 1819 |
65 | 1820 @defvar YaTeX-template-file |
1821 File name which is automatically inserted at creation | |
1822 (@code{~/work/template.tex}) | |
1823 @end defvar | |
1824 | |
20 | 1825 @node Sample definitions, Hook variables, All customizable variables, Lisp variables |
1826 @comment node-name, next, previous, up | |
1827 @subsection Sample definitions | |
1828 @cindex prefix key stroke | |
1829 @cindex fill-prefix | |
1830 | |
1831 For instance, to change the prefix key stroke to @kbd{ESC}, and name of | |
1832 the user dictionary @file{~/src/emacs/yatexrc}, and set @code{fill-prefix} | |
1833 to single TAB character, add the following @code{setq} to @file{~/.emacs}. | |
1834 | |
1835 @lisp | |
46 | 1836 (setq YaTeX-prefix "\e" |
1837 YaTeX-user-completion-table "~/src/emacs/yatexrc" | |
1838 YaTeX-fill-prefix " ") | |
20 | 1839 @end lisp |
1840 | |
1841 @node Hook variables, Hook file, Sample definitions, Lisp variables | |
1842 @comment node-name, next, previous, up | |
1843 @subsection Hook variables | |
1844 @cindex hook variables | |
1845 | |
1846 More customizations will be done by the hook-function defined in | |
1847 hook-variable @code{yatex-mode-hook}. This is useful to define a shortcut | |
1848 key sequence to enter some environments other than @code{document} and | |
1849 @code{enumerate} etc. The following statement defines @code{[prefix] ba} | |
1850 to enter @code{\begin@{abstract@}} ... @code{=end@{abstract@}} | |
1851 immediately. | |
1852 | |
1853 @lisp | |
46 | 1854 (setq yatex-mode-hook |
1855 '(lambda() (YaTeX-define-begend-key "ba" "abstract"))) | |
20 | 1856 @end lisp |
1857 | |
46 | 1858 You should use functions @code{YaTeX-define-key}, or |
1859 @code{YaTeX-define-begend-key} to define all the key sequences of | |
20 | 1860 yatex-mode. |
1861 | |
1862 @node Hook file, , Hook variables, Lisp variables | |
1863 @comment node-name, next, previous, up | |
1864 @subsection Hook file | |
1865 @cindex hook file | |
1866 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1867 You can stuff all of YaTeX related expressions into a file named |
20 | 1868 @file{yatexhks.el} if you have a lot of codes. YaTeX automatically load |
1869 this file at the initialization of itself. Using @file{yatexhks.el} | |
1870 makes @code{yatex-mode-load-hook} unnecessary. | |
1871 | |
49 | 1872 @node Add-in functions, Add-in generator, Lisp variables, Customizations |
20 | 1873 @comment node-name, next, previous, up |
1874 @section Add-in functions | |
1875 @cindex add-in functions | |
49 | 1876 @cindex yatexadd.el |
20 | 1877 |
1878 You can easily define a function to input detailed arguments | |
49 | 1879 with completion according to La@TeX{} environments or commands. |
1880 | |
1881 @c @node What is add-in functions?, , Add-in functions, Add-in functions | |
1882 @comment node-name, next, previous, up | |
1883 @subsection What is add-in functions? | |
1884 @cindex tabular | |
1885 | |
1886 When you input @code{tabular} environment, don't you think ``I want | |
1887 YaTeX to complete its argument toward my favorite one such as | |
1888 @code{@{|c|c|c|@}}...''? Yes, you can define the function to complete | |
1889 arguments for any environment and any La@TeX{} commands. | |
1890 | |
1891 @subsection Procedure | |
1892 | |
1893 Here is the procedure to define add-in functions. | |
1894 @enumerate | |
1895 @item | |
1896 Define the function | |
1897 @item | |
1898 Put the function into @file{yatexhks.el} | |
1899 @end enumerate | |
1900 | |
1901 @menu | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1902 * How the add-in function works:: |
49 | 1903 * How the function is called:: |
1904 * Useful functions for creating add-in:: | |
1905 * Contribution:: | |
1906 @end menu | |
1907 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1908 @node How the add-in function works, How the function is called, Add-in functions, Add-in functions |
49 | 1909 @comment node-name, next, previous, up |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
1910 @subsection How the add-in function works |
49 | 1911 |
1912 There are two kinds of add-in. @dfn{Option add-in} returns the | |
1913 La@TeX{}'s optional parameters such as optional strings after | |
1914 @code{\begin@{ENV@}}, optional strings between a section-type command | |
1915 and its first argument, and optional strings just after type | |
1916 maketitle-type command. The following illustrates the name of add-in | |
1917 functions, where underlined strings are generated by add-in functions. | |
1918 | |
1919 @display | |
1920 \begin{table}[ht] (Function name: YaTeX:table) | |
1921 ~~~~ | |
1922 \put(100,200){} (Function name: YaTeX:put) | |
1923 ~~~~~~~~~ | |
1924 \sum_{i=0}^{n} (Function name: YaTeX:sum) | |
1925 ~~~~~~~~~~ | |
1926 @end display | |
1927 | |
1928 Obviously, the function name is decided by concatenating the prefix | |
1929 `YaTeX:' and La@TeX{} command's name. | |
1930 | |
1931 Another add-in type is @dfn{argument add-in}, which completes arguments | |
1932 for section-type commands. | |
1933 | |
1934 @display | |
1935 \newcommand{\foo}{bar} (Function name: YaTeX::newcommand) | |
1936 ~~~~ ~~~ | |
1937 @end display | |
1938 | |
1939 When the section-type command is inputted, the function named by | |
1940 concatenating `YaTeX::' and section-type command, is called automatically | |
1941 with an integer argument which indicates which argument of section-type | |
1942 command is being read. Thus the add-in should determine the | |
51 | 1943 job referring the value of its argument. |
49 | 1944 |
1945 @menu | |
68 | 1946 * Defining option-add-in:: |
1947 * Defining argument-add-in:: | |
49 | 1948 @end menu |
1949 | |
68 | 1950 @node Defining option-add-in, Defining argument-add-in, How the add-in function works, How the add-in function works |
49 | 1951 @comment node-name, next, previous, up |
1952 @subsubsection Defining `option add-in' | |
1953 | |
1954 If you want @code{@{|c|c|c|@}} for all @code{tabular} environment, | |
1955 | |
1956 @lisp | |
1957 (defun YaTeX:tabular () | |
1958 "{|c|c|c|}") | |
1959 @end lisp | |
1960 | |
1961 @noindent | |
1962 is enough. If you want more complicated format, define as below. | |
1963 | |
1964 @lisp | |
1965 (defun YaTeX:tabular () | |
1966 "@{@@@{\\vrule width 1pt\\ @}|||@@@{\\ \\vrule width 1pt@}@}") | |
1967 @end lisp | |
1968 | |
1969 @noindent | |
1970 Note that the character @code{\} must be described as @code{\\} in | |
1971 Emacs-Lisp. The next example reads the tabular format from keyboard. | |
1972 @lisp | |
1973 (defun YaTeX:tabular () | |
1974 (concat "{" (read-string "Rule: ") "}")) | |
1975 @end lisp | |
1976 | |
68 | 1977 @node Defining argument-add-in, , Defining option-add-in, How the add-in function works |
49 | 1978 @comment node-name, next, previous, up |
1979 @subsubsection Defining `argument add-in' | |
1980 | |
1981 This section describes how to define the add-in function for | |
1982 @code{\newcommand}. | |
1983 | |
1984 The first argument of @code{\newcommand} begins always with @code{\}. | |
1985 The second argument is usually so complex that we can not edit them in the | |
1986 minibuffer. Here is the created function considering this. | |
1987 | |
1988 @lisp | |
1989 (defun YaTeX::newcommand (n) ;n is argument position | |
1990 (cond | |
1991 ((= n 1) ;1st argument is macro name | |
1992 (read-string "Command: " "\\")) ;initial input `\' | |
1993 ((= n 2) "") ;do nothing when reading arg#2 | |
1994 (t nil))) | |
1995 @end lisp | |
1996 | |
1997 Note that when the `argument add-in' function return `nil', normal | |
1998 argument reader will be called. | |
1999 | |
58
3a7c0c2bf16d
Official support for AMS-LaTeX, HTML, xdvi -remote, Netscape
yuuji
parents:
57
diff
changeset
|
2000 @node How the function is called, Useful functions for creating add-in, How the add-in function works, Add-in functions |
49 | 2001 @comment node-name, next, previous, up |
2002 @subsection How the function is called | |
2003 | |
2004 YaTeX calls the add-in functions for specified begin-type, section-type, | |
2005 and maketitle-type command, if any. `Option add-in' functions for | |
2006 begin-type are called when @code{\begin@{ENV@}} has been inserted, | |
2007 functions for section-type are called just before input of the first | |
2008 argument, and functions for maketitle-type is called after maketitle-type | |
2009 command has been inserted. `Argument add-in' functions are called at each | |
2010 entry of arguments for section-type commands. | |
2011 | |
2012 @node Useful functions for creating add-in, Contribution, How the function is called, Add-in functions | |
2013 @comment node-name, next, previous, up | |
2014 @subsection Useful functions for creating add-in | |
2015 | |
2016 Many add-in functions for typical La@TeX{} commands are defined in | |
2017 @file{yatexadd.el}. Those are also useful as references. Here are the | |
2018 short descriptions on useful functions, where [F] means function, [A] | |
2019 means arguments, [D] means description. | |
2020 | |
69 | 2021 @table @kbd |
49 | 2022 @item [F] |
2023 YaTeX:read-position | |
2024 @itemx [A] | |
2025 Character list which can show up in the brackets | |
2026 @itemx [D] | |
2027 Return the location specifier such as `[htb]'. When | |
2028 nothing is entered, omit [] itself. If the possible characters | |
2029 are "htbp", call this function as | |
2030 @code{(YaTeX:read-position "htbp")} | |
2031 | |
2032 @item [F] | |
2033 YaTeX:read-coordinates | |
2034 @itemx [A] | |
2035 Base prompt, X-axis prompt, Y-axis prompt (each optional) | |
2036 @itemx [D] | |
51 | 2037 Read the coordinates with the prompt ``BasePrompt X-axisPrompt:'' for |
49 | 2038 X-axis, ``BasePrompt Y-axisPrompt:'' for Y-axis, and return it in the form |
51 | 2039 of ``(X,Y)''. The default prompts are @code{Dimension}, @code{X}, |
49 | 2040 @code{Y} respectively. |
2041 | |
2042 @item [F] | |
51 | 2043 YaTeX:check-completion-type |
49 | 2044 @itemx [A] |
2045 One of the symbols: 'begin, 'section, or 'maketitle | |
2046 @itemx [D] | |
2047 Check the current completion type is specified one and cause error if | |
2048 not. The variable @code{YaTeX-current-completion-type} holds the symbol | |
2049 according to the current completion type. | |
69 | 2050 @end table |
49 | 2051 |
2052 @node Contribution, , Useful functions for creating add-in, Add-in functions | |
2053 @comment node-name, next, previous, up | |
2054 @subsection Contribution | |
2055 | |
2056 If you make your own pretty function and you let it be in public, please | |
2057 send me the function. I'm going to include it in the next release. | |
2058 | |
2059 @node Add-in generator, , Add-in functions, Customizations | |
2060 @comment node-name, next, previous, up | |
2061 @section Add-in generator | |
20 | 2062 |
49 | 2063 First, don't forget to read the section of add-in functions @ref{Add-in |
2064 functions}. If you easily understand how to define them, there's no need | |
2065 to read this section. But being not familiar with Emacs-Lisp, when you | |
2066 don't have clear idea what to do, this section describes how to get YaTeX | |
2067 make add-in function. | |
2068 | |
2069 There are two methods of generation. One is for fully interactive | |
2070 generator for beginners and another requires little knowledge of | |
2071 Emacs-Lisp. | |
2072 | |
2073 @subsection Generator for beginners | |
2074 The former generator is called by | |
2075 @center @kbd{M-x YaTeX-generate} | |
2076 | |
2077 @noindent | |
2078 strokes. All you have to do is follow the guidances. Defying them may cases | |
2079 the disaster (I wonder what is it???). So when you make some mistake, it | |
2080 is recommendable to type @kbd{C-g} and start afresh. | |
2081 | |
2082 @subsection Simple generator | |
2083 | |
2084 The latter generator is invoked by the next sequence. | |
2085 @center @kbd{M-x YaTeX-generate-simple} | |
2086 This generator can make both ``option add-in'' and ``argument add-in'' | |
2087 (@emph{refer the section add-in functions} | |
68 | 2088 @ref{How the add-in function works}), whereas @code{YaTeX-generate} |
49 | 2089 cannot make ``argument addin''. |
2090 | |
2091 For example, assume you have the LaTeX command as follows. | |
2092 | |
2093 @example | |
2094 \epsinput[t](250,50){hoge.eps}{plain}{Picture of foo} | |
2095 (A) (B) (1) (2) (3) | |
2096 (A)Optional parameter to specify the position | |
2097 One of t(top), b(bottom), l(left), r(right) | |
2098 (B)Maximum size of frame | |
2099 (1)1st argument is filename of EPS file | |
2100 (2)2nd argument indicates | |
2101 plain do nothing | |
2102 frame make frame around image | |
2103 dframe make double-frame around image | |
2104 for included EPS file. | |
2105 (3)Caption for the picture | |
2106 @end example | |
2107 | |
2108 Now get start with generation. Typing @kbd{M-x YaTeX-generate-simple} | |
2109 brings the prompt: | |
2110 @display | |
2111 (O)ption? (A)rgument? | |
2112 @end display | |
2113 | |
2114 @subsubsection Generating ``option add-in'' | |
2115 @cindex option add-in | |
2116 | |
2117 Since (A), (B) above are optional argument, all we have to do to | |
2118 complete them is define the option add-in for them. Let's generate the | |
2119 function to complete (A). | |
2120 | |
2121 @display | |
2122 M-x YaTeX-generate-simple RET | |
2123 epsinput RET | |
2124 o | |
2125 @end display | |
2126 | |
2127 @noindent | |
2128 Typing as above leads the next prompt. | |
2129 | |
2130 @display | |
2131 Read type(1): (S)tring (C)omplete (F)ile ([)option (P)osition co(O)rd. (q)uit | |
2132 @end display | |
2133 | |
2134 @noindent | |
2135 This asks that ``Which type is the completion style of 1st argument?''. | |
2136 Here are the possible completion style. | |
2137 | |
2138 @table @code | |
2139 @item String | |
2140 read plain string | |
2141 @item Complete | |
2142 read with completion | |
2143 @item File | |
2144 read file name | |
2145 @item Option | |
2146 read optional string (if string omitted, omit [] too) | |
2147 @item Position | |
2148 read positional option (like [htbp]) | |
2149 @item Coord. | |
51 | 2150 read coordinates |
49 | 2151 @item Quit |
51 | 2152 quit from generating |
49 | 2153 @end table |
2154 | |
2155 Since (A) is the optional argument to specify the location of included | |
2156 EPS file, the completion style is @code{Position}, and the possible | |
2157 characters are t, b, l, and r. To tell these information to generator, | |
2158 operate as follows. | |
2159 | |
2160 @display | |
2161 Read type(1).... p | |
2162 Acceptable characters: tblr RET | |
2163 @end display | |
2164 | |
2165 (B) is coordinate. So its completion style is coOrd. We want a prompt | |
2166 meaning ``Maximum size'' when completion. | |
2167 | |
2168 @display | |
2169 Read type(2).... o | |
2170 Prompt for coordinates: Max size RET | |
2171 @end display | |
2172 | |
2173 That's all for optional argument. Select quit. | |
2174 | |
2175 @display | |
2176 Read type(3).... q | |
2177 @end display | |
2178 | |
2179 Then the generated option add-in function for \epsinput will be shown in | |
2180 the next window. | |
2181 | |
2182 @subsubsection Generating ``argument add-in'' | |
2183 @cindex argument add-in | |
2184 | |
2185 Next, create the argument add-in. The arguments for \epsinput are EPS | |
2186 file name, framing style, and caption string in sequence. | |
2187 | |
2188 @display | |
2189 M-x YaTeX-generate-simple RET | |
2190 epsinput RET | |
2191 a | |
2192 @end display | |
2193 | |
2194 Above key strokes bring the prompt that asks the number of argument. | |
2195 Answer it with 3. | |
2196 | |
2197 @display | |
2198 How many arguments?: 3 RET | |
2199 @end display | |
2200 | |
2201 Then the generator asks the completion style and prompt for completion. | |
2202 Answer them. @kbd{f} for FileName and prompt string. | |
2203 | |
2204 @display | |
2205 Read type(1).... f | |
2206 Prompt for argument#1 EPS file name RET | |
2207 @end display | |
2208 | |
2209 The second argument is one of selected symbol. So the completion type | |
2210 is @code{Completion}. | |
2211 | |
2212 @display | |
2213 Read type(2).... c | |
2214 Prompt for argument#2 Include style RET | |
2215 @end display | |
2216 | |
2217 Then all the candidates ready to be read. Type single RET after | |
2218 entering all. | |
2219 | |
2220 @display | |
2221 Item[1](RET to exit): plain RET | |
2222 Item[2](RET to exit): frame RET | |
2223 Item[3](RET to exit): dframe RET | |
2224 Item[4](RET to exit): RET | |
2225 @end display | |
2226 | |
2227 The following prompt asks whether the entered string must belong to | |
2228 candidates or not. In this case, since the argument must be one of | |
2229 @code{plain}, @code{frame}, and @code{dframe}, type @code{y}. | |
2230 | |
2231 @display | |
2232 Require match? (y or n) y | |
2233 @end display | |
2234 | |
2235 The last argument is the caption string for which any completion is | |
2236 needed. | |
2237 | |
2238 @display | |
2239 Read type(3).... s | |
2240 Prompt for argument#3 Caption RET | |
2241 default: Figure of RET | |
2242 @end display | |
2243 | |
2244 Finally we'll get the argument add-in in the next window. | |
2245 | |
2246 @subsection Contribution | |
2247 | |
2248 If you get your own pretty function and you let it be in public, please | |
51 | 2249 steel yourself in the happy atmosphere and do not send me the function. |
49 | 2250 I do know it is not fine because it is generated by yatexgen:-p. |
20 | 2251 |
2252 @node Etcetera, Copying, Customizations, Top | |
2253 @comment node-name, next, previous, up | |
2254 @chapter Etcetera | |
2255 | |
2256 The standard completion tables provided in @file{yatex.el} contain a | |
2257 few La@TeX{} commands I frequently use. This is to lessen the key | |
2258 strokes to complete entire word, because too many candidates | |
2259 rarely used often cause too many hits. Therefore always try to | |
2260 use completion in order to enrich your dictionary, and you will | |
2261 also find `Wild Bird' growing suitable for your La@TeX{} style. | |
2262 | |
51 | 2263 The package name `Wild Bird' is the English translation of Japanese |
2264 title `Yachou', which is a trick on words of Japanese. | |
20 | 2265 |
2266 @node Copying, , Etcetera, Top | |
2267 @comment node-name, next, previous, up | |
2268 @chapter Copying | |
2269 | |
2270 This program is distributed as a free software. You can | |
2271 redistribute this software freely but with NO warranty to anything | |
2272 as a result of using this software. However, any reports and | |
2273 suggestions are welcome as long as I feel interests in this | |
69 | 2274 software. My possible e-mail address is `yuuji@@gentei.org'. |
2275 (up to May.1999 at least) And there is mailing list for YaTeX. | |
52 | 2276 Although the common language is Japanese, questions in English will be |
2277 welcome. To join the ML, send the mail whose subject is `append' to | |
57 | 2278 the address `yatex-control@@jaist.ac.jp'. If you have some |
2279 question, please ask to `yatex-request@@jaist.ac.jp'. | |
20 | 2280 |
2281 The specification of this software will be surely modified | |
2282 (depending on my feelings) without notice :-p. | |
2283 | |
2284 | |
2285 @flushright | |
2286 HIROSE Yuuji | |
2287 @end flushright | |
2288 @bye | |
2289 | |
2290 Local variables: | |
2291 mode: texinfo | |
2292 fill-prefix: nil | |
2293 fill-column: 74 | |
2294 End: |