diff options
| author | Carsten Dominik | 1999-12-15 17:27:40 +0000 |
|---|---|---|
| committer | Carsten Dominik | 1999-12-15 17:27:40 +0000 |
| commit | d4e1eea368b4a1b48448272addd2f6b73a9977ef (patch) | |
| tree | 90b54737c7b74882901bd8476d4ee93ada0d9408 | |
| parent | 7c4d13cca61958bc3387b200450779cd50fdda11 (diff) | |
| download | emacs-d4e1eea368b4a1b48448272addd2f6b73a9977ef.tar.gz emacs-d4e1eea368b4a1b48448272addd2f6b73a9977ef.zip | |
Update to reftex 4.9
| -rw-r--r-- | man/reftex.texi | 708 |
1 files changed, 552 insertions, 156 deletions
diff --git a/man/reftex.texi b/man/reftex.texi index 8afb27d6b0a..097eed0d3f0 100644 --- a/man/reftex.texi +++ b/man/reftex.texi | |||
| @@ -9,9 +9,9 @@ | |||
| 9 | @synindex ky cp | 9 | @synindex ky cp |
| 10 | @syncodeindex vr cp | 10 | @syncodeindex vr cp |
| 11 | @syncodeindex fn cp | 11 | @syncodeindex fn cp |
| 12 | @set VERSION 4.6 | 12 | @set VERSION 4.9 |
| 13 | @set EDITION 4.6 | 13 | @set EDITION 4.9 |
| 14 | @set DATE September 1999 | 14 | @set DATE December 1999 |
| 15 | @set AUTHOR Carsten Dominik | 15 | @set AUTHOR Carsten Dominik |
| 16 | @set AUTHOR-EMAIL dominik@@strw.leidenuniv.nl | 16 | @set AUTHOR-EMAIL dominik@@strw.leidenuniv.nl |
| 17 | @set MAINTAINER Carsten Dominik | 17 | @set MAINTAINER Carsten Dominik |
| @@ -72,7 +72,7 @@ translation approved by the Free Software Foundation. | |||
| 72 | 72 | ||
| 73 | @author by Carsten Dominik | 73 | @author by Carsten Dominik |
| 74 | @page | 74 | @page |
| 75 | Copyright @copyright{} 1997, 1998 Free Software Foundation, Inc. | 75 | Copyright @copyright{} 1997, 1998, 1999 Free Software Foundation, Inc. |
| 76 | 76 | ||
| 77 | @sp 2 | 77 | @sp 2 |
| 78 | This is edition @value{EDITION} of the @cite{Ref@TeX{} User Manual} for | 78 | This is edition @value{EDITION} of the @cite{Ref@TeX{} User Manual} for |
| @@ -178,11 +178,18 @@ Citations | |||
| 178 | 178 | ||
| 179 | Index Support | 179 | Index Support |
| 180 | 180 | ||
| 181 | * Creating Index Entries:: | 181 | * Creating Index Entries:: Macros and completion of entries. |
| 182 | * Displaying and Editing the Index:: | 182 | * The Index Phrases File:: A special file for global indexing. |
| 183 | * Displaying and Editing the Index:: The index editor. | ||
| 183 | * Builtin Index Macros:: The index macros RefTeX knows about. | 184 | * Builtin Index Macros:: The index macros RefTeX knows about. |
| 184 | * Defining Index Macros:: ... and macros it doesn't. | 185 | * Defining Index Macros:: ... and macros it doesn't. |
| 185 | 186 | ||
| 187 | The Index Phrases File | ||
| 188 | |||
| 189 | * Collecting Phrases:: Collecting from document or external. | ||
| 190 | * Consistency Checks:: Check for duplicates etc. | ||
| 191 | * Global Indexing:: The interactive indexing process. | ||
| 192 | |||
| 186 | AUCTeX | 193 | AUCTeX |
| 187 | 194 | ||
| 188 | * AUCTeX-RefTeX Interface:: How both packages work together | 195 | * AUCTeX-RefTeX Interface:: How both packages work together |
| @@ -356,22 +363,24 @@ are supported.@refill | |||
| 356 | @itemize @bullet | 363 | @itemize @bullet |
| 357 | @item | 364 | @item |
| 358 | @b{Creating Index Entries}@* | 365 | @b{Creating Index Entries}@* |
| 359 | Type @kbd{C-c /} (@code{reftex-index-selection-or-word}) to index the | 366 | To index the current selection or the word at point, type @kbd{C-c /} |
| 360 | current selection or the word at the cursor with the default macro (see | 367 | (@code{reftex-index-selection-or-word}). The default macro |
| 361 | the variable @code{reftex-index-default-macro}).@* | 368 | @code{reftex-index-default-macro} will be used. For a more complex entry |
| 362 | Type @kbd{C-c <} (@code{reftex-index}) to insert a general index macro. | 369 | type @kbd{C-c <} (@code{reftex-index}), select any of the index macros |
| 363 | @b{Ref@TeX{}} will offer a list of available macros and provide | 370 | and enter the arguments with completion.@refill |
| 364 | completion for the index tag (used to identify one of multiple indices) | 371 | |
| 365 | and for the entry itself (useful with subentries). | 372 | @item |
| 366 | 373 | @b{The Index Phrases File (Delayed Indexing)}@* | |
| 367 | @refill | 374 | Type @kbd{C-c \} (@code{reftex-index-phrase-selection-or-word}) to add |
| 368 | 375 | the current word or selection to a special @emph{index phrase file}. | |
| 369 | @item | 376 | @b{Ref@TeX{}} can later search the document for occurrences of these |
| 370 | @b{Displaying the Index}@* To display the compiled index in a special | 377 | phrases and let you interactively index the matches.@refill |
| 371 | buffer, type @kbd{C-c >} (@code{reftex-display-index}). From that | 378 | |
| 372 | buffer you can check and edit all entries. The index can be restricted | 379 | @item |
| 373 | to those entries defined in a single document section or in a user | 380 | @b{Displaying and Editing the Index}@* |
| 374 | defined region.@refill | 381 | To display the compiled index in a special buffer, type @kbd{C-c >} |
| 382 | (@code{reftex-display-index}). From that buffer you can check and edit | ||
| 383 | all entries.@refill | ||
| 375 | @end itemize | 384 | @end itemize |
| 376 | 385 | ||
| 377 | @page | 386 | @page |
| @@ -381,10 +390,10 @@ When point is on the @var{key} argument of a cross--referencing macro | |||
| 381 | @code{\index}, and variations) or inside a BibTeX database entry, you | 390 | @code{\index}, and variations) or inside a BibTeX database entry, you |
| 382 | can press @kbd{C-c &} (@code{reftex-view-crossref}) to display | 391 | can press @kbd{C-c &} (@code{reftex-view-crossref}) to display |
| 383 | corresponding locations in the document and associated BibTeX database | 392 | corresponding locations in the document and associated BibTeX database |
| 384 | files.@refill @* When the enclosing macro is @code{\cite} or @code{\ref} | 393 | files.@refill @* |
| 385 | and no other message occupies the echo area, information about the | 394 | When the enclosing macro is @code{\cite} or @code{\ref} and no other |
| 386 | citation or label will automatically be displayed in the echo | 395 | message occupies the echo area, information about the citation or label |
| 387 | area.@refill | 396 | will automatically be displayed in the echo area.@refill |
| 388 | 397 | ||
| 389 | @item | 398 | @item |
| 390 | @b{Multifile Documents}@* | 399 | @b{Multifile Documents}@* |
| @@ -440,7 +449,8 @@ an AUCTeX style file to support them with both AUCTeX and | |||
| 440 | @item @b{Where Next?}@* Go ahead and use @b{Ref@TeX{}}. Use its menus | 449 | @item @b{Where Next?}@* Go ahead and use @b{Ref@TeX{}}. Use its menus |
| 441 | until you have picked up the key bindings. For an overview of what you | 450 | until you have picked up the key bindings. For an overview of what you |
| 442 | can do in each of the different special buffers, press @kbd{?}. Read | 451 | can do in each of the different special buffers, press @kbd{?}. Read |
| 443 | the manual if you get stuck. The first part of the manual explains in | 452 | the manual if you get stuck, of if you are curious what else might be |
| 453 | available. The first part of the manual explains in | ||
| 444 | a tutorial way how to use and customize @b{Ref@TeX{}}. The second | 454 | a tutorial way how to use and customize @b{Ref@TeX{}}. The second |
| 445 | part is a command and variable reference.@refill | 455 | part is a command and variable reference.@refill |
| 446 | @end enumerate | 456 | @end enumerate |
| @@ -541,6 +551,16 @@ buffer. | |||
| 541 | 551 | ||
| 542 | @tablesubheading{Controlling what gets displayed} | 552 | @tablesubheading{Controlling what gets displayed} |
| 543 | 553 | ||
| 554 | @item t | ||
| 555 | @vindex reftex-toc-max-level | ||
| 556 | Change the maximum level of toc entries displayed in the @file{*toc*} | ||
| 557 | buffer. Without prefix arg, all levels will be included. With prefix | ||
| 558 | arg (e.g @kbd{3 t}), ignore all toc entries with level greater than | ||
| 559 | @var{arg} (3 in this case). Chapters are level 1, sections are level 2. | ||
| 560 | The mode line @samp{T<>} indicator shows the current value. The default | ||
| 561 | depth can be configured with the variable | ||
| 562 | @code{reftex-toc-max-level}.@refill | ||
| 563 | |||
| 544 | @item F | 564 | @item F |
| 545 | @vindex reftex-toc-include-file-boundaries | 565 | @vindex reftex-toc-include-file-boundaries |
| 546 | Toggle the display of the file borders of a multifile document in the | 566 | Toggle the display of the file borders of a multifile document in the |
| @@ -602,12 +622,16 @@ keymap @code{reftex-toc-map} may be used.@refill | |||
| 602 | @cindex Sectioning commands | 622 | @cindex Sectioning commands |
| 603 | @cindex KOMA-Script, LaTeX classes | 623 | @cindex KOMA-Script, LaTeX classes |
| 604 | @cindex LaTeX classes, KOMA-Script | 624 | @cindex LaTeX classes, KOMA-Script |
| 625 | @cindex TOC entries for environments | ||
| 605 | @vindex reftex-section-levels | 626 | @vindex reftex-section-levels |
| 606 | The section macros recognized by @b{Ref@TeX{}} are all LaTeX section | 627 | The section macros recognized by @b{Ref@TeX{}} are all LaTeX section |
| 607 | macros (from @code{\part} to @code{\subsubparagraph}) and the commands | 628 | macros (from @code{\part} to @code{\subsubparagraph}) and the commands |
| 608 | @code{\addchap} and @code{\addsec} from the KOMA-Script classes. | 629 | @code{\addchap} and @code{\addsec} from the KOMA-Script classes. |
| 609 | Additional macros can be configured with the variable | 630 | Additional macros can be configured with the variable |
| 610 | @code{reftex-section-levels}. | 631 | @code{reftex-section-levels}. It is also possible to add certain LaTeX |
| 632 | environments to the table of contents. This is probably only useful for | ||
| 633 | theorem-like environments. @xref{Defining Label Environments}, for an | ||
| 634 | example. | ||
| 611 | 635 | ||
| 612 | @node Labels and References, Citations, Table of Contents, Top | 636 | @node Labels and References, Citations, Table of Contents, Top |
| 613 | @chapter Labels and References | 637 | @chapter Labels and References |
| @@ -882,7 +906,9 @@ Toggle the display of the file borders of a multifile document in the | |||
| 882 | selection buffer.@refill | 906 | selection buffer.@refill |
| 883 | 907 | ||
| 884 | @item t | 908 | @item t |
| 885 | Toggle the display of the table of contents in the selection buffer.@refill | 909 | Toggle the display of the table of contents in the selection buffer. |
| 910 | With prefix @var{arg}, change the maximum level of toc entries displayed | ||
| 911 | to @var{arg}. Chapters are level 1, section are level 2.@refill | ||
| 886 | 912 | ||
| 887 | @item # | 913 | @item # |
| 888 | Toggle the display of a label counter in the selection buffer.@refill | 914 | Toggle the display of a label counter in the selection buffer.@refill |
| @@ -1095,8 +1121,8 @@ library. With Lisp it would look like this | |||
| 1095 | 1121 | ||
| 1096 | @lisp | 1122 | @lisp |
| 1097 | (setq reftex-label-alist | 1123 | (setq reftex-label-alist |
| 1098 | '(("axiom" ?a "ax:" "~\\ref@{%s@}" nil ("axiom" "ax.")) | 1124 | '(("axiom" ?a "ax:" "~\\ref@{%s@}" nil ("axiom" "ax.") -2) |
| 1099 | ("theorem" ?h "thr:" "~\\ref@{%s@}" t ("theorem" "theor." "th.")))) | 1125 | ("theorem" ?h "thr:" "~\\ref@{%s@}" t ("theorem" "th.") -3))) |
| 1100 | @end lisp | 1126 | @end lisp |
| 1101 | 1127 | ||
| 1102 | The type indicator characters @code{?a} and @code{?h} are used for | 1128 | The type indicator characters @code{?a} and @code{?h} are used for |
| @@ -1130,11 +1156,19 @@ For more complex ways of getting context, see the variable | |||
| 1130 | Environments)}).@refill | 1156 | Environments)}).@refill |
| 1131 | @end itemize | 1157 | @end itemize |
| 1132 | 1158 | ||
| 1133 | The strings at the end of each entry are used to guess the correct label | 1159 | The following list of strings is used to guess the correct label type |
| 1134 | type from the word before point when creating a reference. E.g. if you | 1160 | from the word before point when creating a reference. E.g. if you |
| 1135 | write: @samp{As we have shown in Theorem} and then press @kbd{C-c )}, | 1161 | write: @samp{As we have shown in Theorem} and then press @kbd{C-c )}, |
| 1136 | @b{Ref@TeX{}} will know that you are looking for a theorem label and restrict | 1162 | @b{Ref@TeX{}} will know that you are looking for a theorem label and |
| 1137 | the menu to only these labels without even asking.@refill | 1163 | restrict the menu to only these labels without even asking.@refill |
| 1164 | |||
| 1165 | The final item in each entry is the level at which the environment | ||
| 1166 | should produce entries in the table of context buffer. If the number is | ||
| 1167 | positive, the environment will produce numbered entries (like | ||
| 1168 | @code{\section}), if it is negative the entries will be unnumbered (like | ||
| 1169 | @code{\section*}). Use this only for environments which structure the | ||
| 1170 | document similar to sectioning commands. For everything else, omit the | ||
| 1171 | item.@refill | ||
| 1138 | 1172 | ||
| 1139 | To do the same configuration with @code{customize}, you need to click on | 1173 | To do the same configuration with @code{customize}, you need to click on |
| 1140 | the @code{[INS]} button twice to create two templates and fill them in | 1174 | the @code{[INS]} button twice to create two templates and fill them in |
| @@ -1152,6 +1186,7 @@ Reftex Label Alist: [Hide] | |||
| 1152 | [INS] [DEL] String: axiom | 1186 | [INS] [DEL] String: axiom |
| 1153 | [INS] [DEL] String: ax. | 1187 | [INS] [DEL] String: ax. |
| 1154 | [INS] | 1188 | [INS] |
| 1189 | [X] Make TOC entry : [Value Menu] Level: -2 | ||
| 1155 | [INS] [DEL] Package or Detailed : [Value Menu] Detailed: | 1190 | [INS] [DEL] Package or Detailed : [Value Menu] Detailed: |
| 1156 | Environment or \macro : [Value Menu] String: theorem | 1191 | Environment or \macro : [Value Menu] String: theorem |
| 1157 | Type specification : [Value Menu] Char : h | 1192 | Type specification : [Value Menu] Char : h |
| @@ -1163,6 +1198,7 @@ Reftex Label Alist: [Hide] | |||
| 1163 | [INS] [DEL] String: theor. | 1198 | [INS] [DEL] String: theor. |
| 1164 | [INS] [DEL] String: th. | 1199 | [INS] [DEL] String: th. |
| 1165 | [INS] | 1200 | [INS] |
| 1201 | [X] Make TOC entry : [Value Menu] Level: -3 | ||
| 1166 | @end example | 1202 | @end example |
| 1167 | 1203 | ||
| 1168 | @vindex reftex-insert-label-flags | 1204 | @vindex reftex-insert-label-flags |
| @@ -1220,6 +1256,7 @@ Reftex Label Alist: [Hide] | |||
| 1220 | Context method : [Value Menu] Macro arg nr: 1 | 1256 | Context method : [Value Menu] Macro arg nr: 1 |
| 1221 | Magic words: | 1257 | Magic words: |
| 1222 | [INS] | 1258 | [INS] |
| 1259 | [ ] Make TOC entry : [Value Menu] No entry | ||
| 1223 | @end example | 1260 | @end example |
| 1224 | 1261 | ||
| 1225 | @node Figure Wrapper, Adding Magic Words, Quick Equation, Defining Label Environments | 1262 | @node Figure Wrapper, Adding Magic Words, Quick Equation, Defining Label Environments |
| @@ -1279,6 +1316,7 @@ Again, here the configuration in the customization buffer: | |||
| 1279 | Context method : [Value Menu] Macro arg nr: 3 | 1316 | Context method : [Value Menu] Macro arg nr: 3 |
| 1280 | Magic words: | 1317 | Magic words: |
| 1281 | [INS] | 1318 | [INS] |
| 1319 | [ ] Make TOC entry : [Value Menu] No entry | ||
| 1282 | @end example | 1320 | @end example |
| 1283 | 1321 | ||
| 1284 | @node Adding Magic Words, Using \eqref, Figure Wrapper, Defining Label Environments | 1322 | @node Adding Magic Words, Using \eqref, Figure Wrapper, Defining Label Environments |
| @@ -1443,8 +1481,8 @@ the entries described above: | |||
| 1443 | 1481 | ||
| 1444 | @lisp | 1482 | @lisp |
| 1445 | (setq reftex-label-alist | 1483 | (setq reftex-label-alist |
| 1446 | '(("axiom" ?a "ax:" "~\\ref@{%s@}" nil ("axiom" "ax.")) | 1484 | '(("axiom" ?a "ax:" "~\\ref@{%s@}" nil ("axiom" "ax.") -2) |
| 1447 | ("theorem" ?h "thr:" "~\\ref@{%s@}" t ("theorem" "theor." "th.")) | 1485 | ("theorem" ?h "thr:" "~\\ref@{%s@}" t ("theorem" "theor." "th.") -3) |
| 1448 | ("\\quickeq@{@}" ?e nil nil 1 nil) | 1486 | ("\\quickeq@{@}" ?e nil nil 1 nil) |
| 1449 | AMSTeX | 1487 | AMSTeX |
| 1450 | ("\\myfig[]@{@}@{@}@{*@}@{@}" ?f nil nil 3) | 1488 | ("\\myfig[]@{@}@{@}@{*@}@{@}" ?f nil nil 3) |
| @@ -1801,15 +1839,12 @@ the @kbd{C-c [} binding to the mail buffer. It also provides a local | |||
| 1801 | binding for @code{reftex-cite-format}.@refill | 1839 | binding for @code{reftex-cite-format}.@refill |
| 1802 | 1840 | ||
| 1803 | @lisp | 1841 | @lisp |
| 1804 | (add-hook | 1842 | (add-hook 'mail-setup-hook |
| 1805 | 'mail-setup-hook | 1843 | (lambda () (define-key mail-mode-map "\C-c[" |
| 1806 | (lambda () | 1844 | (lambda () (interactive) |
| 1807 | (define-key mail-mode-map "\C-c[" | 1845 | (require 'reftex) |
| 1808 | (lambda () | 1846 | (let ((reftex-cite-format 'locally)) |
| 1809 | (interactive) | 1847 | (reftex-citation)))))) |
| 1810 | (require 'reftex) | ||
| 1811 | (let ((reftex-cite-format 'locally)) | ||
| 1812 | (reftex-citation)))))) | ||
| 1813 | @end lisp | 1848 | @end lisp |
| 1814 | 1849 | ||
| 1815 | @node Index Support, Viewing Cross-References, Citations, Top | 1850 | @node Index Support, Viewing Cross-References, Citations, Top |
| @@ -1828,44 +1863,63 @@ file. A separate tool must be used to convert this information into a | |||
| 1828 | nicely formatted index. Tools used with LaTeX include @code{MakeIndex} | 1863 | nicely formatted index. Tools used with LaTeX include @code{MakeIndex} |
| 1829 | and @code{xindy}.@refill | 1864 | and @code{xindy}.@refill |
| 1830 | 1865 | ||
| 1831 | Indexing is a lot of work and must follow strict conventions, so that | 1866 | Indexing is a very difficult task. It must follow strict conventions to |
| 1832 | the same word looks the same in all index entries referencing it, and in | 1867 | make the index consistent and complete. There are basically two |
| 1833 | order to avoid spurious multiple entries. Therefore, the author of a | 1868 | approaches one can follow, and both have their merits. |
| 1834 | document will most likely define special macros to make this easier. To | 1869 | |
| 1835 | make @b{Ref@TeX{}} support for indexing possible, these special macros | 1870 | @enumerate |
| 1836 | must be added to @b{Ref@TeX{}}'s configuration (@pxref{Defining Index | 1871 | @item |
| 1837 | Macros}).@refill | 1872 | Part of the indexing should already be done with the markup. The |
| 1873 | document structure should be reflected in the index, so when starting | ||
| 1874 | new sections, the basic topics of the section should be indexed. If the | ||
| 1875 | document contains definitions, theorems or the like, these should all | ||
| 1876 | correspond to appropriate index entries. This part of the index can | ||
| 1877 | very well be developed along with the document. Often it is worthwhile | ||
| 1878 | to define special purpose macros which define an item and at the same | ||
| 1879 | time make an index entry, possibly with special formatting to make the | ||
| 1880 | reference page in the index bold or underlined. To make @b{Ref@TeX{}} | ||
| 1881 | support for indexing possible, these special macros must be added to | ||
| 1882 | @b{Ref@TeX{}}'s configuration (@pxref{Defining Index Macros}).@refill | ||
| 1883 | |||
| 1884 | @item | ||
| 1885 | The rest of the index is often just a collection of where in the | ||
| 1886 | document certain words or phrases are being used. This part is | ||
| 1887 | difficult to develop along with the document, because consistent entries | ||
| 1888 | for each occurrence are needed and are best selected when the document | ||
| 1889 | is ready. @b{Ref@TeX{}} supports this with an @emph{index phrases file} | ||
| 1890 | which collects phrases and helps indexing the phrases globally.@refill | ||
| 1891 | @end enumerate | ||
| 1892 | |||
| 1893 | Before you start, you need to make sure that @b{Ref@TeX{}} knows about | ||
| 1894 | the index style being used in the current document. @b{Ref@TeX{}} has | ||
| 1895 | builtin support for the default @code{\index} and @code{\glossary} | ||
| 1896 | macros. Other LaTeX packages, like the @file{multind} or @file{index} | ||
| 1897 | package, redefine the @code{\index} macro to have an additional | ||
| 1898 | argument, and @b{Ref@TeX{}} needs to be configured for those. A | ||
| 1899 | sufficiently new version of AUCTeX (9.10c or later) will do this | ||
| 1900 | automatically. If you really don't use AUCTeX (you should!), this | ||
| 1901 | configuration needs to be done by hand with the menu (@code{Ref->Index | ||
| 1902 | Style}), or globally for all your documents with@refill | ||
| 1903 | |||
| 1904 | @lisp | ||
| 1905 | (setq reftex-index-macros '(multind)) @r{or} | ||
| 1906 | (setq reftex-index-macros '(index)) | ||
| 1907 | @end lisp | ||
| 1838 | 1908 | ||
| 1839 | @menu | 1909 | @menu |
| 1840 | * Creating Index Entries:: | 1910 | * Creating Index Entries:: Macros and completion of entries. |
| 1841 | * Displaying and Editing the Index:: | 1911 | * The Index Phrases File:: A special file for global indexing. |
| 1912 | * Displaying and Editing the Index:: The index editor. | ||
| 1842 | * Builtin Index Macros:: The index macros RefTeX knows about. | 1913 | * Builtin Index Macros:: The index macros RefTeX knows about. |
| 1843 | * Defining Index Macros:: ... and macros it doesn't. | 1914 | * Defining Index Macros:: ... and macros it doesn't. |
| 1844 | @end menu | 1915 | @end menu |
| 1845 | 1916 | ||
| 1846 | @node Creating Index Entries, Displaying and Editing the Index, , Index Support | 1917 | @node Creating Index Entries, The Index Phrases File, , Index Support |
| 1847 | @section Creating Index Entries | 1918 | @section Creating Index Entries |
| 1848 | @cindex Creating index entries | 1919 | @cindex Creating index entries |
| 1849 | @cindex Index entries, creating | 1920 | @cindex Index entries, creating |
| 1850 | @kindex C-c < | 1921 | @kindex C-c < |
| 1851 | @findex reftex-index | 1922 | @findex reftex-index |
| 1852 | |||
| 1853 | First you need to make sure that @b{Ref@TeX{}} knows about the index | ||
| 1854 | style being used in the current document. @b{Ref@TeX{}} has builtin | ||
| 1855 | support for the default @code{\index} and @code{\glossary} macros. | ||
| 1856 | Other LaTeX packages, like the @file{multind} or @file{index} package, | ||
| 1857 | redefine the @code{\index} macro to have an additional argument, and | ||
| 1858 | @b{Ref@TeX{}} needs to be configured for those. A sufficiently new | ||
| 1859 | version of AUCTeX (9.10c or later) will do this automatically. If you | ||
| 1860 | really don't use AUCTeX (you should!), this configuration needs to be | ||
| 1861 | done by hand with the menu (@code{Ref->Index Style}), or globally for | ||
| 1862 | all your documents with | ||
| 1863 | |||
| 1864 | @lisp | ||
| 1865 | (setq reftex-index-macros '((multind)) @r{or} | ||
| 1866 | (setq reftex-index-macros '((index)) | ||
| 1867 | @end lisp | ||
| 1868 | |||
| 1869 | @kindex C-c / | 1923 | @kindex C-c / |
| 1870 | @findex reftex-index-selection-or-word | 1924 | @findex reftex-index-selection-or-word |
| 1871 | 1925 | ||
| @@ -1891,20 +1945,235 @@ index tag is a string identifying one of multiple indices. With the | |||
| 1891 | @file{multind} and @file{index} packages, this tag is the first argument | 1945 | @file{multind} and @file{index} packages, this tag is the first argument |
| 1892 | to the redefined @code{\index} macro.@refill | 1946 | to the redefined @code{\index} macro.@refill |
| 1893 | 1947 | ||
| 1894 | @findex reftex-index-globally | 1948 | @node The Index Phrases File, Displaying and Editing the Index, Creating Index Entries, Index Support |
| 1949 | @section The Index Phrases File | ||
| 1950 | @cindex Index phrase file | ||
| 1951 | @cindex Phrase file | ||
| 1952 | @kindex C-c | | ||
| 1953 | @findex reftex-index-visit-phrases-buffer | ||
| 1954 | @cindex Macro definition lines, in phrase buffer | ||
| 1955 | |||
| 1956 | @b{Ref@TeX{}} maintains a file in which phrases can be collected for | ||
| 1957 | later indexing. The file is located in the same directory as the master | ||
| 1958 | file of the document and has the extension @file{.rip} (@b{R}eftex | ||
| 1959 | @b{I}ndex @b{P}hrases). You can create or visit the file with @kbd{C-c | ||
| 1960 | |} (@code{reftex-index-visit-phrases-buffer}). If the file is empty it | ||
| 1961 | is initialized by inserting a file header which contains the definition | ||
| 1962 | of the available index macros. This list is initialized from | ||
| 1963 | @code{reftex-index-macros} (@pxref{Defining Index Macros}). You can | ||
| 1964 | edit the header as needed, but if you define new LaTeX indexing macros, | ||
| 1965 | don't forget to add them to @code{reftex-index-macros} as well. Here is | ||
| 1966 | a phrase file header example:@refill | ||
| 1967 | |||
| 1968 | @example | ||
| 1969 | % -*- mode: reftex-index-phrases -*- | ||
| 1970 | % Key Macro Format Repeat | ||
| 1971 | %---------------------------------------------------------- | ||
| 1972 | >>>INDEX_MACRO_DEFINITION: i \index@{%s@} t | ||
| 1973 | >>>INDEX_MACRO_DEFINITION: I \index*@{%s@} nil | ||
| 1974 | >>>INDEX_MACRO_DEFINITION: g \glossary@{%s@} t | ||
| 1975 | >>>INDEX_MACRO_DEFINITION: n \index*[name]@{%s@} nil | ||
| 1976 | %---------------------------------------------------------- | ||
| 1977 | @end example | ||
| 1978 | |||
| 1979 | The macro definition lines consist of a unique letter identifying a | ||
| 1980 | macro, a format string and the @var{repeat} flag, all separated by | ||
| 1981 | @key{TAB}. The format string shows how the macro is to be applied, the | ||
| 1982 | @samp{%s} will be replaced with the index entry. The repeat flag | ||
| 1983 | indicates if @var{word} is indexed by the macro as | ||
| 1984 | @samp{\index@{@var{word}@}} (@var{repeat} = @code{nil}) or as | ||
| 1985 | @samp{\index@{@var{word}@}@var{word}} (@var{repeat} = @code{t}). In the | ||
| 1986 | above example it is assumed that the macro @code{\index*@{@var{word}@}} | ||
| 1987 | already typesets its argument in the text, so that it is unnecessary to | ||
| 1988 | repeat @var{word} outside the macro.@refill | ||
| 1989 | |||
| 1990 | @menu | ||
| 1991 | * Collecting Phrases:: Collecting from document or external. | ||
| 1992 | * Consistency Checks:: Check for duplicates etc. | ||
| 1993 | * Global Indexing:: The interactive indexing process. | ||
| 1994 | @end menu | ||
| 1995 | |||
| 1996 | @node Collecting Phrases, Consistency Checks, , The Index Phrases File | ||
| 1997 | @subsection Collecting Phrases | ||
| 1998 | @cindex Collecting index phrases | ||
| 1999 | @cindex Index phrases, collection | ||
| 2000 | @cindex Phrases, collecting | ||
| 2001 | |||
| 2002 | Phrases for indexing can be collected while writing the document. The | ||
| 2003 | command @kbd{C-c \} (@code{reftex-index-phrase-selection-or-word}) | ||
| 2004 | copies the current selection (if active) or the word near point into the | ||
| 2005 | phrases buffer. It then selects this buffer, so that the phrase line | ||
| 2006 | can be edited. To return to the LaTeX document, press @kbd{C-c C-c} | ||
| 2007 | (@code{reftex-index-phrases-save-and-return}). | ||
| 2008 | |||
| 2009 | You can also prepare the list of index phrases in a different way and | ||
| 2010 | copy it into the phrases file. For example you might want to start from | ||
| 2011 | a word list of the document and remove all words which should not be | ||
| 2012 | indexed. | ||
| 1895 | 2013 | ||
| 1896 | There is also a command @code{reftex-index-globally}@footnote{This | 2014 | The phrase lines in the phrase buffer must have a specific format. |
| 1897 | function is still experimentally and may change or go away.} which | 2015 | @b{Ref@TeX{}} will use font-lock to indicate if a line has the proper |
| 1898 | copies an index entry near point to other occurrences of the same word | 2016 | format. A phrase line looks like this: |
| 1899 | in the document. @b{Ref@TeX{}} assumes that the word you want to index | ||
| 1900 | is in direct contact with the index macro, e.g. | ||
| 1901 | @samp{\index@{@var{word}@}@var{word}} or | ||
| 1902 | @samp{@var{word}\index@{@var{word}@}}. If there is no such word, it | ||
| 1903 | uses the key argument of the index macro. After making you confirm the | ||
| 1904 | precise search and replace strings, a query-replace over the entire | ||
| 1905 | document will be launched. | ||
| 1906 | 2017 | ||
| 1907 | @node Displaying and Editing the Index, Builtin Index Macros, Creating Index Entries, Index Support | 2018 | @example |
| 2019 | [@var{key}] <TABs> @var{phrase} [<TABs> @var{arg}[&&@var{arg}]... [ || @var{arg}]...] | ||
| 2020 | @end example | ||
| 2021 | |||
| 2022 | @code{<TABs>} stands for white space containing at least one @key{TAB}. | ||
| 2023 | @var{key} must be at the start of the line and is the character | ||
| 2024 | identifying one of the macros defined in the file header. It is | ||
| 2025 | optional - when omitted, the first macro definition line in the file | ||
| 2026 | will be used for this phrase. The @var{phrase} is the phrase to be | ||
| 2027 | searched for when indexing. It may contain several words separated by | ||
| 2028 | spaces. By default the search phrase is also the text entered as | ||
| 2029 | argument of the index macro. If you want the index entry to be | ||
| 2030 | different from the search phrase, enter another @key{TAB} and the index | ||
| 2031 | argument @var{arg}. If you want to have each match produce several | ||
| 2032 | index entries, separate the different index arguments with @samp{ && | ||
| 2033 | }@footnote{@samp{&&} with optional spaces, see | ||
| 2034 | @code{reftex-index-phrases-logical-and-regexp}.}. If you want to be | ||
| 2035 | able to choose at each match between several different index arguments, | ||
| 2036 | separate them with @samp{ || }@footnote{@samp{||} with optional spaces, | ||
| 2037 | see @code{reftex-index-phrases-logical-or-regexp}.}. Here is an | ||
| 2038 | example:@refill | ||
| 2039 | |||
| 2040 | @example | ||
| 2041 | %-------------------------------------------------------------------- | ||
| 2042 | I Sun | ||
| 2043 | i Planet Planets | ||
| 2044 | i Vega Stars!Vega | ||
| 2045 | Jupiter Planets!Jupiter | ||
| 2046 | i Mars Planets!Mars || Gods!Mars || Chocolate Bars!Mars | ||
| 2047 | i Pluto Planets!Pluto && Kuiper Belt Objects!Pluto | ||
| 2048 | @end example | ||
| 2049 | |||
| 2050 | |||
| 2051 | So @samp{Sun} will be indexed directly as @samp{\index*@{Sun@}}, while | ||
| 2052 | @samp{Planet} will be indexed as @samp{\index@{Planets@}Planet}. | ||
| 2053 | @samp{Vega} will be indexed as a subitem of @samp{Stars}. The | ||
| 2054 | @samp{Jupiter} line will also use the @samp{i} macro as it was the first | ||
| 2055 | macro definition in the file header (see above example). At each | ||
| 2056 | occurrence of @samp{Mars} you will be able choose between indexing it as | ||
| 2057 | a subitem of @samp{Planets}, @samp{Gods} or @samp{Chocolate Bars}. | ||
| 2058 | Finally, every occurrence of @samp{Pluto} will be indexed as | ||
| 2059 | @samp{\index@{Planets!Pluto@}\index@{Kuiper Belt Objects!Pluto@}Pluto} | ||
| 2060 | and will therefore create two different index entries.@refill | ||
| 2061 | |||
| 2062 | @node Consistency Checks, Global Indexing, Collecting Phrases, The Index Phrases File | ||
| 2063 | @subsection Consistency Checks | ||
| 2064 | @cindex Index phrases, consistency checks | ||
| 2065 | @cindex Phrases, consistency checks | ||
| 2066 | @cindex Consistency check for index phrases | ||
| 2067 | |||
| 2068 | @kindex C-c C-s | ||
| 2069 | Before indexing the phrases in the phrases buffer, they should be | ||
| 2070 | checked carefully for consistency. A first step is to sort the phrases | ||
| 2071 | alphabetically - this is done with the command @kbd{C-c C-s} | ||
| 2072 | (@code{reftex-index-sort-phrases}). It will sort all phrases in the | ||
| 2073 | buffer alphabetically by search phrase. If you want to group certain | ||
| 2074 | phrases and only sort within the groups, insert empty lines between the | ||
| 2075 | groups. Sorting will only change the sequence of phrases within each | ||
| 2076 | group (see the variable @code{reftex-index-phrases-sort-in-blocks}).@refill | ||
| 2077 | |||
| 2078 | @kindex C-c C-i | ||
| 2079 | A useful command is @kbd{C-c C-i} (@code{reftex-index-phrases-info}) | ||
| 2080 | which lists information about the phrase at point, including an example | ||
| 2081 | of how the index entry will look like and the number of expected matches | ||
| 2082 | in the document.@refill | ||
| 2083 | |||
| 2084 | @kindex C-c C-t | ||
| 2085 | Another important check is to find out if there are double or | ||
| 2086 | overlapping entries in the buffer. For example if you are first | ||
| 2087 | searching and indexing @samp{Mars} and then @samp{Planet Mars}, the | ||
| 2088 | second phrase will not match because of the index macro inserted before | ||
| 2089 | @samp{Mars} earlier. The command @kbd{C-c C-t} | ||
| 2090 | (@code{reftex-index-find-next-conflict-phrase}) finds the next phrase in | ||
| 2091 | the buffer which is either duplicate or a subphrase of another phrase. | ||
| 2092 | In order to check the whole buffer like this, start at the beginning and | ||
| 2093 | execute this command repeatedly.@refill | ||
| 2094 | |||
| 2095 | @node Global Indexing, , Consistency Checks, The Index Phrases File | ||
| 2096 | @subsection Global Indexing | ||
| 2097 | @cindex Global indexing | ||
| 2098 | @cindex Indexing, global | ||
| 2099 | @cindex Indexing, from @file{phrases} buffer | ||
| 2100 | |||
| 2101 | Once the index phrases have been collected and organized, you are set | ||
| 2102 | for global indexing. I recommend to do this only on an otherwise | ||
| 2103 | finished document. Global indexing starts from the phrases buffer. | ||
| 2104 | There are several commands which start indexing: @kbd{C-c C-x} acts on | ||
| 2105 | the current phrase line, @kbd{C-c C-r} on all lines in the current | ||
| 2106 | region and @kbd{C-c C-a} on all phrase lines in the buffer. It is | ||
| 2107 | probably good to do indexing in small chunks since your concentration | ||
| 2108 | may not last long enough to do everything in one go.@refill | ||
| 2109 | |||
| 2110 | @b{Ref@TeX{}} will start at the first phrase line and search the phrase | ||
| 2111 | globally in the whole document. At each match it will stop, compute the | ||
| 2112 | replacement string and offer you the following choices@footnote{Windows | ||
| 2113 | users: Restrict yourself to the described keys during indexing. Pressing | ||
| 2114 | @key{Help} at the indexing prompt can apparently hang Emacs.}:@refill | ||
| 2115 | |||
| 2116 | @table @kbd | ||
| 2117 | @item y | ||
| 2118 | Replace this match with the proposed string. | ||
| 2119 | @item n | ||
| 2120 | Skip this match. | ||
| 2121 | @item ! | ||
| 2122 | Replace this and all further matches in this file. | ||
| 2123 | @item q | ||
| 2124 | Skip this match, start with next file. | ||
| 2125 | @item Q | ||
| 2126 | Skip this match, start with next phrase. | ||
| 2127 | @item o | ||
| 2128 | Select a different indexing macro for this match. | ||
| 2129 | @item 1-9 | ||
| 2130 | Select one of multiple index keys (those separated with @samp{||}). | ||
| 2131 | @item e | ||
| 2132 | Edit the replacement text. | ||
| 2133 | @item C-r | ||
| 2134 | Recursive edit. Use @kbd{M-C-c} to return to the indexing process. | ||
| 2135 | @item s | ||
| 2136 | Save this buffer and ask again about the current match. | ||
| 2137 | @item S | ||
| 2138 | Save all document buffers and ask again about the current match. | ||
| 2139 | @item C-g | ||
| 2140 | Abort the indexing process. | ||
| 2141 | @end table | ||
| 2142 | |||
| 2143 | The @samp{Find and Index in Document} menu in the phrases buffer also | ||
| 2144 | lists a few options for the indexing process. The options have | ||
| 2145 | associated customization variables to set the defaults (@pxref{Options | ||
| 2146 | (Index Support)}). Here is a short explanation of what the options do: | ||
| 2147 | |||
| 2148 | @table @i | ||
| 2149 | @item Match Whole Words | ||
| 2150 | When searching for index phrases, make sure whole words are matched. | ||
| 2151 | This should probably always be on. | ||
| 2152 | @item Case Sensitive Search | ||
| 2153 | Search case sensitively for phrases. I recommend to have this setting | ||
| 2154 | off, in order to match the capitalized words at the beginning of a | ||
| 2155 | sentence, and even typos. You can always say @emph{no} at a match you | ||
| 2156 | do not like. | ||
| 2157 | @item Wrap Long Lines | ||
| 2158 | Inserting index macros increases the line length. Turn this option on | ||
| 2159 | to allow @b{Ref@TeX{}} to wrap long lines. | ||
| 2160 | @item Skip Indexed Matches | ||
| 2161 | When this is on, @b{Ref@TeX{}} will at each match try to figure out if | ||
| 2162 | this match is already indexed. A match is considered indexed if it is | ||
| 2163 | either the argument of an index macro, or if an index macro is directly | ||
| 2164 | (without whitespace separation) before or after the match. Index macros | ||
| 2165 | are those configured in @code{reftex-index-macros}. Intended for | ||
| 2166 | re-indexing a documents after changes have been made.@refill | ||
| 2167 | @end table | ||
| 2168 | |||
| 2169 | Even though indexing should be the last thing you do to a document, you | ||
| 2170 | are bound to make changes afterwards. Indexing then has to be applied | ||
| 2171 | to the changed regions. The command | ||
| 2172 | @code{reftex-index-phrases-apply-to-region} is designed for this | ||
| 2173 | purpose. When called from a LaTeX document with active region, it will | ||
| 2174 | apply @code{reftex-index-all-phrases} to the current region.@refill | ||
| 2175 | |||
| 2176 | @node Displaying and Editing the Index, Builtin Index Macros, The Index Phrases File, Index Support | ||
| 1908 | @section Displaying and Editing the Index | 2177 | @section Displaying and Editing the Index |
| 1909 | @cindex Displaying the Index | 2178 | @cindex Displaying the Index |
| 1910 | @cindex Editing the Index | 2179 | @cindex Editing the Index |
| @@ -1926,8 +2195,8 @@ index. To restrict to the current section, use a numeric prefix | |||
| 1926 | @samp{2}, thus press @kbd{C-u 2 C-c >}. To restrict to the current | 2195 | @samp{2}, thus press @kbd{C-u 2 C-c >}. To restrict to the current |
| 1927 | region, make the region active and use a numeric prefix @samp{3} (press | 2196 | region, make the region active and use a numeric prefix @samp{3} (press |
| 1928 | @kbd{C-u 3 C-c >}). From within the @file{*Index*} buffer the | 2197 | @kbd{C-u 3 C-c >}). From within the @file{*Index*} buffer the |
| 1929 | restriction can be moved from one section to the next with the @kbd{<} | 2198 | restriction can be moved from one section to the next by pressing the |
| 1930 | and @kbd{>} keys.@refill | 2199 | @kbd{<} and @kbd{>} keys.@refill |
| 1931 | 2200 | ||
| 1932 | One caveat: @b{Ref@TeX{}} finds the definition point of an index entry | 2201 | One caveat: @b{Ref@TeX{}} finds the definition point of an index entry |
| 1933 | by searching near the buffer position where it had found to macro during | 2202 | by searching near the buffer position where it had found to macro during |
| @@ -1973,7 +2242,7 @@ window.@refill | |||
| 1973 | 2242 | ||
| 1974 | @item @key{RET} | 2243 | @item @key{RET} |
| 1975 | Go to the definition of the current index entry and hide the | 2244 | Go to the definition of the current index entry and hide the |
| 1976 | @file{*Index*} buffer.@refill | 2245 | @file{*Index*} buffer window.@refill |
| 1977 | 2246 | ||
| 1978 | @item f | 2247 | @item f |
| 1979 | @vindex reftex-index-follow-mode | 2248 | @vindex reftex-index-follow-mode |
| @@ -2030,13 +2299,6 @@ Remove the highest superordinate entry. If the current entry is a | |||
| 2030 | subitem (@samp{aaa!bbb!ccc}), this function moves it up the hierarchy | 2299 | subitem (@samp{aaa!bbb!ccc}), this function moves it up the hierarchy |
| 2031 | (@samp{bbb!ccc}).@refill | 2300 | (@samp{bbb!ccc}).@refill |
| 2032 | 2301 | ||
| 2033 | @item & | ||
| 2034 | Globalize the current entry. This runs a search-and-replace through the | ||
| 2035 | entire document in order to index the same word at other places. Rescan | ||
| 2036 | the document in order to get the new entries into the index buffer. For | ||
| 2037 | details, see the command @code{reftex-index-globally}, | ||
| 2038 | @ref{Commands}.@refill | ||
| 2039 | |||
| 2040 | @tablesubheading{Exiting} | 2302 | @tablesubheading{Exiting} |
| 2041 | @item q | 2303 | @item q |
| 2042 | Hide the @file{*Index*} buffer.@refill | 2304 | Hide the @file{*Index*} buffer.@refill |
| @@ -2056,7 +2318,7 @@ default for this flag can be set with the variable | |||
| 2056 | 2318 | ||
| 2057 | @item @} | 2319 | @item @} |
| 2058 | Restrict the index to a single document section. The corresponding | 2320 | Restrict the index to a single document section. The corresponding |
| 2059 | section number will be displayed in the @code{R<>} indication in the | 2321 | section number will be displayed in the @code{R<>} indicator in the |
| 2060 | mode line and in the header of the @file{*Index*} buffer.@refill | 2322 | mode line and in the header of the @file{*Index*} buffer.@refill |
| 2061 | 2323 | ||
| 2062 | @item @{ | 2324 | @item @{ |
| @@ -2104,8 +2366,8 @@ indices).@refill | |||
| 2104 | 2366 | ||
| 2105 | @b{Ref@TeX{}} by default recognizes the @code{\index} and | 2367 | @b{Ref@TeX{}} by default recognizes the @code{\index} and |
| 2106 | @code{\glossary} macros which are defined in the LaTeX core. It has | 2368 | @code{\glossary} macros which are defined in the LaTeX core. It has |
| 2107 | also builtin support for the re-implementations of the @code{\index} | 2369 | also builtin support for the re-implementations of @code{\index} |
| 2108 | macro of the @file{multind} and @file{index} packages. However, since | 2370 | in the @file{multind} and @file{index} packages. However, since |
| 2109 | the different definitions of the @code{\index} macro are incompatible, | 2371 | the different definitions of the @code{\index} macro are incompatible, |
| 2110 | you will have to explicitly specify the index style used. | 2372 | you will have to explicitly specify the index style used. |
| 2111 | @xref{Creating Index Entries}, for information on how to do that. | 2373 | @xref{Creating Index Entries}, for information on how to do that. |
| @@ -2137,9 +2399,9 @@ macros, first with Emacs Lisp. | |||
| 2137 | 2399 | ||
| 2138 | @lisp | 2400 | @lisp |
| 2139 | (setq reftex-index-macros | 2401 | (setq reftex-index-macros |
| 2140 | '(("\\ix@{*@}" "idx" ?x "" nil) | 2402 | '(("\\ix@{*@}" "idx" ?x "" nil nil) |
| 2141 | ("\\nindex@{*@}" "name" ?n "" nil) | 2403 | ("\\nindex@{*@}" "name" ?n "" nil nil) |
| 2142 | ("\\astobj@{*@}" "idx" ?o "Astronomical Objects!" nil))) | 2404 | ("\\astobj@{*@}" "idx" ?o "Astronomical Objects!" nil t))) |
| 2143 | @end lisp | 2405 | @end lisp |
| 2144 | 2406 | ||
| 2145 | Note that the index tag is @samp{idx} for the main index, and | 2407 | Note that the index tag is @samp{idx} for the main index, and |
| @@ -2156,6 +2418,15 @@ respectively. | |||
| 2156 | The following string is empty unless your macro adds a superordinate | 2418 | The following string is empty unless your macro adds a superordinate |
| 2157 | entry to the index key - this is the case for the @code{\astobj} macro. | 2419 | entry to the index key - this is the case for the @code{\astobj} macro. |
| 2158 | 2420 | ||
| 2421 | The next entry can be a hook function to exclude certain matches, it | ||
| 2422 | almost always can be @code{nil}. | ||
| 2423 | |||
| 2424 | The final element in the list indicates if the text being indexed needs | ||
| 2425 | to be repeated outside the macro. For the normal index macros, this | ||
| 2426 | should be @code{t}. Only if the macro typesets the entry in the text | ||
| 2427 | (like @code{\ix} and @code{\nindex} in the example do), this should be | ||
| 2428 | @code{nil}. | ||
| 2429 | |||
| 2159 | To do the same thing with customize, you need to fill in the templates | 2430 | To do the same thing with customize, you need to fill in the templates |
| 2160 | like this: | 2431 | like this: |
| 2161 | 2432 | ||
| @@ -2167,18 +2438,21 @@ Repeat: | |||
| 2167 | Access Key : x | 2438 | Access Key : x |
| 2168 | Key Prefix : | 2439 | Key Prefix : |
| 2169 | Exclusion hook : nil | 2440 | Exclusion hook : nil |
| 2441 | Repeat Outside : [Toggle] off (nil) | ||
| 2170 | [INS] [DEL] List: | 2442 | [INS] [DEL] List: |
| 2171 | Macro with args: \nindex@{*@} | 2443 | Macro with args: \nindex@{*@} |
| 2172 | Index Tag : [Value Menu] String: name | 2444 | Index Tag : [Value Menu] String: name |
| 2173 | Access Key : n | 2445 | Access Key : n |
| 2174 | Key Prefix : | 2446 | Key Prefix : |
| 2175 | Exclusion hook : nil | 2447 | Exclusion hook : nil |
| 2448 | Repeat Outside : [Toggle] off (nil) | ||
| 2176 | [INS] [DEL] List: | 2449 | [INS] [DEL] List: |
| 2177 | Macro with args: \astobj@{*@} | 2450 | Macro with args: \astobj@{*@} |
| 2178 | Index Tag : [Value Menu] String: idx | 2451 | Index Tag : [Value Menu] String: idx |
| 2179 | Access Key : o | 2452 | Access Key : o |
| 2180 | Key Prefix : Astronomical Objects! | 2453 | Key Prefix : Astronomical Objects! |
| 2181 | Exclusion hook : nil | 2454 | Exclusion hook : nil |
| 2455 | Repeat Outside : [Toggle] on (non-nil) | ||
| 2182 | [INS] | 2456 | [INS] |
| 2183 | @end example | 2457 | @end example |
| 2184 | 2458 | ||
| @@ -2187,15 +2461,13 @@ macro used for indexing a text phrase (@pxref{Creating Index Entries}). | |||
| 2187 | This would be done like this | 2461 | This would be done like this |
| 2188 | 2462 | ||
| 2189 | @lisp | 2463 | @lisp |
| 2190 | (setq reftex-index-default-macro '(?x "idx" nil)) | 2464 | (setq reftex-index-default-macro '(?x "idx")) |
| 2191 | @end lisp | 2465 | @end lisp |
| 2192 | 2466 | ||
| 2193 | which specifies that the macro identified with the character @code{?x} (the | 2467 | which specifies that the macro identified with the character @code{?x} (the |
| 2194 | @code{\ix} macro) should be used for indexing phrases and words already | 2468 | @code{\ix} macro) should be used for indexing phrases and words already |
| 2195 | in the buffer with @kbd{C-c /} (@code{reftex-index-selection-or-word}). | 2469 | in the buffer with @kbd{C-c /} (@code{reftex-index-selection-or-word}). |
| 2196 | The index tag is "idx", and the final @code{nil} means that it is not | 2470 | The index tag is "idx".@refill |
| 2197 | necessary to repeat the phrase outside the macro, because the macro | ||
| 2198 | indexes @emph{and} typesets is argument. | ||
| 2199 | 2471 | ||
| 2200 | @node Viewing Cross-References, RefTeXs Menu, Index Support, Top | 2472 | @node Viewing Cross-References, RefTeXs Menu, Index Support, Top |
| 2201 | @chapter Viewing Cross--References | 2473 | @chapter Viewing Cross--References |
| @@ -2301,6 +2573,8 @@ Here is a summary of the available keybindings. | |||
| 2301 | @kindex C-c & | 2573 | @kindex C-c & |
| 2302 | @kindex S-mouse-2 | 2574 | @kindex S-mouse-2 |
| 2303 | @kindex C-c / | 2575 | @kindex C-c / |
| 2576 | @kindex C-c \ | ||
| 2577 | @kindex C-c | | ||
| 2304 | @kindex C-c < | 2578 | @kindex C-c < |
| 2305 | @kindex C-c > | 2579 | @kindex C-c > |
| 2306 | @example | 2580 | @example |
| @@ -2311,6 +2585,8 @@ Here is a summary of the available keybindings. | |||
| 2311 | @kbd{C-c &} @code{reftex-view-crossref} | 2585 | @kbd{C-c &} @code{reftex-view-crossref} |
| 2312 | @kbd{S-mouse-2} @code{reftex-mouse-view-crossref} | 2586 | @kbd{S-mouse-2} @code{reftex-mouse-view-crossref} |
| 2313 | @kbd{C-c /} @code{reftex-index-selection-or-word} | 2587 | @kbd{C-c /} @code{reftex-index-selection-or-word} |
| 2588 | @kbd{C-c \} @code{reftex-index-phrase-selection-or-word} | ||
| 2589 | @kbd{C-c |} @code{reftex-index-visit-phrases-buffer} | ||
| 2314 | @kbd{C-c <} @code{reftex-index} | 2590 | @kbd{C-c <} @code{reftex-index} |
| 2315 | @kbd{C-c >} @code{reftex-display-index} | 2591 | @kbd{C-c >} @code{reftex-display-index} |
| 2316 | @end example | 2592 | @end example |
| @@ -2795,7 +3071,7 @@ with @code{\newtheorem} might use@refill | |||
| 2795 | (if (fboundp 'reftex-add-label-environments) | 3071 | (if (fboundp 'reftex-add-label-environments) |
| 2796 | (reftex-add-label-environments | 3072 | (reftex-add-label-environments |
| 2797 | '(("proposition" ?p "prop:" "~\\ref@{%s@}" t | 3073 | '(("proposition" ?p "prop:" "~\\ref@{%s@}" t |
| 2798 | ("Proposition" "Prop."))))))) | 3074 | ("Proposition" "Prop.") -3)))))) |
| 2799 | @end group | 3075 | @end group |
| 2800 | @end lisp | 3076 | @end lisp |
| 2801 | 3077 | ||
| @@ -2843,8 +3119,8 @@ you could write this in the style file @file{myindex.el}: | |||
| 2843 | '("aindex" TeX-arg-index)) | 3119 | '("aindex" TeX-arg-index)) |
| 2844 | (if (fboundp 'reftex-add-index-macros) | 3120 | (if (fboundp 'reftex-add-index-macros) |
| 2845 | (reftex-add-index-macros | 3121 | (reftex-add-index-macros |
| 2846 | '(("molec@{*@}" "idx" ?m "Molecules!" nil) | 3122 | '(("molec@{*@}" "idx" ?m "Molecules!" nil nil) |
| 2847 | ("aindex@{*@}" "author" ?a "" nil)))))) | 3123 | ("aindex@{*@}" "author" ?a "" nil nil)))))) |
| 2848 | @end lisp | 3124 | @end lisp |
| 2849 | 3125 | ||
| 2850 | @findex reftex-add-section-levels | 3126 | @findex reftex-add-section-levels |
| @@ -2868,7 +3144,7 @@ is a style file @file{foils.el} that will inform @b{Ref@TeX{}} about these: | |||
| 2868 | 3144 | ||
| 2869 | Once you have written a document with labels, references and citations, | 3145 | Once you have written a document with labels, references and citations, |
| 2870 | it can be nice to read it like a hypertext document. @b{Ref@TeX{}} has | 3146 | it can be nice to read it like a hypertext document. @b{Ref@TeX{}} has |
| 2871 | some support for that: @code{reftex-view-crossref} (bound to @kbd{C-c | 3147 | support for that: @code{reftex-view-crossref} (bound to @kbd{C-c |
| 2872 | &}), @code{reftex-mouse-view-crossref} (bound to @kbd{S-mouse-2}), and | 3148 | &}), @code{reftex-mouse-view-crossref} (bound to @kbd{S-mouse-2}), and |
| 2873 | @code{reftex-search-document}. A somewhat fancier interface with mouse | 3149 | @code{reftex-search-document}. A somewhat fancier interface with mouse |
| 2874 | highlighting is provided (among other things) by Peter S. Galbraith's | 3150 | highlighting is provided (among other things) by Peter S. Galbraith's |
| @@ -2984,8 +3260,8 @@ We need to trick @b{Ref@TeX{}} into swallowing this: | |||
| 2984 | @group | 3260 | @group |
| 2985 | ;; Configuration for Lamport's pf.sty | 3261 | ;; Configuration for Lamport's pf.sty |
| 2986 | (setq reftex-label-alist | 3262 | (setq reftex-label-alist |
| 2987 | '(("\\step@{*@}@{@}" ?p "st:" "~\\stepref@{%s@}" 2 ("Step" "St.")) | 3263 | '(("\\step@{*@}@{@}" ?p "st:" "~\\stepref@{%s@}" 2 ("Step" "St.")) |
| 2988 | ("\\begin@{step+@}@{*@}" ?p "st:" "~\\stepref@{%s@}" 1000))) | 3264 | ("\\begin@{step+@}@{*@}" ?p "st:" "~\\stepref@{%s@}" 1000))) |
| 2989 | @end group | 3265 | @end group |
| 2990 | @end lisp | 3266 | @end lisp |
| 2991 | 3267 | ||
| @@ -3068,12 +3344,12 @@ webpage}. Note that the Emacs 19 version supports many but not all | |||
| 3068 | features described in this manual.@refill | 3344 | features described in this manual.@refill |
| 3069 | 3345 | ||
| 3070 | Thanks to the people on the Net who have used @b{Ref@TeX{}} and helped | 3346 | Thanks to the people on the Net who have used @b{Ref@TeX{}} and helped |
| 3071 | developing it with their reports. In particular thanks to | 3347 | developing it with their reports. In particular thanks to @i{Fran |
| 3072 | @i{Fran Burstall, Alastair Burt, Soren Dayton, Stephen Eglen, Karl | 3348 | Burstall, Alastair Burt, Soren Dayton, Stephen Eglen, Karl Eichwalder, |
| 3073 | Eichwalder, Peter Galbraith, Kai Grossjohann, Dieter Kraft, Adrian Lanz, | 3349 | Peter Galbraith, Kai Grossjohann, Frank Harrell, Dieter Kraft, Adrian |
| 3074 | Rory Molinari, Stefan Monnier, Laurent Mugnier, Sudeep Kumar Palat, | 3350 | Lanz, Rory Molinari, Stefan Monnier, Laurent Mugnier, Sudeep Kumar |
| 3075 | Daniel Polani, Robin Socha, Richard Stanton, Allan Strand, Jan Vroonhof, | 3351 | Palat, Daniel Polani, Robin Socha, Richard Stanton, Allan Strand, Jan |
| 3076 | Christoph Wedler, Alan Williams}.@refill | 3352 | Vroonhof, Christoph Wedler, Alan Williams}.@refill |
| 3077 | 3353 | ||
| 3078 | The @code{view-crossref} feature was inspired by @i{Peter Galbraith's} | 3354 | The @code{view-crossref} feature was inspired by @i{Peter Galbraith's} |
| 3079 | @file{bib-cite.el}.@refill | 3355 | @file{bib-cite.el}.@refill |
| @@ -3086,8 +3362,10 @@ MicroEmacs at the time).@refill | |||
| 3086 | @chapter Commands | 3362 | @chapter Commands |
| 3087 | @cindex Commands, list of | 3363 | @cindex Commands, list of |
| 3088 | 3364 | ||
| 3089 | Here is a summary of @b{Ref@TeX{}}'s commands. All commands are available | 3365 | Here is a summary of @b{Ref@TeX{}}'s commands which can be executed from |
| 3090 | from the @code{Ref} menu. For keybindings, @pxref{Keybindings}. | 3366 | LaTeX files. Command which are executed from the special buffers are |
| 3367 | not described here. All commands are available from the @code{Ref} | ||
| 3368 | menu. For keybindings, @pxref{Keybindings}. | ||
| 3091 | 3369 | ||
| 3092 | @deffn Command reftex-toc | 3370 | @deffn Command reftex-toc |
| 3093 | Show the table of contents for the current document. When called with | 3371 | Show the table of contents for the current document. When called with |
| @@ -3143,6 +3421,24 @@ library which is part of AUCTeX, the string is first processed with the | |||
| 3143 | @code{reftex-index-math-format}, which see.@refill | 3421 | @code{reftex-index-math-format}, which see.@refill |
| 3144 | @end deffn | 3422 | @end deffn |
| 3145 | 3423 | ||
| 3424 | @deffn Command reftex-index-phrase-selection-or-word | ||
| 3425 | Add current selection or the word at point to the phrases buffer. | ||
| 3426 | When you are in transient-mark-mode and the region is active, the | ||
| 3427 | selection will be used - otherwise the word at point. | ||
| 3428 | You get a chance to edit the entry in the phrases buffer - to save the | ||
| 3429 | buffer and return to the LaTeX document, finish with @kbd{C-c C-c}. | ||
| 3430 | @end deffn | ||
| 3431 | |||
| 3432 | @deffn Command reftex-index-visit-phrases-buffer | ||
| 3433 | Switch to the phrases buffer, initialize if empty. | ||
| 3434 | @end deffn | ||
| 3435 | |||
| 3436 | @deffn Command reftex-index-phrases-apply-to-region | ||
| 3437 | Index all index phrases in the current region. | ||
| 3438 | This works exactly like global indexing from the index phrases buffer, | ||
| 3439 | but operation is restricted to the current region. | ||
| 3440 | @end deffn | ||
| 3441 | |||
| 3146 | @deffn Command reftex-display-index | 3442 | @deffn Command reftex-display-index |
| 3147 | Display a buffer with an index compiled from the current document. | 3443 | Display a buffer with an index compiled from the current document. |
| 3148 | When the document has multiple indices, first prompts for the correct one. | 3444 | When the document has multiple indices, first prompts for the correct one. |
| @@ -3152,21 +3448,6 @@ With prefix 2, restrict index to current document section. | |||
| 3152 | With prefix 3, restrict index to active region.@refill | 3448 | With prefix 3, restrict index to active region.@refill |
| 3153 | @end deffn | 3449 | @end deffn |
| 3154 | 3450 | ||
| 3155 | @deffn Command reftex-index-globally | ||
| 3156 | Index a word with a global search and replace. This works very much | ||
| 3157 | like @code{reftex-query-replace-document}, but the defaults for the | ||
| 3158 | search and replace strings are derived from local context. When there | ||
| 3159 | is an index entry, we try to index similar words. The word to search | ||
| 3160 | for is the word in direct contact with the index macro (like | ||
| 3161 | @samp{\index@{@var{word}@}@var{word}} or | ||
| 3162 | @samp{@var{word}\index@{@var{word}@}}). If there is no such word, we | ||
| 3163 | use the the index key. The replacement text is the index macro with all | ||
| 3164 | its arguments and the attached word. When there is no index entry at | ||
| 3165 | point, we search for the word near point and propose to index it like | ||
| 3166 | this: @samp{\index@{@var{word}@}@var{word}}. You get a chance to edit | ||
| 3167 | the search and replacement strings.@refill | ||
| 3168 | @end deffn | ||
| 3169 | |||
| 3170 | @deffn Command reftex-view-crossref | 3451 | @deffn Command reftex-view-crossref |
| 3171 | View cross reference of macro at point. Point must be on the @var{key} | 3452 | View cross reference of macro at point. Point must be on the @var{key} |
| 3172 | argument. Works with the macros @code{\label}, @code{\ref}, | 3453 | argument. Works with the macros @code{\label}, @code{\ref}, |
| @@ -3278,6 +3559,13 @@ reftex-customize} will get you there.@refill | |||
| 3278 | @cindex Options, table of contents | 3559 | @cindex Options, table of contents |
| 3279 | @cindex Table of contents, options | 3560 | @cindex Table of contents, options |
| 3280 | 3561 | ||
| 3562 | @defopt reftex-toc-max-level | ||
| 3563 | The maximum level of toc entries which will be included in the TOC. | ||
| 3564 | Section headings with a bigger level will be ignored. In RefTeX, | ||
| 3565 | chapters are level 1, sections level 2 etc. This variable can be | ||
| 3566 | changed from within the @file{*toc*} buffer with the @kbd{t} key.@refill | ||
| 3567 | @end defopt | ||
| 3568 | |||
| 3281 | @defopt reftex-toc-keep-other-windows | 3569 | @defopt reftex-toc-keep-other-windows |
| 3282 | Non-@code{nil} means, split the selected window to display the | 3570 | Non-@code{nil} means, split the selected window to display the |
| 3283 | @file{*toc*} buffer. This helps to keep the window configuration, but | 3571 | @file{*toc*} buffer. This helps to keep the window configuration, but |
| @@ -3352,7 +3640,7 @@ itself and has the following structure: | |||
| 3352 | 3640 | ||
| 3353 | @example | 3641 | @example |
| 3354 | (@var{env-or-macro} @var{type-key} @var{label-prefix} @var{reference-format} | 3642 | (@var{env-or-macro} @var{type-key} @var{label-prefix} @var{reference-format} |
| 3355 | @var{context-method} (@var{magic-word} ... )) | 3643 | @var{context-method} (@var{magic-word} ... ) @var{toc-level}) |
| 3356 | @end example | 3644 | @end example |
| 3357 | 3645 | ||
| 3358 | Each list entry describes either an environment carrying a counter for | 3646 | Each list entry describes either an environment carrying a counter for |
| @@ -3478,8 +3766,16 @@ the word before point is equal to one of these words when calling | |||
| 3478 | @code{reftex-reference}, the label list offered will be automatically | 3766 | @code{reftex-reference}, the label list offered will be automatically |
| 3479 | restricted to labels of the correct type. If the first element of this | 3767 | restricted to labels of the correct type. If the first element of this |
| 3480 | word--list is the symbol `regexp', the strings are interpreted as regular | 3768 | word--list is the symbol `regexp', the strings are interpreted as regular |
| 3481 | expressions@footnote{Careful: @b{Ref@TeX{}} will add stuff to the | 3769 | expressions.@refill |
| 3482 | beginning and end of these regular expressions.}.@refill | 3770 | |
| 3771 | @item @var{toc-level} | ||
| 3772 | The integer level at which this environment should be added to the table | ||
| 3773 | of contents. See also @code{reftex-section-levels}. A positive value | ||
| 3774 | will number the entries mixed with the sectioning commands of the same | ||
| 3775 | level. A negative value will make unnumbered entries. Useful only for | ||
| 3776 | theorem-like environments which structure the document. Will be ignored | ||
| 3777 | for macros. When omitted or @code{nil}, no TOC entries will be | ||
| 3778 | made.@refill | ||
| 3483 | @end table | 3779 | @end table |
| 3484 | 3780 | ||
| 3485 | If the type indicator characters of two or more entries are the same, | 3781 | If the type indicator characters of two or more entries are the same, |
| @@ -3507,7 +3803,7 @@ Commands and levels used for defining sections in the document. The | |||
| 3507 | @code{car} of each cons cell is the name of the section macro. The | 3803 | @code{car} of each cons cell is the name of the section macro. The |
| 3508 | @code{cdr} is a number indicating its level. A negative level means the | 3804 | @code{cdr} is a number indicating its level. A negative level means the |
| 3509 | same as the positive value, but the section will never get a | 3805 | same as the positive value, but the section will never get a |
| 3510 | number. The @code{cdr} amy also be a function which then has to return | 3806 | number. The @code{cdr} may also be a function which then has to return |
| 3511 | the level.@refill | 3807 | the level.@refill |
| 3512 | @end defopt | 3808 | @end defopt |
| 3513 | 3809 | ||
| @@ -3923,7 +4219,7 @@ correspond to the @code{MakeIndex} keywords | |||
| 3923 | List of macros which define index entries. The structure of each entry | 4219 | List of macros which define index entries. The structure of each entry |
| 3924 | is | 4220 | is |
| 3925 | @lisp | 4221 | @lisp |
| 3926 | (@var{macro} @var{index-tag} @var{key} @var{prefix} @var{exclude}) | 4222 | (@var{macro} @var{index-tag} @var{key} @var{prefix} @var{exclude} @var{repeat}) |
| 3927 | @end lisp | 4223 | @end lisp |
| 3928 | 4224 | ||
| 3929 | @var{macro} is the macro. Arguments should be denoted by empty braces, | 4225 | @var{macro} is the macro. Arguments should be denoted by empty braces, |
| @@ -3949,6 +4245,11 @@ non-nil value, the index entry at point is ignored. This was | |||
| 3949 | implemented to support the (deprecated) @samp{^} and @samp{_} shortcuts | 4245 | implemented to support the (deprecated) @samp{^} and @samp{_} shortcuts |
| 3950 | in the LaTeX2e @code{index} package.@refill | 4246 | in the LaTeX2e @code{index} package.@refill |
| 3951 | 4247 | ||
| 4248 | @var{repeat}, if non-@code{nil}, means the index macro does not typeset | ||
| 4249 | the entry in the text, so that the text has to be repeated outside the | ||
| 4250 | index macro. Needed for @code{reftex-index-selection-or-word} and for | ||
| 4251 | indexing from the phrase buffer.@refill | ||
| 4252 | |||
| 3952 | The final entry may also be a symbol. It must have an association in | 4253 | The final entry may also be a symbol. It must have an association in |
| 3953 | the variable @code{reftex-index-macros-builtin} to specify the main | 4254 | the variable @code{reftex-index-macros-builtin} to specify the main |
| 3954 | indexing package you are using. Legal values are currently@refill | 4255 | indexing package you are using. Legal values are currently@refill |
| @@ -3966,7 +4267,7 @@ package here. | |||
| 3966 | 4267 | ||
| 3967 | @defopt reftex-index-default-macro | 4268 | @defopt reftex-index-default-macro |
| 3968 | The default index macro for @code{reftex-index-selection-or-word}. | 4269 | The default index macro for @code{reftex-index-selection-or-word}. |
| 3969 | This is a list with @code{(@var{macro-key} @var{default-tag} @var{repeat-word})}. | 4270 | This is a list with @code{(@var{macro-key} @var{default-tag})}. |
| 3970 | 4271 | ||
| 3971 | @var{macro-key} is a character identifying an index macro - see | 4272 | @var{macro-key} is a character identifying an index macro - see |
| 3972 | @code{reftex-index-macros}. | 4273 | @code{reftex-index-macros}. |
| @@ -3975,11 +4276,7 @@ This is a list with @code{(@var{macro-key} @var{default-tag} @var{repeat-word})} | |||
| 3975 | @var{tag} argument. When this is @code{nil} and a @var{tag} is needed, | 4276 | @var{tag} argument. When this is @code{nil} and a @var{tag} is needed, |
| 3976 | @b{Ref@TeX{}} will ask for it. When this is the empty string and the | 4277 | @b{Ref@TeX{}} will ask for it. When this is the empty string and the |
| 3977 | TAG argument of the index macro is optional, the TAG argument will be | 4278 | TAG argument of the index macro is optional, the TAG argument will be |
| 3978 | omitted. | 4279 | omitted.@refill |
| 3979 | |||
| 3980 | @var{repeat-word}, when non-@code{nil} means, the index macro does not | ||
| 3981 | typeset the entry in the text, so that the text has to be repeated | ||
| 3982 | outside the index macro. | ||
| 3983 | @end defopt | 4280 | @end defopt |
| 3984 | 4281 | ||
| 3985 | @defopt reftex-index-default-tag | 4282 | @defopt reftex-index-default-tag |
| @@ -4004,14 +4301,90 @@ math delimiters (e.g. @samp{$}) to the string. Requires the | |||
| 4004 | @file{texmathp.el} library which is part of AUCTeX.@refill | 4301 | @file{texmathp.el} library which is part of AUCTeX.@refill |
| 4005 | @end defopt | 4302 | @end defopt |
| 4006 | 4303 | ||
| 4304 | @defopt reftex-index-phrases-logical-and-regexp | ||
| 4305 | Regexp matching the @samp{and} operator for index arguments in phrases | ||
| 4306 | file. When several index arguments in a phrase line are separated by | ||
| 4307 | this operator, each part will generate an index macro. So each match of | ||
| 4308 | the search phrase will produce @emph{several} different index entries. | ||
| 4309 | Make sure this does no match things which are not separators. This | ||
| 4310 | logical @samp{and} has higher priority than the logical @samp{or} | ||
| 4311 | specified in @code{reftex-index-phrases-logical-or-regexp}.@refill | ||
| 4312 | @end defopt | ||
| 4313 | |||
| 4314 | @defopt reftex-index-phrases-logical-or-regexp | ||
| 4315 | Regexp matching the @samp{or} operator for index arguments in phrases | ||
| 4316 | file. When several index arguments in a phrase line are separated by | ||
| 4317 | this operator, the user will be asked to select one of them at each | ||
| 4318 | match of the search phrase. The first index arg will be the default. A | ||
| 4319 | number key @kbd{1}--@kbd{9} must be pressed to switch to another. Make | ||
| 4320 | sure this does no match things which are not separators. The logical | ||
| 4321 | @samp{and} specified in @code{reftex-index-phrases-logical-or-regexp} | ||
| 4322 | has higher priority than this logical @samp{or}.@refill | ||
| 4323 | @end defopt | ||
| 4324 | |||
| 4325 | @defopt reftex-index-phrases-search-whole-words | ||
| 4326 | Non-@code{nil} means phrases search will look for whole words, not subwords. | ||
| 4327 | This works by requiring word boundaries at the beginning and end of | ||
| 4328 | the search string. When the search phrase already has a non-word-char | ||
| 4329 | at one of these points, no word boundary is required there. | ||
| 4330 | @end defopt | ||
| 4331 | |||
| 4332 | @defopt reftex-index-phrases-case-fold-search | ||
| 4333 | Non-@code{nil} means, searching for index phrases will ignore | ||
| 4334 | case.@refill | ||
| 4335 | @end defopt | ||
| 4336 | |||
| 4337 | @defopt reftex-index-phrases-skip-indexed-matches | ||
| 4338 | Non-@code{nil} means, skip matches which appear to be indexed already. | ||
| 4339 | When doing global indexing from the phrases buffer, searches for some | ||
| 4340 | phrases may match at places where that phrase was already indexed. In | ||
| 4341 | particular when indexing an already processed document again, this | ||
| 4342 | will even be the norm. When this variable is non-@code{nil}, | ||
| 4343 | @b{Ref@TeX{}} checks if the match is an index macro argument, or if an | ||
| 4344 | index macro is directly before or after the phrase. If that is the | ||
| 4345 | case, that match will be ignored.@refill | ||
| 4346 | @end defopt | ||
| 4347 | |||
| 4348 | @defopt reftex-index-phrases-wrap-long-lines | ||
| 4349 | Non-@code{nil} means, when indexing from the phrases buffer, wrap lines. | ||
| 4350 | Inserting indexing commands in a line makes the line longer - often | ||
| 4351 | so long that it does not fit onto the screen. When this variable is | ||
| 4352 | non-@code{nil}, newlines will be added as necessary before and/or after the | ||
| 4353 | indexing command to keep lines short. However, the matched text | ||
| 4354 | phrase and its index command will always end up on a single line.@refill | ||
| 4355 | @end defopt | ||
| 4356 | |||
| 4357 | @defopt reftex-index-phrases-sort-prefers-entry | ||
| 4358 | Non-@code{nil} means when sorting phrase lines, the explicit index entry | ||
| 4359 | is used. Phrase lines in the phrases buffer contain a search phrase, and | ||
| 4360 | sorting is normally based on these. Some phrase lines also have | ||
| 4361 | an explicit index argument specified. When this variable is | ||
| 4362 | non-@code{nil}, the index argument will be used for sorting.@refill | ||
| 4363 | @end defopt | ||
| 4364 | |||
| 4365 | @defopt reftex-index-phrases-sort-in-blocks | ||
| 4366 | Non-@code{nil} means, empty and comment lines separate phrase buffer | ||
| 4367 | into blocks. Sorting will then preserve blocks, so that lines are | ||
| 4368 | re-arranged only within blocks. | ||
| 4369 | @end defopt | ||
| 4370 | |||
| 4371 | @defopt reftex-index-phrases-map | ||
| 4372 | Keymap for the Index Phrases buffer. | ||
| 4373 | @end defopt | ||
| 4374 | |||
| 4375 | @defopt reftex-index-phrases-mode-hook | ||
| 4376 | Normal hook which is run when a buffer is put into | ||
| 4377 | @code{reftex-index-phrases-mode}.@refill | ||
| 4378 | @end defopt | ||
| 4379 | |||
| 4007 | @defopt reftex-index-section-letters | 4380 | @defopt reftex-index-section-letters |
| 4008 | The letters which denote sections in the index. Usually these are all | 4381 | The letters which denote sections in the index. Usually these are all |
| 4009 | capital letters. Don't use any downcase letters. Order is not | 4382 | capital letters. Don't use any downcase letters. Order is not |
| 4010 | significant, the index will be sorted by whatever the sort function | 4383 | significant, the index will be sorted by whatever the sort function |
| 4011 | thinks is correct. In addition to these letters, RefTeX will create a | 4384 | thinks is correct. In addition to these letters, @b{Ref@TeX{}} will |
| 4012 | group @samp{!} which contains all entries sorted below the lowest | 4385 | create a group @samp{!} which contains all entries sorted below the |
| 4013 | specified letter. In the @file{*Index*} buffer, pressing any of these | 4386 | lowest specified letter. In the @file{*Index*} buffer, pressing any of |
| 4014 | capital letters or @kbd{!} will jump to that section.@refill | 4387 | these capital letters or @kbd{!} will jump to that section.@refill |
| 4015 | @end defopt | 4388 | @end defopt |
| 4016 | 4389 | ||
| 4017 | @defopt reftex-index-include-context | 4390 | @defopt reftex-index-include-context |
| @@ -4445,11 +4818,11 @@ Normal hook which is being run when loading @file{reftex.el}. | |||
| 4445 | Normal hook which is being run when turning on @b{Ref@TeX{}} mode.@refill | 4818 | Normal hook which is being run when turning on @b{Ref@TeX{}} mode.@refill |
| 4446 | @end deffn | 4819 | @end deffn |
| 4447 | 4820 | ||
| 4448 | Furthermore, the 3 modes used for referencing labels, creating citations | 4821 | Furthermore, the 4 modes used for referencing labels, creating |
| 4449 | and for the table of contents buffer have their own keymaps and mode | 4822 | citations, the table of contents buffer and the phrases buffer have |
| 4450 | hooks. See the respective sections. There are many more hooks which | 4823 | their own keymaps and mode hooks. See the respective sections. There |
| 4451 | are described in the relevant sections about options for a specific part | 4824 | are many more hooks which are described in the relevant sections about |
| 4452 | of @b{Ref@TeX{}}.@refill | 4825 | options for a specific part of @b{Ref@TeX{}}.@refill |
| 4453 | 4826 | ||
| 4454 | @node Changes, , Keymaps and Hooks, Top | 4827 | @node Changes, , Keymaps and Hooks, Top |
| 4455 | @chapter Changes | 4828 | @chapter Changes |
| @@ -4903,7 +5276,6 @@ New options @code{reftex-texpath-environment-variables}, | |||
| 4903 | @emph{kpathsearch} support. See new options and | 5276 | @emph{kpathsearch} support. See new options and |
| 4904 | @code{reftex-bibpath-environment-variables}. | 5277 | @code{reftex-bibpath-environment-variables}. |
| 4905 | @end itemize | 5278 | @end itemize |
| 4906 | @end ignore | ||
| 4907 | @noindent @b{Version 3.42} | 5279 | @noindent @b{Version 3.42} |
| 4908 | @itemize @bullet | 5280 | @itemize @bullet |
| 4909 | @item | 5281 | @item |
| @@ -4932,6 +5304,7 @@ Files in @code{reftex-default-bibliography} will be searched along | |||
| 4932 | @item | 5304 | @item |
| 4933 | Reading a parse file now checks consistency. | 5305 | Reading a parse file now checks consistency. |
| 4934 | @end itemize | 5306 | @end itemize |
| 5307 | @end ignore | ||
| 4935 | @noindent @b{Version 4.00} | 5308 | @noindent @b{Version 4.00} |
| 4936 | @itemize @bullet | 5309 | @itemize @bullet |
| 4937 | @item | 5310 | @item |
| @@ -4980,7 +5353,30 @@ of a sectioning command. | |||
| 4980 | @item | 5353 | @item |
| 4981 | Multiple @code{thebibliography} environments recognized. | 5354 | Multiple @code{thebibliography} environments recognized. |
| 4982 | @end itemize | 5355 | @end itemize |
| 4983 | 5356 | @noindent @b{Version 4.09} | |
| 5357 | @itemize @bullet | ||
| 5358 | @item | ||
| 5359 | New option @code{reftex-toc-max-level} to limit the depth of the toc. | ||
| 5360 | New keybinding @kbd{t} in the @file{*toc*} buffer to change this | ||
| 5361 | setting.@refill | ||
| 5362 | @item | ||
| 5363 | RefTeX maintaines an @file{Index Phrases} file in which phrases can be | ||
| 5364 | collected. When the document is ready, RefTeX can search all | ||
| 5365 | these phrases and assist indexing all matches.@refill | ||
| 5366 | @item | ||
| 5367 | The variables @code{reftex-index-macros} and | ||
| 5368 | @code{reftex-index-default-macro} have changed their syntax slightly. | ||
| 5369 | The @var{repeat} parameter has move from the latter to the former. | ||
| 5370 | Also calls to @code{reftex-add-index-macros} from AUCTeX style files | ||
| 5371 | need to be adapted.@refill | ||
| 5372 | @item | ||
| 5373 | The variable @code{reftex-section-levels} no longer contains the | ||
| 5374 | default stuff which has been moved to a constant.@refill | ||
| 5375 | @item | ||
| 5376 | Environments like theorems can be placed into the TOC by putting | ||
| 5377 | entries for @samp{"begin@{theorem@}"} in | ||
| 5378 | @code{reftex-setion-levels}.@refill | ||
| 5379 | @end itemize | ||
| 4984 | 5380 | ||
| 4985 | @node Index, , , Top | 5381 | @node Index, , , Top |
| 4986 | @unnumbered Index | 5382 | @unnumbered Index |