" mail FTplugin " " Requires vim 6.x. " To install place in ~/.vim/after/ftplugin/mail.vim " " Author: Brian Medley " Email: freesoftware@4321.tv " " This file was modified from Cedric Duval's version. " http://cedricduval.free.fr/download/vimrc/mail " Only do this when not done yet for this buffer if exists("b:did_mail_after_ftplugin") finish endif let b:did_mail_after_ftplugin = 1 if !exists ("mail_alias_program") let mail_alias_program="Abook" endif " ==================================================================== " Globals " ==================================================================== if !exists ("mail_quote_chars") let s:quote_chars = ':!|>' else let s:quote_chars = mail_quote_chars endif " This re defines a 'quote' let s:quote_re = '\(\s\?\w*[' . s:quote_chars . ']\)' " \s\? => 0 or one whitespace char " (b/c some ppl put " spaces in the quote, " and others don't) " " \w* => maybe word chars (b/c " some ppl put initals in " the quotes) " the rest => actual quote chars " \( \) => this is a quote "level" " This re defines the quoting level at the *beginning* of a line let s:quote_start = '^' . s:quote_re . s:quote_re . '*' " ^s:quote_re => quote at beginning of " line " s:quote_re* => perhaps followed by " more quotes " For debugging: " let b:quote_chars = s:quote_chars " let b:quote_re = s:quote_re " let b:quote_start = s:quote_start " ==================================================================== " Mappings " ==================================================================== if !exists("no_plugin_maps") && !exists("no_mail_maps") " " get alias list mappings " if !hasmapto('MailAliasList', 'n') nmap al MailAliasList endif if !hasmapto('MailAliasList', 'i') imap al MailAliasList endif nnoremap