[Vim-latex-cvs] vimfiles/ftplugin/latex-suite main.vim,1.34,1.35
Brought to you by:
srinathava,
tmaas
From: <sri...@us...> - 2003-01-17 09:13:34
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv12052 Modified Files: main.vim Log Message: - main.vim used to help various other components set up mappings etc. This was becoming ugly because it caused some unecessary dependencies... The new tex_latexSuite.vim file enables us to remove these dependencies. SetTeXOptions() now just sets options local to main.vim. Each of the other components do their own stuff. SetTeXOptions() is called by catching the LatexSuiteFileType event thrown by tex_latexSuite.vim. Index: main.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** main.vim 16 Jan 2003 17:42:09 -0000 1.34 --- main.vim 17 Jan 2003 09:13:31 -0000 1.35 *************** *** 35,42 **** exe "so ".s:path.'/texrc' - augroup LatexSuite User LatexSuiteInit - au! - augroup END - " }}} --- 35,38 ---- *************** *** 536,553 **** " SetTeXOptions: sets options/mappings for this file. {{{ function! <SID>SetTeXOptions() ! exe 'setlocal dict+='.s:path.'/dictionaries/dictionary' ! setlocal foldtext=TexFoldTextFunction() ! ! " fold up things. and mappings for refreshing folds. ! if g:Tex_Folding && g:Tex_AutoFolding ! call MakeTexFolds(0) ! endif ! if g:Tex_Folding ! if mapcheck('<F6>') == "" ! nnoremap <buffer> <F6> :call MakeTexFolds(1)<cr> ! endif ! nnoremap <buffer> <leader>rf :call MakeTexFolds(1)<cr> endif " smart functions if g:Tex_SmartKeyQuote --- 532,544 ---- " SetTeXOptions: sets options/mappings for this file. {{{ function! <SID>SetTeXOptions() ! " Avoid reinclusion. ! if exists('b:doneSetTeXOptions') ! return endif + let b:doneSetTeXOptions = 1 + exe 'setlocal dict+='.s:path.'/dictionaries/dictionary' + + call Tex_Debug('SetTeXOptions: sourcing maps') " smart functions if g:Tex_SmartKeyQuote *************** *** 560,582 **** inoremap <buffer> <silent> . <C-R>=<SID>SmartDots()<CR> endif - if g:Tex_PromptedEnvironments != '' || g:Tex_HotKeyMappings != '' - call Tex_SetFastEnvironmentMaps() - endif - if g:Tex_PromptedCommands != '' - call Tex_SetFastCommandMaps() - endif - " viewing/searching - if !hasmapto('RunLaTeX') - if has("gui") - nnoremap <buffer> <Leader>ll :silent! call RunLaTeX()<cr> - nnoremap <buffer> <Leader>lv :silent! call ViewLaTeX()<cr> - nnoremap <buffer> <Leader>ls :silent! call ForwardSearchLaTeX()<cr> - else - nnoremap <buffer> <Leader>ll :call RunLaTeX()<cr> - nnoremap <buffer> <Leader>lv :call ViewLaTeX()<cr> - nnoremap <buffer> <Leader>ls :call ForwardSearchLaTeX()<cr> - end - end " This line seems to be necessary to source our compiler/tex.vim file. " The docs are unclear why this needs to be done even though this file is --- 551,555 ---- *************** *** 584,591 **** runtime compiler/tex.vim - silent! do LatexSuite User LatexSuiteInit endfunction ! call <SID>SetTeXOptions() " }}} --- 557,565 ---- runtime compiler/tex.vim endfunction ! augroup LatexSuite ! au LatexSuite User LatexSuiteFileType call <SID>SetTeXOptions() ! augroup END " }}} |