[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

11. Automatic Customization

Since AUCTeX is so highly customizable, it makes sense that it is able to customize itself. The automatic customization consists of scanning TeX files and extracting symbols, environments, and things like that.

The automatic customization is done on three different levels. The global level is the level shared by all users at your site, and consists of scanning the standard TeX style files, and any extra styles added locally for all users on the site. The private level deals with those style files you have written for your own use, and use in different documents. You may have a `~/lib/TeX/' directory where you store useful style files for your own use. The local level is for a specific directory, and deals with writing customization for the files for your normal TeX documents.

If compared with the environment variable TEXINPUTS, the global level corresponds to the directories built into TeX. The private level corresponds to the directories you add yourself, except for `.', which is the local level.

11.1 Automatic Customization for the Site  
11.2 Automatic Customization for a User  
11.3 Automatic Customization for a Directory  

By default AUCTeX will search for customization files in all the global, private, and local style directories, but you can also set the path directly. This is useful if you for example want to add another person's style hooks to your path. Please note that all matching files found in TeX-style-path are loaded, and all hooks defined in the files will be executed.

User Option: TeX-style-path
List of directories to search for AUCTeX style files. Each must end with a slash.

By default, when AUCTeX searches a directory for files, it will recursively search through subdirectories.

User Option: TeX-file-recurse
Whether to search TeX directories recursively: nil means do not recurse, a positive integer means go that far deep in the directory hierarchy, t means recurse indefinitely.

By default, AUCTeX will ignore files name `.', `..', `SCCS', `RCS', and `CVS'.

User Option: TeX-ignore-file
Regular expression matching file names to ignore.

These files or directories will not be considered when searching for TeX files in a directory.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

11.1 Automatic Customization for the Site

Assuming that the automatic customization at the global level was done when AUCTeX was installed, your choice is now: will you use it? If you use it, you will benefit by having access to all the symbols and environments available for completion purposes. The drawback is slower load time when you edit a new file and perhaps too many confusing symbols when you try to do a completion.

You can disable the automatic generated global style hooks by setting the variable TeX-auto-global to nil.

User Option: TeX-macro-global
Directories containing the site's TeX style files.

User Option: TeX-style-global
Directory containing hand generated TeX information. Must end with a slash.

These correspond to TeX macros shared by all users of a site.

User Option: TeX-auto-global
Directory containing automatically generated information.

For storing automatic extracted information about the TeX macros shared by all users of a site.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

11.2 Automatic Customization for a User

You should specify where you store your private TeX macros, so AUCTeX can extract their information. The extracted information will go to the directories listed in TeX-auto-private

Use M-x TeX-auto-generate to extract the information.

User Option: TeX-macro-private
Directories where you store your personal TeX macros. Each must end with a slash.

This defaults to the directories listed in the `TEXINPUTS' and `BIBINPUTS' environment variables.

User Option: TeX-auto-private
List of directories containing automatically generated information. Must end with a slash.

These correspond to the personal TeX macros.

Command: TeX-auto-generate TEX AUTO
(M-x TeX-auto-generate) Generate style hook for TEX and store it in AUTO. If TEX is a directory, generate style hooks for all files in the directory.

User Option: TeX-style-private
List of directories containing hand generated information. Must end with a slash.

These correspond to the personal TeX macros.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

11.3 Automatic Customization for a Directory

AUCTeX can update the style information about a file each time you save it, and it will do this if the directory TeX-auto-local exist. TeX-auto-local is by default set to `"auto/"', so simply creating an `auto' directory will enable automatic saving of style information.

The advantage of doing this is that macros, labels, etc. defined in any file in a multifile document will be known in all the files in the document. The disadvantage is that saving will be slower. To disable, set TeX-auto-local to nil.

User Option: TeX-style-local
Directory containing hand generated TeX information. Must end with a slash.

These correspond to TeX macros found in the current directory.

User Option: TeX-auto-local
Directory containing automatically generated TeX information. Must end with a slash.

These correspond to TeX macros found in the current directory.


[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

This document was generated by XEmacs shared group account on December, 19 2009 using texi2html 1.65.