1 Future Development of AUCTeX
2 ****************************
4 The following sections describe future development of AUCTeX.
5 Besides mid-term goals, bug reports and requests we cannot fix or honor
6 right away are being gathered here. If you have some time for Emacs
7 Lisp hacking, you are encouraged to try to provide a solution to one of
8 the following problems. If you don't know Lisp, you may help us to
9 improve the documentation. It might be a good idea to discuss proposed
10 changes on the mailing list of AUCTeX first.
15 * Integration of preview-latex into AUCTeX
17 As of AUCTeX 11.81 preview-latex is a part of AUCTeX in the sense
18 that the installation routines were merged and preview-latex is
19 being packaged with AUCTeX.
21 Further integration will happen at the backend. This involves
22 folding of error parsing and task management of both packages
23 which will ease development efforts and avoid redundant work.
25 * More flexible option and command handling
27 The current state of command handling with `TeX-command-list' is
28 not very flexible because there is no distinction between
29 executables and command line options to be passed to them.
31 Customization of `TeX-command-list' by the user will interfere with
36 Currently, the help for errors is more or less hardwired into
37 `tex.el'. For supporting error help in other languages, it would
38 be sensible to instead arrange error messages in language-specific
39 files, make a common info file from all such catalogs in a given
40 language and look the error texts up in an appropriate index. The
41 user would then specify a preference list of languages, and the
42 errors would be looked up in the catalogs in sequence until they
45 * Combining `docTeX' with RefTeX
47 Macro cross references should also be usable for document
48 navigation using RefTeX.
54 * Documentation lookup for macros
56 A parser could gather information about which macros are defined in
57 which LaTeX packages and store the information in a hashtable which
58 can be used in a backend for `TeX-doc' in order to open the
59 matching documentation for a given macro. The information could
60 also be used to insert an appropriate `\usepackage' statement if
61 the user tries to insert a macro for which the respective package
62 has not been requested yet.
64 * Spell checking of macros
66 A special ispell dictionary for macros could be nice to have.
68 * Quick error overviews
70 An error overview window (extract from the log file with just the
71 error lines, clickable like a "grep" buffer) and/or fringe
72 indicators for errors in the main text would be nice.
76 A separate frame with a table of math character graphics to click
77 on in order to insert the respective sequence into the buffer (cf.
78 the "grid" of x-symbol).
80 * Crossreferencing support
82 It would be nice if you could index process your favorite
83 collection of `.dtx' files (such as the LaTeX source), just call a
84 command on arbitrary control sequence, and get either the DVI
85 viewer opened right at the definition of that macro (using Source
86 Specials), or the source code of the `.dtx' file.
88 * Better plain TeX support
90 For starters, `LaTeX-math-mode' is not very LaTeX-specific in the
91 first place, and similar holds for indentation and formatting.
93 * Poor man's Source Specials In particular in PDF mode (and where
94 Source Specials cause problems), alternatives would be desirable.
95 One could implement inverse search by something like Heiko
96 Oberdiek's `vpe.sty', and forward search by using the `.aux' file
97 info to correlate labels in the text (possibly in cooperation with
98 RefTeX) with previewer pages.
100 In AUCTeX 11.83, support for forward search with PDF files was
101 added. Currently this only works if you use the pdfsync LaTeX
102 package and xpdf as your PDF viewer.
104 * Page count when compiling should (optionally) go to modeline of the
105 window where the compilation command was invoked, instead of the
106 output window. Suggested by Karsten Tinnefeld
107 <tinnefeld@irb.informatik.uni-dortmund.de>.
109 * Command to insert a macrodefinition in the preamble, without moving
110 point from the current location. Suggested by "Jeffrey C. Ely"
113 * A database of all commands defined in all stylefiles. When a
114 command or environment gets entered that is provided in one of the
115 styles, insert the appropriate `\usepackage' in the preamble.
117 * A way to add and overwrite math mode entries in style files, and to
118 decide where they should be. Suggested by Remo Badii
121 * Create template for (first) line of tabular environment.
123 * I think prompting for the master is the intended behaviour. It
124 corresponds to a `shared' value for TeX-master.
126 There should probably be a `none' value which wouldn't query for
127 the master, but instead disable all features that relies on
130 This default value for TeX-master could then be controled with
131 mapping based on the extension.
133 * Multiple argument completion for `\bibliography'. In general, I
134 ought to make `,' special for these kind of completions.
136 * Suggest `makindex' when appropriate.
138 * Use index files (when available) to speed up `C-c C-m include
141 * Option not to calculate very slow completions like for `C-c C-m
144 * Font menu should be created from `TeX-font-list'.
146 * Installation procedure written purely in emacs lisp.
148 * Included PostScript files should also be counted as part of the
151 * The parser should catch warnings about undefined crossreferences.
152 Suggested by Richard Hirsch `i3080501@ws.rz.tu-bs.de'.
154 * A nice hierarchical by-topic organization of all officially
155 documented LaTeX macros, available from the menu bar.
157 * `TeX-command-default' should be set from the master file, if not
158 set locally. Suggested by Peter Whaite `<peta@cim.mcgill.ca>'.
160 * Make AUCTeX work with `crypt++'. Suggested by Chris Moore
161 `<Chris.Moore@src.bae.co.uk>'.
163 * Make AUCTeX work with `longlines'. This would also apply to
164 preview-latex, though it might make sense to unify error processing
165 before attempting this.
167 * The `Spell' command should apply to all files in a document. Maybe
168 it could try to restrict to files that have been modified since
169 last spell check? Suggested by Ravinder Bhumbla
170 `<rbhumbla@ucsd.edu>'.
172 * Make <.> check for abbreviations and sentences ending with capital
175 * Use Emacs 19 minibuffer history to choose between previewers, and
176 other stuff. Suggested by John Interrante
177 `<interran@uluru.Stanford.EDU>'.
181 A new command `TeX-update' (`C-c C-u') could be used to create an
182 up-to-date dvi file by repeatedly running BibTeX, MakeIndex and
183 (La)TeX, until an error occurs or we are done.
185 An alternative is to have an `Update' command that ensures the
186 `dvi' file is up to date. This could be called before printing and
189 * Documentation of variables that can be set in a style hook.
191 We need a list of what can safely be done in an ordinary style
192 hook. You can not set a variable that AUCTeX depends on, unless
193 AUCTeX knows that it has to run the style hooks first.
195 Here is the start of such a list.
196 `LaTeX-add-environments'
202 `LaTeX-add-bibliographies'
204 `LaTeX-largest-level'
206 * Completion for counters and sboxes.
208 * Outline should be (better) supported in TeX mode.
210 At least, support headers, trailers, as well as TeX-outline-extra.
212 * `TeX-header-start' and `TeX-trailer-end'.
214 We might want these, just for fun (and outlines)
216 * Plain TeX and LaTeX specific header and trailer expressions.
218 We should have a way to globally specify the default value of the
219 header and trailer regexps.
221 * Get closer to original `TeX-mode' keybindings.
223 A third initialization file (`tex-mode.el') containing an emulator
224 of the standard `TeX-mode' would help convince some people to
227 * Make `TeX-next-error' parse ahead and store the results in a list,
228 using markers to remember buffer positions in order to be more
229 robust with regard to line numbers and changed files. This is what
230 `next-error' does. (Or did, until Emacs 19).
232 * Finish the Texinfo mode. For one thing, many Texinfo mode
233 commands do not accept braces around their arguments.
235 * Hook up the letter environment with `bbdb.el'.
241 * The parsed files and style hooks for `example.dtx', `example.sty',
242 `example.drv' and `example.bib' all clash. Bad.
244 * `C-c `' should always stay in the current window, also when it
247 * Do not overwrite emacs warnings about existing auto-save files when
250 * Maybe the regexp for matching a TeX symbol during parsing should be
251 `"\\\\\\([a-zA-Z]+\\|.\\)"' --
252 `<thiemann@informatik.uni-tuebingen.de>' Peter Thiemann.
254 * AUCTeX should not parse verbatim environments.
256 * Make ``' check for math context in `LaTeX-math-mode'. and simply
257 self insert if not in a math context.
259 * Make `TeX-insert-dollar' more robust. Currently it can be fooled
260 by `\mbox''es and escaped double dollar for example.
262 * Correct indentation for tabular, tabbing, table, math, and array
265 * Syntax highlighting of LaTeX constructs spanning more than one line
266 sometimes stops in the middle of the construct. Highlighting can
267 get lost during typing. (XEmacs only)
269 * No syntactic font locking of verbatim macros and environments.
272 * Font locking inside of verbatim macros and environments is not
273 inhibited. This may result in syntax highlighting of unbalanced
274 dollar signs and the like spilling out of the verbatim content.
277 * Folding of LaTeX constructs spanning more than one line may result
278 in overfull lines. (XEmacs only)
280 Future Development of preview-latex
281 ***********************************
283 * Support other formats than just LaTeX
285 plain TeX users and ConTeXt users should not have to feel left
286 out. While ConTeXt is not supported yet by released versions of
287 AUCTeX, at least supporting plain would help people, and be a start
288 for ConTeXt as well. There are plain-based formats like MusiXTeX
289 that could benefit a lot from preview-latex. The main part of the
290 difficulties here is to adapt `preview.dtx' to produce stuff not
293 * Support nested snippets
295 Currently you can't have both a footnote (which gets displayed as
296 just its footnote number) and math inside of a footnote rendered
297 as an image: such nesting might be achieved by rerunning
298 preview-latex on the footnote contents when one opens the footnote
301 * Support other text properties than just images
303 Macros like `\textit' can be rendered as images, but the resulting
304 humungous blob is not suitable for editing, in particular since the
305 line filling from LaTeX does not coincide with that of Emacs. It
306 would be much more useful if text properties just switched the
307 relevant font to italics rather than replacing the whole text with
308 an image. It would also make editing quite easier. Then there
309 are things like footnotes that are currently just replaced by
310 their footnote number. While editing is not a concern here (the
311 number is not in the original text, anyway), it would save a lot
312 of conversion time if no images were generated, but Emacs just
313 displayed a properly fontified version of the footnote number.
314 Also, this might make preview-latex useful even on text terminals.
316 * Find a way to facilitate Source Specials
318 Probably in connection with adding appropriate support to
319 `dvipng', it would be nice if clicking on an image from a larger
320 piece of source code would place the cursor at the respective
321 source code location.
323 * Make `preview.dtx' look reasonable in AUCTeX
325 It is a bit embarrassing that `preview.dtx' is written in a manner
326 that will not give either good syntax highlighting or good
327 indentation when employing AUCTeX.
331 Currently, preview-latex's web page is not structured at all.
332 Better navigation would be desirable, as well as separate News and
335 * Manual improvements
337 - Pepper the manual with screen shots and graphics
339 This will be of interest for the HTML and TeX renditions of
340 the texinfo manual. Since Texinfo now supports images as
341 well, this could well be nice to have.
345 Various stuff appears several times.
348 * Implement rendering pipelines for Emacs
350 The current `gs.el' interface is fundamentally flawed, not only
351 because of a broken implementation. A general batchable and
352 daemonizable rendering infrastructure that can work on all kinds of
353 preview images for embedding into buffers is warranted. The
354 current implementation has a rather adhoc flavor and is not easily
355 extended. It will not work outside of AUCTeX, either.
357 * Integrate into RefTeX
359 When referencing to equations and the like, the preview-images of
360 the source rather than plain text should be displayed. If the
361 preview in question covers labels, those should appear in the
362 bubble help and/or a context menu. Apropos:
364 * Implement LaTeX error indicators
366 Previews on erroneous LaTeX passages might gain a red border or
369 * Pop up relevant online documentation for frequent errors
371 A lot of errors are of the "badly configured" variety. Perhaps the
372 relevant info pages should be delivered in addition to the error
375 * Implement a table editing mode where every table cell gets output
376 as a separate preview. Alternatively, output the complete table
377 metrics in a way that lets people click on individual cells for
380 * Benchmark and kill Emacs inefficiencies
382 Both the LaTeX run under Emacs control as well as actual image
383 insertion in Emacs could be faster. CVS Emacs has improved in that
384 respect, but it still is slower than desirable.
386 * Improve image support under Emacs
388 The general image and color handling in Emacs is inefficient and
389 partly defective. This is still the case in CVS. One option
390 would be to replace the whole color and image handling with GDK
391 routines when this library is available, since it has been