A set of macros to improve usage of Vim + Cream as a LaTeX editor.
*
The features of Vim: syntax highlighting, spellchecking, high level of configurability, and many many interesting things.
The features of Cream: simple interface, easy entrance to Vim for newcomers.
+ some more things for easy work with LaTeX files (toolbar, menu, popup menu, error windows, keybindings, autoformatting paragraphs...)
Tested with Vim 7.1, Cream 0.41
Other programs:
Toolbar can be customized through Settings: groups of icons can be
switched off or on
JumpTo:
LaTeX:
`Insert environment' can be done by pressing Tab when writing \begin
In the example the context menu over \eqref{*} also gives list of labels. It works in a similar way over \cite{*}.
This functionality is also provided for Tab key.
It is assumed that Vim and Cream have been installed (usually one also needs to add spelling files to $VIMRUNTIME/spell), along with the software mentioned above in `Software needed'
Put files tex4cream.vim, tune_cream.vim, latex_environments.vim, cream-spell-mod.vim from addons.zip to ~/.cream/addons
Put icons for toolbar (bitmaps.zip) to $VIMRUNTIME/cream/bitmaps
Put .ctags from conf.zip to your home directory
Sample files cream-conf.vim, cream-user.vim from conf.zip are to be put to ~/.cream (there one can also change settings, such as encodings that vim will recognize, languages for spellchecking)
Cream contains an outdated version of taglist. Besides, when working with non-latin text it can be useful to patch taglist.vim to allow postprocessing of its output with iconv to convert tags to correct encoding.
A patched version of taglist.vim can be done by the command "patch -p0 < taglist.patch" with taglist.patch and put to $VIMRUNTIME/cream
A collection of gVim color schemes colors.zip can be put to $VIMRUNTIME/colors or replace $VIMRUNTIME/colors
An example of settings for Cream (of importance are Auto Wrap, Toolbar, Tabbed Documents,...)
Settings for LaTeX Symbol selector
Spellchecking
DVI previewer should be set for inverse search. E.g. in KDVI:
tex4cream.vim
main source of additional functionality:
defining system dependent tex tools for compilation, viewing of dvi (to note is that a dcop trick is applied to autoraise kdvi window), pdf, ps, conversion of dvi to pdf and ps;
some keybindings and context menu addons;
LaTeX and JumpTo menus, and toolbar definition;
TeX paragraph autoformat;
LaTeX error window.
latex_environments.vim
definition of LaTeX environments for `Insert Environment' and `Replace Environment' in LaTeX and popup menu. (One can easily edit this file to make it more suitable for individual style of work and packages in use.)
latex_tools.vim
system dependent definitions of tools for inserting LaTeX commands, viewing dvi, ps, pdf files, conversion of dvi to ps and pdf. (One can easily edit this file to tune for the current program environment.)
tune_cream.vim
tuning Cream:
windows-like behaviour of arrows and mouse motion over selection;
adding baloons to show contents of folding when cursor is over;
returning to native gVim color schemes;
repairing cream's bugs: C-A and forgetting window height.
For users who use Russian language (indeed, it can be redone for other non-latin languages) two more addons can be useful:
tune_rus.vim
introduces langmaps, which allow us to use keybindins (Ctrl-C, Ctrl-A and so on) when Russian keyboard is switched on (at the moment it needs 2 patches of vim: 1 and 2).
xrus_tex4cream.vim
some mappings to run autoformat of TeX paragraph at pressing Russian vowels.
cream-spell-mod.vim
It is cream-spell.vim file patched to replace `b:cream_spell' with `g:CREAM_SPELL' (In my opinion it is better when status of spellchecker on or off is global, for all open files, and is remembered between editor's launches).
TeX4Cream is distributed under the GPL License. TeX4Cream is Copyright © 2008 Oleg V. Motygin