vim-latex-cvs Mailing List for Vim-Latex (Page 24)
Brought to you by:
srinathava,
tmaas
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(82) |
Dec
(124) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(104) |
Feb
(3) |
Mar
(6) |
Apr
(48) |
May
(34) |
Jun
(62) |
Jul
(33) |
Aug
(24) |
Sep
(32) |
Oct
(16) |
Nov
(36) |
Dec
(39) |
2004 |
Jan
|
Feb
(3) |
Mar
(8) |
Apr
|
May
(29) |
Jun
(13) |
Jul
(4) |
Aug
(6) |
Sep
|
Oct
|
Nov
|
Dec
(2) |
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(3) |
Oct
|
Nov
(6) |
Dec
(9) |
2006 |
Jan
(9) |
Feb
(2) |
Mar
(16) |
Apr
(5) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2008 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(22) |
Jun
(1) |
Jul
|
Aug
(6) |
Sep
|
Oct
|
Nov
|
Dec
|
2009 |
Jan
(1) |
Feb
|
Mar
(2) |
Apr
(2) |
May
|
Jun
(1) |
Jul
|
Aug
(17) |
Sep
(3) |
Oct
(4) |
Nov
(1) |
Dec
(3) |
2010 |
Jan
(25) |
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(8) |
Nov
|
Dec
|
2011 |
Jan
|
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(2) |
Sep
(10) |
Oct
(1) |
Nov
|
Dec
(1) |
2012 |
Jan
(5) |
Feb
(1) |
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
(4) |
Nov
(1) |
Dec
|
2013 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(15) |
Dec
|
2015 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
(2) |
Dec
|
From: <mi...@us...> - 2003-04-07 10:52:20
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv3014 Modified Files: compiler.vim Log Message: include fix by Soren Debois and make possible inverse searching with xdvi instation from forward searching Index: compiler.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/compiler.vim,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** compiler.vim 4 Apr 2003 00:55:57 -0000 1.23 --- compiler.vim 7 Apr 2003 10:52:11 -0000 1.24 *************** *** 111,114 **** --- 111,117 ---- let &l:makeprg = _makeprg elseif exists("g:partcomp") + " Change directory to location of temporary file. In this way output + " files will be in temporary directory (no garbage in real current + " directory). System will take care about space. let curdir = getcwd() let pcomdir = fnamemodify(g:tfile, ":p:h") *************** *** 151,154 **** --- 154,160 ---- " Again, if the current file is a \input in a master file, see text above " RunLaTeX() to see how to set this information. + " If ViewLaTeX was called with argument "part" show file which name is stored + " in g:tfile variable. If g:tfile doesnt exist, no problem. Function is called + " as silent. function! ViewLaTeX(size) if &ft != 'tex' *************** *** 193,198 **** if s:target == 'dvi' if exists('g:Tex_UseEditorSettingInDVIViewer') && ! \ g:Tex_UseEditorSettingInDVIViewer == 1 && a:size == "all" ! exec '!'.s:viewer.' -editor "gvim --servername '.v:servername.' --remote-silent +%l %f" '.mainfname.'.dvi &' else if a:size == "all" --- 199,206 ---- if s:target == 'dvi' if exists('g:Tex_UseEditorSettingInDVIViewer') && ! \ g:Tex_UseEditorSettingInDVIViewer == 1 && a:size == "all" && ! \ exists('v:servername') && ! \ (s:viewer == "xdvi" || s:viewer == "xdvik") ! exec '!'.s:viewer.' -editor "gvim --servername '.v:servername.' --remote-silent +\%l \%f" '.mainfname.'.dvi &' else if a:size == "all" *************** *** 253,257 **** exec '!start '.viewer.' -s '.line('.').expand('%:p:t').' '.mainfname else ! exec '!'.viewer.' -name xdvi -sourceposition '.line('.').expand('%').' '.mainfname.'.dvi' end --- 261,272 ---- exec '!start '.viewer.' -s '.line('.').expand('%:p:t').' '.mainfname else ! if exists('g:Tex_UseEditorSettingInDVIViewer') && ! \ g:Tex_UseEditorSettingInDVIViewer == 1 && ! \ exists('v:servername') && ! \ (viewer == "xdvi" || viewer == "xdvik") && ! exec '!'.viewer.' -name xdvi -sourceposition '.line('.').expand('%').' -editor "gvim --servername '.v:servername.' --remote-silent +\%l \%f" '.mainfname.'.dvi &' ! else ! exec '!'.viewer.' -name xdvi -sourceposition '.line('.').expand('%').' '.mainfname.'.dvi &' ! endif end |
From: <mi...@us...> - 2003-04-06 22:59:53
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv17470 Modified Files: packages.vim Log Message: check if in current directory exists user package and scan it for usepackage, newcommand etc. TODO - TEXINPUTS, use glob or globpath Index: packages.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** packages.vim 28 Feb 2003 20:21:51 -0000 1.29 --- packages.vim 6 Apr 2003 22:59:50 -0000 1.30 *************** *** 186,189 **** --- 186,191 ---- function! Tex_pack_all(fname) + let g:lastname = a:fname + let pos = line('.').' | normal! '.virtcol('.').'|' let currfile = expand('%:p') *************** *** 202,207 **** " Scan while search('^\s*\\usepackage\_.\{-}{\_.\+}', 'W') ! if line('.') > beginline ! break endif --- 204,212 ---- " Scan while search('^\s*\\usepackage\_.\{-}{\_.\+}', 'W') ! ! if !exists("s:Tex_up_check") ! if line('.') > beginline ! break ! endif endif *************** *** 270,275 **** while search('^\s*\\newcommand\*\?{.\{-}}', 'W') ! if line('.') > endline ! break endif --- 275,282 ---- while search('^\s*\\newcommand\*\?{.\{-}}', 'W') ! if !exists("s:Tex_up_check") ! if line('.') > endline ! break ! endif endif *************** *** 287,292 **** while search('^\s*\\newenvironment\*\?{.\{-}}', 'W') ! if line('.') > endline ! break endif --- 294,301 ---- while search('^\s*\\newenvironment\*\?{.\{-}}', 'W') ! if !exists("s:Tex_up_check") ! if line('.') > endline ! break ! endif endif *************** *** 300,303 **** --- 309,351 ---- q endif + + " Check if one of declared packages isn't user package in current (TODO: + " or $TEXINPUTS or declared in texrc or ...) + if !exists("s:Tex_up_check") + " Prevents endless loop + let s:Tex_up_check = 1 + + " Operate on list of packages from current/main file, + " g:Tex_package_detected will be changing + let tpd_orig = g:Tex_package_detected + + " Iterate through original list + let fn = 1 + while Tex_Strntok(tpd_orig, ',', fn) != '' + let userpackage = Tex_Strntok(tpd_orig, ',', fn) + let stypath = expand("%:p:h").'/'.userpackage.'.sty' + + " If package with given name exists in user space (not TeX space) + " check if there are usepackage commands, newcommand etc. + if filereadable(stypath) + let g:path = stypath + call Tex_pack_all(stypath) + + " Remove this file from list of buffers + exe 'bwipe '.stypath + + " But add word completion - if such file exists probably there + " is huge collection of commands, <F7> doesn't solve + " everything + exe 'setlocal complete+=s'.stypath + + endif + + let fn = fn + 1 + + endwhile + + endif + exe pos endfunction |
From: <mi...@us...> - 2003-04-06 22:59:42
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv17410 Modified Files: wizardfuncs.vim Log Message: improved F1 wrapper: proper error message (thanks Benji), checks for environment names Index: wizardfuncs.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/wizardfuncs.vim,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** wizardfuncs.vim 4 Apr 2003 23:25:03 -0000 1.10 --- wizardfuncs.vim 6 Apr 2003 22:59:37 -0000 1.11 *************** *** 204,219 **** " ============================================================================== ! inoremap <buffer> <silent> <F1> <C-O>:silent! call <SID>TexHelp()<CR> ! nnoremap <buffer> <silent> <F1> :silent! call <SID>TexHelp()<CR> ! command! -nargs=0 THelp silent! call <SID>TexHelp() " TexHelp: Cursor being on LaTeX item check if exists help tag about it " {{{ function! s:TexHelp() ! if synIDattr(synID(line('.'),col('.')-1,0),"name") =~ '^tex' setlocal isk+=\ let curword = expand('<cword>') setlocal isk-=\ ! if curword =~ "^\\" ! exe 'help ' . curword else help --- 204,227 ---- " ============================================================================== ! inoremap <buffer> <silent> <F1> <C-O>:call <SID>TexHelp()<CR> ! nnoremap <buffer> <silent> <F1> :call <SID>TexHelp()<CR> ! command! -nargs=0 THelp call <SID>TexHelp() " TexHelp: Cursor being on LaTeX item check if exists help tag about it " {{{ function! s:TexHelp() ! let syntax_item = synIDattr(synID(line('.'),col('.')-1,0),"name") ! if syntax_item =~ '^tex' setlocal isk+=\ let curword = expand('<cword>') setlocal isk-=\ ! let v:errmsg = '' ! if curword =~ "^\\" || syntax_item == 'texSectionName' ! exe 'silent! help '.curword ! if v:errmsg =~ '^E149:' ! echohl ErrorMsg ! exe "echomsg 'Sorry, no help for LaTeX: ".curword."'" ! echohl None ! let v:errmsg = '' ! endif else help |
From: <mi...@us...> - 2003-04-05 21:35:53
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv28597 Modified Files: texviewer.vim Log Message: Relative path under Windows was given with wrong file delimiter Index: texviewer.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** texviewer.vim 4 Apr 2003 23:24:46 -0000 1.5 --- texviewer.vim 5 Apr 2003 21:35:50 -0000 1.6 *************** *** 329,333 **** let path1 = a:explfilename let path2 = a:texfilename ! if has("win32") let path1 = substitute(path1, '\\', '/', 'ge') let path2 = substitute(path2, '\\', '/', 'ge') --- 329,333 ---- let path1 = a:explfilename let path2 = a:texfilename ! if has("win32") || has("win16") || has("dos32") || has("dos16") let path1 = substitute(path1, '\\', '/', 'ge') let path2 = substitute(path2, '\\', '/', 'ge') *************** *** 343,346 **** --- 343,349 ---- endif let relpath = subrelpath.path1 + if has("win32") || has("win16") || has("dos32") || has("dos16") + let relpath = substitute(relpath, '/', "\\", 'ge') + endif return relpath endfunction " }}} *************** *** 350,352 **** let s:doneOnce = 1 ! " vim:fdm=marker:nowrap:noet:ff=unix --- 353,355 ---- let s:doneOnce = 1 ! " vim:fdm=marker:nowrap:noet:ff=unix:ts=4:sw=4 |
From: <mi...@us...> - 2003-04-04 23:27:48
|
Update of /cvsroot/vim-latex/vimfiles/plugin In directory sc8-pr-cvs1:/tmp/cvs-serv30664 Added Files: explorer.vim Log Message: This is almost standard version of explorer plugin. This addition to lS is necessary for things like explorer-completion. Change is to make EditEntry function global available. It makes possible to remap standard explorer shortcuts for better interaction with lS. I signalized this on vi...@vi... and hope it will be standard behaviour of explorer.vim in next Vim editions thus we won't need this file. But for today pros are much more than contras I think. (sorry for my english today, please correct my faults in latex-suite.txt if you find few minutes) --- NEW FILE: explorer.vim --- "============================================================================= " File: explorer.vim " Author: M A Aziz Ahmed (az...@ac...) " Last Change: 2002 Jun 12 " Version: 2.5 + changes " Additions by Mark Waggoner (wag...@ar...) et al. "----------------------------------------------------------------------------- " This file implements a file explorer. Latest version available at: " http://www.freespeech.org/aziz/vim/ " Updated version available at: " http://www.aracnet.com/~waggoner "----------------------------------------------------------------------------- " Normally, this file will reside in the plugins directory and be " automatically sourced. If not, you must manually source this file " using :source explorer.vim " " To use it, just edit a directory (vi dirname) or type :Explore to " launch the file explorer in the current window, or :Sexplore to split " the current window and launch explorer there. [...1242 lines suppressed...] call s:EditDir() endwhile endfunction "--- " Set up the autocommand to allow directories to be edited " augroup fileExplorer au! " Fill the window when entering the buffer; ":edit dir". au BufEnter * call s:EditDir() " Set the window variables after a split; ":split". au WinEnter * if !exists("w:sortdirection") | call s:EditDir() | endif " Fill the windows after Vim has started up. au VimEnter * call s:EditAll() augroup end " restore 'cpo' let &cpo = s:cpo_save unlet s:cpo_save |
From: <mi...@us...> - 2003-04-04 23:25:14
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv29639 Modified Files: texrc Log Message: new variables for latex completion description in file and latex-suite.txt Index: texrc =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texrc,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** texrc 3 Apr 2003 14:29:17 -0000 1.23 --- texrc 4 Apr 2003 23:25:11 -0000 1.24 *************** *** 76,93 **** " ------------------------------------------------------------------------------ " Compiler rules {{{ - " This section specifies the rules for compiling tex into other formats. - " They have been set by defaults to use the most common programs. - " " This is the first thing you should customize. It is set up for most common " values, but if use some other compiler, then you will want to change this. ! if has('win32') ! let s:CompileFlags = '--src-specials' ! TexLet g:Tex_EscapeChars = '' ! else ! let s:CompileFlags = '' ! TexLet g:Tex_EscapeChars = '{}\' ! endif TexLet g:Tex_CompileRule_dvi = 'latex ' . s:CompileFlags . ! \ ' \nonstopmode \input{$*}' TexLet g:Tex_CompileRule_ps = 'dvips -Ppdf -o $*.ps $*.dvi' --- 76,88 ---- " ------------------------------------------------------------------------------ " Compiler rules {{{ " This is the first thing you should customize. It is set up for most common " values, but if use some other compiler, then you will want to change this. ! " As CompileFlags value you'd perhaps like to use, e.g., '-src-specials', ! " but it is known that it can sometimes give different results in the output, ! " so use it with care. ! let s:CompileFlags = '' ! TexLet g:Tex_EscapeChars = '{}\' TexLet g:Tex_CompileRule_dvi = 'latex ' . s:CompileFlags . ! \ ' -interaction=nonstopmode $*' TexLet g:Tex_CompileRule_ps = 'dvips -Ppdf -o $*.ps $*.dvi' *************** *** 96,100 **** " NOTE: pdflatex generates the same output as latex. therefore quickfix is " possible. ! TexLet g:Tex_CompileRule_pdf = 'pdflatex \nonstopmode \input {$*.tex}' " TexLet g:Tex_CompileRule_pdf = 'ps2pdf $*.ps' " TexLet g:Tex_CompileRule_pdf = 'dvipdfm $*.dvi' --- 91,96 ---- " NOTE: pdflatex generates the same output as latex. therefore quickfix is " possible. ! TexLet g:Tex_CompileRule_pdf = 'pdflatex -interaction=nonstopmode $*.tex' ! " TexLet g:Tex_CompileRule_pdf = 'ps2pdf $*.ps' " TexLet g:Tex_CompileRule_pdf = 'dvipdfm $*.dvi' *************** *** 110,117 **** " when calling them. The viewer therefore cannot accept arguments after " the filename. if has('win32') ! TexLet g:Tex_ViewRule_ps = 'gsview32' ! TexLet g:Tex_ViewRule_pdf = 'AcroRd32' ! TexLet g:Tex_ViewRule_dvi = 'yap -1' elseif has('macunix') " Let the system pick. If you want, you can override the choice here. --- 106,117 ---- " when calling them. The viewer therefore cannot accept arguments after " the filename. + " Important for Windows users: + " you should adapt the absolute path for gsview32 and AcroRd32 calls; + " below you can find some standard locations of those programs. + " Tex_ViewRule_dvi value can be set to 'yap -1' or 'windvi'. if has('win32') ! TexLet g:Tex_ViewRule_ps = 'C:\Ghostgum\gsview\gsview32' ! TexLet g:Tex_ViewRule_pdf = 'C:\Progra~1\Adobe\Acroba~1.0\Reader\AcroRd32' ! TexLet g:Tex_ViewRule_dvi = 'yap -1' elseif has('macunix') " Let the system pick. If you want, you can override the choice here. *************** *** 412,424 **** " }}} ! " TeX Viewer: {{{ " Options for preview window for ref/cite completion. - " Height of cwindow TexLet g:Tex_ViewerCwindowHeight = 5 - " Height of preview window TexLet g:Tex_ViewerPreviewHeight = 10 " }}} --- 412,429 ---- " }}} ! " TeX Completion: {{{ ! " " Options for preview window for ref/cite completion. " Height of cwindow TexLet g:Tex_ViewerCwindowHeight = 5 " Height of preview window TexLet g:Tex_ViewerPreviewHeight = 10 + " Options for explorer completion. + " Height of explorer window + TexLet g:Tex_ExplorerHeight = 10 + + " Directory for images. Read |latex-completion-explorer| before changing + TexLet g:Tex_ImageDir = '' " }}} |
From: <mi...@us...> - 2003-04-04 23:25:06
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv29733 Modified Files: wizardfuncs.vim Log Message: comments, fixing bugs for partial compilation, using <Plug> for mapping Index: wizardfuncs.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/wizardfuncs.vim,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** wizardfuncs.vim 4 Apr 2003 00:55:46 -0000 1.9 --- wizardfuncs.vim 4 Apr 2003 23:25:03 -0000 1.10 *************** *** 206,210 **** inoremap <buffer> <silent> <F1> <C-O>:silent! call <SID>TexHelp()<CR> nnoremap <buffer> <silent> <F1> :silent! call <SID>TexHelp()<CR> ! command! -nargs=0 THelp silent! call <SID>TexHelp()<CR> " TexHelp: Cursor being on LaTeX item check if exists help tag about it " {{{ --- 206,210 ---- inoremap <buffer> <silent> <F1> <C-O>:silent! call <SID>TexHelp()<CR> nnoremap <buffer> <silent> <F1> :silent! call <SID>TexHelp()<CR> ! command! -nargs=0 THelp silent! call <SID>TexHelp() " TexHelp: Cursor being on LaTeX item check if exists help tag about it " {{{ *************** *** 225,241 **** " ============================================================================== ! " Partial compilation " ============================================================================== ! map <F10> :call Tex_PartCompilation()<cr> ! " Tex_PartCompilation: compilation of selected fragment ! function! Tex_PartCompilation() range ! let mainfile = Tex_GetMainFileName() let g:partcomp = 1 let tmpfile = tempname() let g:tfile = tmpfile if mainfile != '' exe 'bot 1 split '.mainfile --- 225,258 ---- " ============================================================================== ! " Partial compilation and viewing output " ============================================================================== ! " ! nnoremap <silent> <Plug>Tex_PartCompilation :call Tex_PartCompilation("f","l","v")<CR> ! if !hasmapto('<Plug>Tex_PartCompilation',"v") ! nnoremap <buffer> <silent> <F10> <Plug>Tex_PartCompilation ! endif ! map <F10> :call Tex_PartCompilation("f","l", "v")<cr> ! command! -nargs=0 -range TPartComp silent! call Tex_PartCompilation(<line1>,<line2>, "c") ! command! -nargs=0 TPartView silent! call ViewLaTeX("part") ! ! " Tex_PartCompilation: compilation of selected fragment {{{ ! function! Tex_PartCompilation(fline,lline,mode) range ! ! " Set partial compilation flag let g:partcomp = 1 + " Save position + let pos = line('.').' | normal! '.virtcol('.').'|' + " Create temporary file and save its name into global variable to use in + " compiler.vim let tmpfile = tempname() let g:tfile = tmpfile + "Create temporary file + " If mainfile exists open it in tiny window and extract preamble there, + " otherwise do it from current file + let mainfile = Tex_GetMainFileName() if mainfile != '' exe 'bot 1 split '.mainfile *************** *** 245,252 **** exe '1,/\s*\\begin{document}/w '.tmpfile endif ! ! let pos = line('.').' | normal! '.virtcol('.').'|' ! ! exe a:firstline.','.a:lastline."w >> ".tmpfile let _clipboard = @c let @c = '\end{document}' --- 262,272 ---- exe '1,/\s*\\begin{document}/w '.tmpfile endif ! " Write range to file, check how it works with marks, range and //,// ! if a:mode == 'v' ! exe a:firstline.','.a:lastline."w! >> ".tmpfile ! else ! exe a:fline.','.a:lline."w! >> ".tmpfile ! endif ! " Add \end{document} to temporary file. Is it really the only way? let _clipboard = @c let @c = '\end{document}' *************** *** 256,261 **** let @c = _clipboard - exe pos silent! call RunLaTeX() unlet g:partcomp --- 276,283 ---- let @c = _clipboard silent! call RunLaTeX() + + " Unlet partial compilation flag for not interfering with normal + " compilation. Maybe argument for RunLaTeX() is better? unlet g:partcomp |
From: <mi...@us...> - 2003-04-04 23:24:50
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv29635 Modified Files: texviewer.vim Log Message: handling of includegraphics, bibliography commands; introduction of explorer-completion; more info in latex-suite.txt - latex-completion Index: texviewer.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** texviewer.vim 3 Apr 2003 17:37:38 -0000 1.4 --- texviewer.vim 4 Apr 2003 23:24:46 -0000 1.5 *************** *** 8,19 **** " ============================================================================ ! if exists("g:Tex_Viewer") finish endif ! inoremap <silent> <Plug>Tex_Viewer <Esc>:call Tex_viewer("default","text")<CR> ! if !hasmapto('<Plug>Tex_Viewer', 'i') ! imap <buffer> <silent> <buffer> <F9> <Plug>Tex_Viewer endif --- 8,19 ---- " ============================================================================ ! if exists("g:Tex_Completion") finish endif ! inoremap <silent> <Plug>Tex_Completion <Esc>:call Tex_completion("default","text")<CR> ! if !hasmapto('<Plug>Tex_Completion', 'i') ! imap <buffer> <silent> <F9> <Plug>Tex_Completion endif *************** *** 23,35 **** function! s:Tex_lookall(what) ! call Tex_viewer(a:what, "all") endfunction function! s:Tex_lookbib(what) ! call Tex_viewer(a:what, "bib") endfunction function! s:Tex_look(what) ! call Tex_viewer(a:what, "tex") endfunction --- 23,35 ---- function! s:Tex_lookall(what) ! call Tex_completion(a:what, "all") endfunction function! s:Tex_lookbib(what) ! call Tex_completion(a:what, "bib") endfunction function! s:Tex_look(what) ! call Tex_completion(a:what, "tex") endfunction *************** *** 43,47 **** " Description: " ! function! Tex_viewer(what, where) " Get info about current window and position of cursor in file --- 43,47 ---- " Description: " ! function! Tex_completion(what, where) " Get info about current window and position of cursor in file *************** *** 52,56 **** if a:where == "text" " What to do after <F9> depending on context ! let s:curline = strpart(getline('.'), col('.') - 20, 20) let s:prefix = matchstr(s:curline, '{\zs.\{-}$') let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$') --- 52,56 ---- if a:where == "text" " What to do after <F9> depending on context ! let s:curline = strpart(getline('.'), col('.') - 40, 40) let s:prefix = matchstr(s:curline, '{\zs.\{-}$') let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$') *************** *** 66,71 **** --- 66,95 ---- call <SID>Tex_c_window_setup() + elseif exists("s:type") && s:type =~ 'includegraphics' + let s:storehidefiles = g:explHideFiles + let g:explHideFiles = '^\.,\.tex$,\.bib$,\.bbl$,\.zip$,\.gz$$' + let s:curfile = expand("%:p") + exe 'silent! Sexplore '.s:search_directory.g:Tex_ImageDir + call <SID>Tex_explore_window("includegraphics") + + elseif exists("s:type") && s:type =~ 'bibliography' + let s:storehidefiles = g:explHideFiles + let g:explHideFiles = '^\.,\.tex$,\.pdf$,\.eps$,\.zip$,\.gz$' + let s:curfile = expand("%:p") + exe 'silent! Sexplore '.s:search_directory + call <SID>Tex_explore_window("bibliography") + else let s:word = matchstr(s:curline, '\zs\k\{-}$') + if s:word == '' + if col('.') == strlen(getline('.')) + startinsert! + return + else + normal! l + startinsert + return + endif + endif exe 'silent! grep! "\<' . s:word . '" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() *************** *** 110,115 **** " Change behaviour of <cr> only for 'ref' and 'cite' context. ! if exists("s:type") && s:type =~ 'ref\|cite' ! nnoremap <buffer> <silent> <cr> :call <SID>CompleteName()<CR> else --- 134,142 ---- " Change behaviour of <cr> only for 'ref' and 'cite' context. ! if exists("s:type") && s:type =~ 'ref' ! nnoremap <buffer> <silent> <cr> :silent! call <SID>CompleteName("ref")<CR> ! ! elseif exists("s:type") && s:type =~ 'cite' ! nnoremap <buffer> <silent> <cr> :silent! call <SID>CompleteName("cite")<CR> else *************** *** 126,129 **** --- 153,169 ---- endfunction " }}} + " Tex_explore_window: settings for completion of filenames {{{ + " Description: + " + function! s:Tex_explore_window(type) + + exe g:Tex_ExplorerHeight.' wincmd _' + if a:type == 'includegraphics' + nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("includegraphics")<CR> + elseif a:type == 'bibliography' + nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("bibliography")<CR> + endif + + endfunction " }}} " UpdateViewerWindow: update error and preview window {{{ " Description: Usually quickfix engine takes care about most of these things *************** *** 195,201 **** " Description: handle completion of items depending on current context " ! function! s:CompleteName() ! if s:type =~ 'cite' if getline('.') =~ '\\bibitem{' let bibkey = matchstr(getline('.'), '\\bibitem{\zs.\{-}\ze}') --- 235,241 ---- " Description: handle completion of items depending on current context " ! function! s:CompleteName(type) ! if a:type =~ 'cite' if getline('.') =~ '\\bibitem{' let bibkey = matchstr(getline('.'), '\\bibitem{\zs.\{-}\ze}') *************** *** 205,219 **** let completeword = strpart(bibkey, strlen(s:prefix)) ! elseif s:type =~ 'ref' let label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') let completeword = strpart(label, strlen(s:prefix)) endif " Return to proper place in main window, close small windows ! exe s:winnum.' wincmd w' ! pclose! ! cclose ! exe s:pos " Complete word, check if add closing } --- 245,286 ---- let completeword = strpart(bibkey, strlen(s:prefix)) ! elseif a:type =~ 'ref' let label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') let completeword = strpart(label, strlen(s:prefix)) + + elseif a:type =~ 'includegraphics\|bibliography' + let line = substitute(strpart(getline('.'),0,b:maxFileLen),'\s\+$','','') + if isdirectory(b:completePath.line) + call EditEntry("", "edit") + exe 'nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("'.a:type.'")<CR>' + let g:explHideFiles = s:storehidefiles + return + + else + let ifile = substitute(line, '\..\{-}$', '', '') + let filename = b:completePath.ifile + + if g:Tex_ImageDir != '' && a:type =~ 'includegraphics' + let imagedir = s:curfile . g:Tex_ImageDir + let completeword = <SID>Tex_RelPath(filename, imagedir) + else + let completeword = <SID>Tex_RelPath(filename, s:curfile) + endif + + let g:explHideFiles = s:storehidefiles + endif endif " Return to proper place in main window, close small windows ! if s:type =~ 'cite\|ref' ! exe s:winnum.' wincmd w' ! pclose! ! cclose ! exe s:pos ! elseif s:type =~ 'includegraphics\|bibliography' ! wincmd q ! exe s:pos ! endif " Complete word, check if add closing } *************** *** 246,250 **** endfunction " }}} ! let g:Tex_Viewer = 1 " this statement has to be at the end. let s:doneOnce = 1 --- 313,350 ---- endfunction " }}} ! " Tex_Common: common part of strings {{{ ! function! s:Tex_Common(path1, path2) ! " Assume the caller handles 'ignorecase' ! if a:path1 == a:path2 ! return a:path1 ! endif ! let n = 0 ! while a:path1[n] == a:path2[n] ! let n = n+1 ! endwhile ! return strpart(a:path1, 0, n) ! endfunction " }}} ! " Tex_RelPath: ultimate file name {{{ ! function! s:Tex_RelPath(explfilename,texfilename) ! let path1 = a:explfilename ! let path2 = a:texfilename ! if has("win32") ! let path1 = substitute(path1, '\\', '/', 'ge') ! let path2 = substitute(path2, '\\', '/', 'ge') ! endif ! let n = matchend(<SID>Tex_Common(path1, path2), '.*/') ! let path1 = strpart(path1, n) ! let path2 = strpart(path2, n) ! if path2 !~ '/' ! let subrelpath = '' ! else ! let subrelpath = substitute(path2, '[^/]\{-}/', '../', 'ge') ! let subrelpath = substitute(subrelpath, '[^/]*$', '', 'ge') ! endif ! let relpath = subrelpath.path1 ! return relpath ! endfunction " }}} ! ! let g:Tex_Completion = 1 " this statement has to be at the end. let s:doneOnce = 1 |
From: <mi...@us...> - 2003-04-04 23:24:42
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv29550 Modified Files: latex-suite.txt Log Message: info about partial compilation and changed info from latex viewer to latex completion and updated. New term IMO better describes what is this for Index: latex-suite.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** latex-suite.txt 3 Apr 2003 14:29:05 -0000 1.16 --- latex-suite.txt 4 Apr 2003 23:24:39 -0000 1.17 *************** *** 75,80 **** Mappings of some common keys like <BS> to make editing faster. ! |latex-viewer| ! Fast access to list of labels and bibliography keys. |latex-bracketing-macros| --- 75,82 ---- Mappings of some common keys like <BS> to make editing faster. ! |latex-completion| ! Fast access to important data. Most notable are bibliography keys and ! labels, also fast inserting of file names in proper manner depending ! on context. Everything with one key! |latex-bracketing-macros| *************** *** 98,106 **** change what kinds of warnings/errors to ignore. ! |latex-viewing| This is a set of functions which open up the compiled .dvi document using the specified DVI viewer. ! |latex-searching| Xdvi (for UNIX) and Yap (for Windows) both provide ways for "forward searching" LaTeX documents. This section describes how to use these --- 100,112 ---- change what kinds of warnings/errors to ignore. ! |latex-part-compiling| ! Compile only chosen part of document. Fast way to check if chosen ! fragment is well formed. ! ! |latex-viewing| This is a set of functions which open up the compiled .dvi document using the specified DVI viewer. ! |latex-searching| Xdvi (for UNIX) and Yap (for Windows) both provide ways for "forward searching" LaTeX documents. This section describes how to use these *************** *** 412,419 **** }}} =========================================================================== ! LATEX VIEWER *latex-viewer* {{{ ! Latex suite provides easy way of looking through BibTeX keys and completing ! them. The same for completion of \ref-like entries. After you insert \cite{, you can press <F9> key (still in Insert mode). Two --- 418,427 ---- }}} =========================================================================== ! LATEX COMPLETION *latex-completion* {{{ ! After pressing "<magic_key>" (default <F9>) Latex-suite will try to complete ! argument of command (part between {}). Now available is support for \cite, ! \ref and their cousins. Also for \includegraphics and \bibliography ! (|latex-completion-explorer|). More to come. After you insert \cite{, you can press <F9> key (still in Insert mode). Two *************** *** 465,468 **** --- 473,497 ---- texrc you can configure height of these windows. + *latex-completion-explorer* + Latex-suite is distributed with slightly changed explorer.vim. This + modification allows to perform custom operations in explorer buffer. + + After \includegraphics{<F9> Latex-suite will open explorer buffer with current + directory or directory defined with g:Tex_ImageDir variable. When you choose + graphic file with <cr> its name will be inserted into file as bib key or + label. If g:Tex_ImageDir is set Latex-suite assume you also defined + \graphicspath{} command and will insert just file name (without extension). If + g:Tex_ImageDir is empty (default) it will put relative path to graphic file. + + After \bibliography{<F9> Latex-suite will open explorer buffer with current + directory. After <cr> name of relative path to chosen file (without extension) + will be inserted. + + In both cases explorer window will open with basic filter. You should not see + uninteresting in current context files. + + You can regulate height of explorer window with g:Tex_ExplorerHeight variable + (default 10). + }}} =========================================================================== *************** *** 687,690 **** --- 716,729 ---- \'You have requested¡'. \'Missing number, treated as zero.' + < + *latex-part-compiling* + You can compile only fragment of document. It can be useful to work on one + sophisticated equation or one chapter. + + Mark fragment in Visual mode and press <F10> (or choose this option from + TeX-Suite menu). This fragment will be saved to temporary file with preamble + and compiled to current target. View new created document with \ls shortcut or + TeX-Suite menu element. Two ":" commands are also available: very interesting + |TPartComp| and |TPartView|. }}} *************** *** 1059,1062 **** --- 1098,1110 ---- Note: TLookuses :grep command and is using 'grepprg'. Its regular expressions can be different from those of Vim. + + :TPartComp *TPartComp* + No argument allowed but accepts range in all formats. Define + fragment of interest with :'a,'b, :/a/,/b/, :'<,'> or :20,30. + All other rules of compilation apply. + + :TPartView *TPartView* + Show last compiled fragment. All rules of viewing apply but + |latex-searching|. }}} |
From: <mi...@us...> - 2003-04-03 17:37:42
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv22048 Modified Files: texviewer.vim Log Message: support inserting cite/ref from menu. Is it robust enough? Without redesigning menu part no more can be done Index: texviewer.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** texviewer.vim 3 Apr 2003 14:28:30 -0000 1.3 --- texviewer.vim 3 Apr 2003 17:37:38 -0000 1.4 *************** *** 203,224 **** let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,') endif ! exe s:winnum.' wincmd w' ! pclose! ! cclose ! exe s:pos ! let bibkey2 = strpart(bibkey, strlen(s:prefix)) ! exe 'normal! a'.bibkey2."}\<Esc>" elseif s:type =~ 'ref' ! let s:label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') ! exe s:winnum.' wincmd w' ! pclose! ! cclose ! exe s:pos ! let label2 = strpart(s:label, strlen(s:prefix)) ! exe 'normal! a'.label2."}\<Esc>" endif if col('.') == strlen(getline('.')) startinsert! --- 203,228 ---- let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,') endif ! let completeword = strpart(bibkey, strlen(s:prefix)) elseif s:type =~ 'ref' ! let label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') ! let completeword = strpart(label, strlen(s:prefix)) endif + " Return to proper place in main window, close small windows + exe s:winnum.' wincmd w' + pclose! + cclose + exe s:pos + + " Complete word, check if add closing } + exe 'normal! a'.completeword."\<Esc>" + + if getline('.')[col('.')] != '}' + exe "normal! a}\<Esc>" + endif + + " Return to Insert mode if col('.') == strlen(getline('.')) startinsert! |
From: <mi...@us...> - 2003-04-03 14:29:22
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv31330 Modified Files: texrc Log Message: configuration of windows heights in viewer Index: texrc =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texrc,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** texrc 3 Apr 2003 11:54:09 -0000 1.22 --- texrc 3 Apr 2003 14:29:17 -0000 1.23 *************** *** 415,420 **** " Options for preview window for ref/cite completion. " Height of preview window ! TexLet g:Tex_PreviewHeight = 10 " }}} --- 415,423 ---- " Options for preview window for ref/cite completion. + " Height of cwindow + TexLet g:Tex_ViewerCwindowHeight = 5 + " Height of preview window ! TexLet g:Tex_ViewerPreviewHeight = 10 " }}} |
From: <mi...@us...> - 2003-04-03 14:29:08
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv31265 Modified Files: latex-suite.txt Log Message: some info about grep and viewer on MS-Windows Index: latex-suite.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** latex-suite.txt 3 Apr 2003 11:54:10 -0000 1.15 --- latex-suite.txt 3 Apr 2003 14:29:05 -0000 1.16 *************** *** 454,459 **** --- 454,467 ---- cwindow. + Under MS-Windows you may need to make additional configuration of 'grepgrg' + option. If you have grep program default value "grep -n" doesn't show file + names if there is only one matching file. Place 'set grepprg=grep\ -Hn' in + your _vimrc. + Viewer module provides also three command-line utilities: |TLook|, |TLookBib| and |TLookAll|. + + Through g:Tex_ViewerCwindowHeight and g:Tex_ViewerPreviewHeight options in + texrc you can configure height of these windows. }}} |
From: <mi...@us...> - 2003-04-03 14:28:36
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv31196 Modified Files: texviewer.vim Log Message: full customization of cwindow and preview window height, vanilla 6.1 has bug which resizes cwindow - fixed with additional wincmd _ command Index: texviewer.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** texviewer.vim 3 Apr 2003 11:53:54 -0000 1.2 --- texviewer.vim 3 Apr 2003 14:28:30 -0000 1.3 *************** *** 98,102 **** cclose ! copen 5 setlocal nonumber setlocal nowrap --- 98,102 ---- cclose ! exe 'copen '. g:Tex_ViewerCwindowHeight setlocal nonumber setlocal nowrap *************** *** 146,149 **** --- 146,153 ---- pclose exe 'silent! bot pedit +'.viewline.' '.viewfile + + " Vanilla 6.1 has bug. This additional setting of cwindow height prevents + " resizing of this window + exe g:Tex_ViewerCwindowHeight.' wincmd _' " Handle situation if there is no item beginning with s:prefix. *************** *** 171,175 **** " Settings of preview window ! exe g:Tex_PreviewHeight.' wincmd _' setlocal foldlevel=10 --- 175,179 ---- " Settings of preview window ! exe g:Tex_ViewerPreviewHeight.' wincmd _' setlocal foldlevel=10 |
From: <mi...@us...> - 2003-04-03 11:54:14
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv29486 Modified Files: texrc Log Message: customization of preview window Index: texrc =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texrc,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** texrc 15 Jan 2003 16:23:13 -0000 1.21 --- texrc 3 Apr 2003 11:54:09 -0000 1.22 *************** *** 412,415 **** --- 412,422 ---- " }}} + " TeX Viewer: {{{ + " Options for preview window for ref/cite completion. + + " Height of preview window + TexLet g:Tex_PreviewHeight = 10 + + " }}} " }}} |
From: <mi...@us...> - 2003-04-03 11:54:14
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv29683 Modified Files: latex-suite.txt Log Message: info about first hightlighted line in cwindow for cite/ref completion Index: latex-suite.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** latex-suite.txt 2 Apr 2003 20:59:21 -0000 1.14 --- latex-suite.txt 3 Apr 2003 11:54:10 -0000 1.15 *************** *** 425,429 **** In cwindow you can move with j and k keys. Contex window will be automatically ! updated. If information visible in context window is not enough you can use J and K keys to move content of context window (without leaving cwindow). After you choose correct bibentry press <cr>. Additional windows will close --- 425,433 ---- In cwindow you can move with j and k keys. Contex window will be automatically ! updated. Current line will be highlighted. Note: first line is still ! highlighted. This is normal line of |quickfix|. You can use instead j and k ! |:cnext| and |:cprev| commands. ! ! If information visible in context window is not enough you can use J and K keys to move content of context window (without leaving cwindow). After you choose correct bibentry press <cr>. Additional windows will close |
From: <mi...@us...> - 2003-04-03 11:53:59
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv29681 Modified Files: texviewer.vim Log Message: label line in preview window in the middle higher preview window (height defined in texrc) support for .bbl files support for \thebibliography environment use grep! instead grep (no need for 'bot 1 split') Index: texviewer.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** texviewer.vim 1 Apr 2003 16:47:51 -0000 1.1 --- texviewer.vim 3 Apr 2003 11:53:54 -0000 1.2 *************** *** 12,16 **** endif ! inoremap <silent> <Plug>Tex_Viewer <Esc>:call <SID>Tex_viewer("default","text")<CR> if !hasmapto('<Plug>Tex_Viewer', 'i') --- 12,16 ---- endif ! inoremap <silent> <Plug>Tex_Viewer <Esc>:call Tex_viewer("default","text")<CR> if !hasmapto('<Plug>Tex_Viewer', 'i') *************** *** 23,35 **** function! s:Tex_lookall(what) ! call <SID>Tex_viewer(a:what, "all") endfunction function! s:Tex_lookbib(what) ! call <SID>Tex_viewer(a:what, "bib") endfunction function! s:Tex_look(what) ! call <SID>Tex_viewer(a:what, "tex") endfunction --- 23,35 ---- function! s:Tex_lookall(what) ! call Tex_viewer(a:what, "all") endfunction function! s:Tex_lookbib(what) ! call Tex_viewer(a:what, "bib") endfunction function! s:Tex_look(what) ! call Tex_viewer(a:what, "tex") endfunction *************** *** 43,47 **** " Description: " ! function! s:Tex_viewer(what, where) " Get info about current window and position of cursor in file --- 43,47 ---- " Description: " ! function! Tex_viewer(what, where) " Get info about current window and position of cursor in file *************** *** 56,74 **** let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$') - " It is necessary to open window and there process grep because Vim - " automatically jumps to first error in clist. - bot 1 split - if exists("s:type") && s:type =~ 'ref' ! exe 'silent! grep "\\label{'.s:prefix.'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif exists("s:type") && s:type =~ 'cite' ! exe 'silent! grep "@.*{'.s:prefix.'" '.s:search_directory.'*.bib' call <SID>Tex_c_window_setup() else let s:word = matchstr(s:curline, '\zs\k\{-}$') ! exe 'silent! grep "\<' . s:word . '" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() --- 56,72 ---- let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$') if exists("s:type") && s:type =~ 'ref' ! exe 'silent! grep! "\\label{'.s:prefix.'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif exists("s:type") && s:type =~ 'cite' ! exe 'silent! grep! "@.*{'.s:prefix.'" '.s:search_directory.'*.bib' ! exe 'silent! grepadd! "bibitem{'.s:prefix.'" '.s:search_directory.'*.bbl' ! exe 'silent! grepadd! "bibitem{'.s:prefix.'" %' call <SID>Tex_c_window_setup() else let s:word = matchstr(s:curline, '\zs\k\{-}$') ! exe 'silent! grep! "\<' . s:word . '" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() *************** *** 77,94 **** elseif a:where == 'tex' " Process :TLook command ! bot 1 split ! exe 'silent! grep "'. a:what .'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif a:where == 'bib' " Process :TLookBib command ! bot 1 split ! exe 'silent! grep "'. a:what .'" '.s:search_directory.'*.bib' call <SID>Tex_c_window_setup() elseif a:where == "all" " Process :TLookAll command ! bot 1 split ! exe 'silent! grep "'. a:what .'" '.s:search_directory.'*' call <SID>Tex_c_window_setup() --- 75,90 ---- elseif a:where == 'tex' " Process :TLook command ! exe 'silent! grep! "'.a:what.'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif a:where == 'bib' " Process :TLookBib command ! exe 'silent! grep! "'.a:what.'" '.s:search_directory.'*.bib' ! exe 'silent! grepadd! "'.a:what.'" '.s:search_directory.'*.bbl' call <SID>Tex_c_window_setup() elseif a:where == "all" " Process :TLookAll command ! exe 'silent! grep! "'.a:what.'" '.s:search_directory.'*' call <SID>Tex_c_window_setup() *************** *** 101,106 **** function! s:Tex_c_window_setup() - wincmd q - cclose copen 5 --- 97,100 ---- *************** *** 154,158 **** " Handle situation if there is no item beginning with s:prefix. ! " Unfortunately, because we know it late we have to close everthing and " return as in complete process if v:errmsg =~ 'E32\>' --- 148,152 ---- " Handle situation if there is no item beginning with s:prefix. ! " Unfortunately, because we know it late we have to close everything and " return as in complete process if v:errmsg =~ 'E32\>' *************** *** 177,184 **** " Settings of preview window ! 5 wincmd _ setlocal foldlevel=10 ! setlocal scrolloff=0 ! normal! zt " Return to cwindow --- 171,186 ---- " Settings of preview window ! exe g:Tex_PreviewHeight.' wincmd _' setlocal foldlevel=10 ! ! if s:type =~ 'cite' ! " In cite context place bibkey at the top of preview window. ! setlocal scrolloff=0 ! normal! zt ! else ! " In other contexts in the middle. Highlight this line? ! setlocal scrolloff=100 ! normal! z. ! endif " Return to cwindow *************** *** 191,196 **** function! s:CompleteName() ! if s:curline =~ 'cite' ! let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,') exe s:winnum.' wincmd w' pclose! --- 193,202 ---- function! s:CompleteName() ! if s:type =~ 'cite' ! if getline('.') =~ '\\bibitem{' ! let bibkey = matchstr(getline('.'), '\\bibitem{\zs.\{-}\ze}') ! else ! let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,') ! endif exe s:winnum.' wincmd w' pclose! *************** *** 200,204 **** exe 'normal! a'.bibkey2."}\<Esc>" ! elseif s:curline =~ 'ref' let s:label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') exe s:winnum.' wincmd w' --- 206,210 ---- exe 'normal! a'.bibkey2."}\<Esc>" ! elseif s:type =~ 'ref' let s:label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') exe s:winnum.' wincmd w' |
From: <mi...@us...> - 2003-04-03 11:53:45
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv29528 Modified Files: texmenuconf.vim Log Message: menu Complete Ref/Cite Index: texmenuconf.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texmenuconf.vim,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** texmenuconf.vim 12 Jan 2003 22:02:40 -0000 1.7 --- texmenuconf.vim 3 Apr 2003 11:53:39 -0000 1.8 *************** *** 48,60 **** exec 'anoremenu 80.90 '.s:mainmenuname.'Set\ &Ignore\ Level<tab>:TCLevel'. \' :TCLevel NONE<CR>' ! exec 'anoremenu 80.100 '.s:mainmenuname.'-sepsuite1- :' " refreshing folds if g:Tex_Folding ! exec 'anoremenu 80.100 '.s:mainmenuname.'Refresh\ Folds<tab>\\rf'. \' :call MakeTexFolds(1)<CR>' ! exec 'anoremenu 80.110 '.s:mainmenuname.'-sepsuite2- :' endif " editing private texrc ! exec 'anoremenu 80.120 '.s:mainmenuname.'Edit\ &texrc<tab>:Ttexrc'. \' :Ttexrc<CR>' --- 48,62 ---- exec 'anoremenu 80.90 '.s:mainmenuname.'Set\ &Ignore\ Level<tab>:TCLevel'. \' :TCLevel NONE<CR>' ! exec 'inoremenu 80.100 '.s:mainmenuname.'C&omplete\ Ref/Cite'. ! \' <Esc>:call Tex_viewer("default","text")<CR>' ! exec 'anoremenu 80.110 '.s:mainmenuname.'-sepsuite1- :' " refreshing folds if g:Tex_Folding ! exec 'anoremenu 80.120 '.s:mainmenuname.'&Refresh\ Folds<tab>\\rf'. \' :call MakeTexFolds(1)<CR>' ! exec 'anoremenu 80.130 '.s:mainmenuname.'-sepsuite2- :' endif " editing private texrc ! exec 'anoremenu 80.140 '.s:mainmenuname.'Edit\ &texrc<tab>:Ttexrc'. \' :Ttexrc<CR>' |
From: <mi...@us...> - 2003-04-02 20:59:26
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv1650 Modified Files: latex-suite.txt Log Message: add info abour F1 wrapper, few mispells, misformats and item in toc about texviewer.vim Index: latex-suite.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** latex-suite.txt 1 Apr 2003 16:47:26 -0000 1.13 --- latex-suite.txt 2 Apr 2003 20:59:21 -0000 1.14 *************** *** 24,28 **** {Vi of course does not have any of this} ! NOTE: If you are viewing this in vim 6.0+, then the sections should appear folded (see |folding|). Use |za| to toggle back and forth between open and closed views. --- 24,28 ---- {Vi of course does not have any of this} ! NOTE: If you are viewing this in Vim 6.0+, then the sections should appear folded (see |folding|). Use |za| to toggle back and forth between open and closed views. *************** *** 53,57 **** < set iskeyword+=: > " IMPORTANT: If you are a win32 user, then the following setting is ! " necessary in order to have latex called correctly from within vim. < set shellslash --- 53,57 ---- < set iskeyword+=: > " IMPORTANT: If you are a win32 user, then the following setting is ! " necessary in order to have latex called correctly from within Vim. < set shellslash *************** *** 70,81 **** |latex-macros| Insert mode and visual mode mappings and menu items for commonly used ! LaTeX typesetting elements |latex-smart-keys| ! mappings of some common keys like <BS> to make editing faster |latex-bracketing-macros| A streamlined way of entering all the \left's and \right's while ! typing latex |latex-templates| --- 70,84 ---- |latex-macros| Insert mode and visual mode mappings and menu items for commonly used ! LaTeX typesetting elements. |latex-smart-keys| ! Mappings of some common keys like <BS> to make editing faster. ! ! |latex-viewer| ! Fast access to list of labels and bibliography keys. |latex-bracketing-macros| A streamlined way of entering all the \left's and \right's while ! typing LaTeX. |latex-templates| *************** *** 107,113 **** ======= |latex-folding| ! manual folding based on LaTeX syntax elements. ! Pacakge Support =============== |latex-packages| --- 110,116 ---- ======= |latex-folding| ! Manual folding based on LaTeX syntax elements. ! Package Support =============== |latex-packages| *************** *** 118,122 **** =================== |latex-help| ! LaTeX's tex-info file translated into a vim help file. |latex-dictionary| --- 121,125 ---- =================== |latex-help| ! LaTeX's tex-info file translated into a Vim help file. |latex-dictionary| *************** *** 152,156 **** name, she can press Control-J (while still in insert-mode). This will take her directly to the next "place-holder". i.e, the <+caption text+> will be visually ! selected with vim in select mode again for typing in the caption. This saves on a lot of key presses. --- 155,159 ---- name, she can press Control-J (while still in insert-mode). This will take her directly to the next "place-holder". i.e, the <+caption text+> will be visually ! selected with Vim in select mode again for typing in the caption. This saves on a lot of key presses. *************** *** 399,403 **** Smart Space Latex-suite maps the <space> key in such a way that $ characters are not ! broken across lines. It does this by first setting tw=0 so that vim will not automatically break lines and then maps the <space> key to insert newlines keeping $$'s on the same line. --- 402,406 ---- Smart Space Latex-suite maps the <space> key in such a way that $ characters are not ! broken across lines. It does this by first setting tw=0 so that Vim will not automatically break lines and then maps the <space> key to insert newlines keeping $$'s on the same line. *************** *** 411,451 **** LATEX VIEWER *latex-viewer* {{{ ! Latex suite provides easy way of looking through BibTeX keys and completing them. The same for completion of \ref-like entries. ! After you insert \cite{, you can press <F9> key (still in Insert mode). Two ! small windows will open. Just below your main window will be list of ! bibliography keys completed from all .bib files in directory of .tex file. ! Name this window as cwindow. Third window is context window to show next few ! lines of current entry (usually the most important info like author, title etc.). ! In cwindow you can move with j and k keys. Contex window will be automatically ! updated. If information visible in context window is not enough you can use ! J and K keys to move content of context window (without leaving cwindow). ! After you choose correct bibentry press <cr>. Additional windows will close ! and \cite{ will be completed to \cite{bibentry}. q returns to main window and closes additional windows. ! If you remember beginning of desired key enter \cite{be. In cwindow will be shown only bibkeys beginning with "be". ! Very similar thing you can do with \ref{, after <F9> in cwindow will be visible all lines containing \label{...}. Also here use of prefix is possible. ! This works with all commads with "ref" or "cite" in them. Thus you will get ! bib completion with \citen, \citenum or \pageref. If you want to create your ! own command which use cite or ref mechanism make sure proper word is inside it. Example: > \newcommand{\pref}[1]{~(p.~\pageref{#1})} < ! <F9> works also with normal words. You can use it here: "Its name is ! tetr<F9>". Now Latex-suite will look in all .tex files in directory of edited ! file word which is beginning with "tetr". Note: <cr> has here different ! behavior. It does not try to complete word but moves you to location chosen in cwindow. ! Viewer module provides also three command-line utilities: |TLook|, |TLookBib| and |TLookAll|. --- 414,454 ---- LATEX VIEWER *latex-viewer* {{{ ! Latex suite provides easy way of looking through BibTeX keys and completing them. The same for completion of \ref-like entries. ! After you insert \cite{, you can press <F9> key (still in Insert mode). Two ! small windows will open. Just below your main window will be list of ! bibliography keys completed from all .bib files in directory of .tex file. ! Name this window as cwindow. Third window is context window to show next few ! lines of current entry (usually the most important info like author, title etc.). ! In cwindow you can move with j and k keys. Contex window will be automatically ! updated. If information visible in context window is not enough you can use ! J and K keys to move content of context window (without leaving cwindow). ! After you choose correct bibentry press <cr>. Additional windows will close ! and \cite{ will be completed to \cite{bibentry}. q returns to main window and closes additional windows. ! If you remember beginning of desired key enter \cite{be. In cwindow will be shown only bibkeys beginning with "be". ! Very similar thing you can do with \ref{, after <F9> in cwindow will be visible all lines containing \label{...}. Also here use of prefix is possible. ! This works with all commads with "ref" or "cite" in them. Thus you will get ! bib completion with \citen, \citenum or \pageref. If you want to create your ! own command which use cite or ref mechanism make sure proper word is inside it. Example: > \newcommand{\pref}[1]{~(p.~\pageref{#1})} < ! <F9> works also with normal words. You can use it here: "Its name is ! tetr<F9>". Now Latex-suite will look in all .tex files in directory of edited ! file word which is beginning with "tetr". Note: <cr> has here different ! behavior. It does not try to complete word but moves you to location chosen in cwindow. ! Viewer module provides also three command-line utilities: |TLook|, |TLookBib| and |TLookAll|. *************** *** 591,597 **** NOTE: For win32 users user MikTeX, sometimes the latex compiler's output has a bug where a single number is split across different lines. In this case, put ! the included vimlatex utility somehwere in your $PATH, make it executable and ! point g:tex_flavor to it. This is not always necessary, and you might want to ! try it without vimlatex till you first notice any problem. *latex-master-file* --- 594,600 ---- NOTE: For win32 users user MikTeX, sometimes the latex compiler's output has a bug where a single number is split across different lines. In this case, put ! the included vim-latexSuite somewhere in your $PATH, make it executable and ! point g:tex_flavor to it. This is not always necessary, and you ! might want to try it without vim-latexSuite till you first notice any problem. *latex-master-file* *************** *** 760,764 **** *latex-package-dictionary* Furthermore, if a file with the same name is found in the ! latex-suite/dictionaries/ directory, then that file will be added to vim's 'dictionary' setting for use with the |i_CTRL-X_CTRL-K| command. Package dictionary file should follow outlines specified in 'dictionary'. --- 763,767 ---- *latex-package-dictionary* Furthermore, if a file with the same name is found in the ! latex-suite/dictionaries/ directory, then that file will be added to Vim's 'dictionary' setting for use with the |i_CTRL-X_CTRL-K| command. Package dictionary file should follow outlines specified in 'dictionary'. *************** *** 766,770 **** *latex-package-file* ! A latex-package-file is a simple vim script which defines some global variables. These global variables are used by latex-suite to create the custom menu. See the |latex-package-file-writing| section how to define a customized --- 769,773 ---- *latex-package-file* ! A latex-package-file is a simple Vim script which defines some global variables. These global variables are used by latex-suite to create the custom menu. See the |latex-package-file-writing| section how to define a customized *************** *** 786,790 **** add options to the package etc. ! NOTE: Since the package file is a vim-script, you could define custom functions there, add mappings etc. --- 789,793 ---- add options to the package etc. ! NOTE: Since the package file is a Vim script, you could define custom functions there, add mappings etc. *************** *** 874,883 **** LATEX HELP *latex-help* {{{ ! latexhelp.txt is a collection of latex.info files `translated' into vim help ! format. Now you can seek for help for specific LaTeX item without exiting vim. Example: > :help \kill ! gives help for the LaTeX \kill command. In order to use this help file, you will need to run |:helptags| once after --- 877,889 ---- LATEX HELP *latex-help* {{{ ! latexhelp.txt is a collection of latex.info files `translated' into Vim help ! format. Now you can seek for help for specific LaTeX item without exiting Vim. Example: > :help \kill ! gives help for the LaTeX \kill command. ! ! You can also place cursor on LaTeX \item and press <F1>. If in latexhelp.txt ! is something about this you would be immediately taken there. In order to use this help file, you will need to run |:helptags| once after *************** *** 890,894 **** Latex-suite ships with a dictionary of over 600 commands from LaTeX and popular packages. When latex-suite starts up, it automatically adds this ! dictionary to vim's 'dictionary' option for use with vim's |i_CTRL-X_CTRL-K| command. --- 896,900 ---- Latex-suite ships with a dictionary of over 600 commands from LaTeX and popular packages. When latex-suite starts up, it automatically adds this ! dictionary to Vim's 'dictionary' option for use with Vim's |i_CTRL-X_CTRL-K| command. |
From: <mi...@us...> - 2003-04-02 20:59:03
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv1583 Modified Files: wizardfuncs.vim Log Message: F1 help for LaTeX items, docs in latex-suite.txt commit Index: wizardfuncs.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/wizardfuncs.vim,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** wizardfuncs.vim 12 Jan 2003 22:02:40 -0000 1.7 --- wizardfuncs.vim 2 Apr 2003 20:58:59 -0000 1.8 *************** *** 200,202 **** --- 200,225 ---- endfunction "}}} + " ============================================================================== + " Add looking help into latexhelp.txt + " ============================================================================== + + inoremap <buffer> <silent> <F1> <C-O>:silent! call TexHelp()<CR> + nnoremap <buffer> <silent> <F1> :silent! call TexHelp()<CR> + + function! TexHelp() + if synIDattr(synID(line('.'),col('.')-1,0),"name") =~ '^tex' + setlocal isk+=\ + let curword = expand('<cword>') + setlocal isk-=\ + if curword =~ "^\\" + exe 'help ' . curword + else + help + endif + else + help + endif + endfunction + + " " vim:fdm=marker:ff=unix:noet:ts=4:sw=4 |
From: <mi...@us...> - 2003-04-01 16:47:56
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex In directory sc8-pr-cvs1:/tmp/cvs-serv10702 Added Files: texviewer.vim Log Message: completion of \ref and \cite commands, more in latex-suite.txt commit --- NEW FILE: texviewer.vim --- " ============================================================================ " File: texviewer.vim " Author: Mikolaj Machowski " Created: Sun Jan 26 06:00 PM 2003 " Description: make a viewer for various purposes: \cite{, \ref{ " License: Vim Charityware License " Part of vim-latexSuite: http://vim-latex.sourceforge.net " ============================================================================ if exists("g:Tex_Viewer") finish endif inoremap <silent> <Plug>Tex_Viewer <Esc>:call <SID>Tex_viewer("default","text")<CR> if !hasmapto('<Plug>Tex_Viewer', 'i') imap <buffer> <silent> <buffer> <F9> <Plug>Tex_Viewer endif command -nargs=1 TLook call <SID>Tex_look(<q-args>) command -nargs=1 TLookAll call <SID>Tex_lookall(<q-args>) command -nargs=1 TLookBib call <SID>Tex_lookbib(<q-args>) function! s:Tex_lookall(what) call <SID>Tex_viewer(a:what, "all") endfunction function! s:Tex_lookbib(what) call <SID>Tex_viewer(a:what, "bib") endfunction function! s:Tex_look(what) call <SID>Tex_viewer(a:what, "tex") endfunction if getcwd() != expand("%:p:h") let s:search_directory = expand("%:h") . '/' else let s:search_directory = '' endif " Tex_viewer: main function {{{ " Description: " function! s:Tex_viewer(what, where) " Get info about current window and position of cursor in file let s:winnum = winnr() let s:pos = line('.').' | normal! '.virtcol('.').'|' let s:col = col('.') if a:where == "text" " What to do after <F9> depending on context let s:curline = strpart(getline('.'), col('.') - 20, 20) let s:prefix = matchstr(s:curline, '{\zs.\{-}$') let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$') " It is necessary to open window and there process grep because Vim " automatically jumps to first error in clist. bot 1 split if exists("s:type") && s:type =~ 'ref' exe 'silent! grep "\\label{'.s:prefix.'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif exists("s:type") && s:type =~ 'cite' exe 'silent! grep "@.*{'.s:prefix.'" '.s:search_directory.'*.bib' call <SID>Tex_c_window_setup() else let s:word = matchstr(s:curline, '\zs\k\{-}$') exe 'silent! grep "\<' . s:word . '" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() endif elseif a:where == 'tex' " Process :TLook command bot 1 split exe 'silent! grep "'. a:what .'" '.s:search_directory.'*.tex' call <SID>Tex_c_window_setup() elseif a:where == 'bib' " Process :TLookBib command bot 1 split exe 'silent! grep "'. a:what .'" '.s:search_directory.'*.bib' call <SID>Tex_c_window_setup() elseif a:where == "all" " Process :TLookAll command bot 1 split exe 'silent! grep "'. a:what .'" '.s:search_directory.'*' call <SID>Tex_c_window_setup() endif endfunction " }}} " Tex_c_window_setup: set maps and local settings for cwindow {{{ " Description: Set local maps jkJKq<cr> for cwindow. Also size and basic " settings " function! s:Tex_c_window_setup() wincmd q cclose copen 5 setlocal nonumber setlocal nowrap call <SID>UpdateViewerWindow() nnoremap <buffer> <silent> j j:call <SID>UpdateViewerWindow()<CR> nnoremap <buffer> <silent> k k:call <SID>UpdateViewerWindow()<CR> nnoremap <buffer> <silent> <up> <up>:call <SID>UpdateViewerWindow()<CR> nnoremap <buffer> <silent> <down> <down>:call <SID>UpdateViewerWindow()<CR> " Change behaviour of <cr> only for 'ref' and 'cite' context. if exists("s:type") && s:type =~ 'ref\|cite' nnoremap <buffer> <silent> <cr> :call <SID>CompleteName()<CR> else " In other contexts jump to place described in cwindow and close small " windows nnoremap <buffer> <silent> <cr> :call <SID>GoToLocation()<cr> endif nnoremap <buffer> <silent> J :wincmd j<cr><c-e>:wincmd k<cr> nnoremap <buffer> <silent> K :wincmd j<cr><c-y>:wincmd k<cr> exe 'nnoremap <buffer> <silent> q :'.s:winnum.' wincmd w<cr>:pclose!<cr>:cclose<cr>' endfunction " }}} " UpdateViewerWindow: update error and preview window {{{ " Description: Usually quickfix engine takes care about most of these things " but we discard it for better control of events. " function! s:UpdateViewerWindow() let viewfile = matchstr(getline('.'), '^\f*\ze|\d') let viewline = matchstr(getline('.'), '|\zs\d\+\ze|') " Hilight current line in cwindow " Normally hightlighting is done with quickfix engine but we use something " different and have to do it separately syntax clear runtime syntax/qf.vim exe 'syn match vTodo /\%'. line('.') .'l.*/' hi link vTodo Todo " Close preview window and open it again in new place pclose exe 'silent! bot pedit +'.viewline.' '.viewfile " Handle situation if there is no item beginning with s:prefix. " Unfortunately, because we know it late we have to close everthing and " return as in complete process if v:errmsg =~ 'E32\>' exe s:winnum.' wincmd w' pclose! cclose if exists("s:prefix") echomsg 'No bibkey, label or word beginning with "'.s:prefix.'"' endif if col('.') == strlen(getline('.')) startinsert! else normal! l startinsert endif let v:errmsg = '' return 0 endif " Move to preview window. Really is it under cwindow? wincmd j " Settings of preview window 5 wincmd _ setlocal foldlevel=10 setlocal scrolloff=0 normal! zt " Return to cwindow wincmd p endfunction " }}} " CompleteName: complete/insert name for current item {{{ " Description: handle completion of items depending on current context " function! s:CompleteName() if s:curline =~ 'cite' let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,') exe s:winnum.' wincmd w' pclose! cclose exe s:pos let bibkey2 = strpart(bibkey, strlen(s:prefix)) exe 'normal! a'.bibkey2."}\<Esc>" elseif s:curline =~ 'ref' let s:label = matchstr(getline('.'), '\\label{\zs.\{-}\ze}') exe s:winnum.' wincmd w' pclose! cclose exe s:pos let label2 = strpart(s:label, strlen(s:prefix)) exe 'normal! a'.label2."}\<Esc>" endif if col('.') == strlen(getline('.')) startinsert! else normal! l startinsert endif endfunction " }}} " GoToLocation: Go to chosen location {{{ " Description: Get number of current line and go to this number " function! s:GoToLocation() exe 'cc ' . line('.') pclose! cclose endfunction " }}} let g:Tex_Viewer = 1 " this statement has to be at the end. let s:doneOnce = 1 " vim:fdm=marker:nowrap:noet:ff=unix |
From: <mi...@us...> - 2003-04-01 16:47:30
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv10543 Modified Files: latex-suite.txt Log Message: description of texviewer.vim module Index: latex-suite.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** latex-suite.txt 4 Jan 2003 00:56:56 -0000 1.12 --- latex-suite.txt 1 Apr 2003 16:47:26 -0000 1.13 *************** *** 409,412 **** --- 409,455 ---- }}} =========================================================================== + LATEX VIEWER *latex-viewer* {{{ + + Latex suite provides easy way of looking through BibTeX keys and completing + them. The same for completion of \ref-like entries. + + After you insert \cite{, you can press <F9> key (still in Insert mode). Two + small windows will open. Just below your main window will be list of + bibliography keys completed from all .bib files in directory of .tex file. + Name this window as cwindow. Third window is context window to show next few + lines of current entry (usually the most important info like author, title + etc.). + + In cwindow you can move with j and k keys. Contex window will be automatically + updated. If information visible in context window is not enough you can use + J and K keys to move content of context window (without leaving cwindow). + After you choose correct bibentry press <cr>. Additional windows will close + and \cite{ will be completed to \cite{bibentry}. q returns to main window and + closes additional windows. + + If you remember beginning of desired key enter \cite{be. In cwindow will be + shown only bibkeys beginning with "be". + + Very similar thing you can do with \ref{, after <F9> in cwindow will be + visible all lines containing \label{...}. Also here use of prefix is possible. + + This works with all commads with "ref" or "cite" in them. Thus you will get + bib completion with \citen, \citenum or \pageref. If you want to create your + own command which use cite or ref mechanism make sure proper word is inside + it. Example: > + + \newcommand{\pref}[1]{~(p.~\pageref{#1})} + < + <F9> works also with normal words. You can use it here: "Its name is + tetr<F9>". Now Latex-suite will look in all .tex files in directory of edited + file word which is beginning with "tetr". Note: <cr> has here different + behavior. It does not try to complete word but moves you to location chosen in + cwindow. + + Viewer module provides also three command-line utilities: |TLook|, |TLookBib| + and |TLookAll|. + + }}} + =========================================================================== CUSTOM TEMPLATES *latex-templates* {{{ *************** *** 974,977 **** --- 1017,1045 ---- table of contents) and then creates a more intelligent template. + + :TLook *TLook* + Accepts one argument. Will look through .tex files in + directory of edited file for argument. It can be regexp. You + don't have to enclose argument in "". <cr> takes you to + location. Other keys work as described in |latex-viewer|. + Note: TLook uses :grep command and is using 'grepprg'. Its + regular expressions can be different from those of Vim. + + :TLookBib *TLookBib* + Accepts one argument. Will look through .bib files in + directory of edited file for argument. It can be regexp. You + don't have to enclose argument in "". <cr> takes you to + location. Other keys work as described in |latex-viewer|. + Note: TLookBib uses :grep command and is using 'grepprg'. Its + regular expressions can be different from those of Vim. + + :TLookAll *TLookAll* + Accepts one argument. Will look through all files in directory + of edited file for argument. It can be regexp. You don't have + to enclose argument in "". <cr> takes you to location. Other + keys work as described in |latex-viewer|. + Note: TLookuses :grep command and is using 'grepprg'. Its + regular expressions can be different from those of Vim. + }}} =========================================================================== |
From: <sri...@us...> - 2003-03-25 19:11:53
|
Update of /cvsroot/vim-latex/vimfiles/plugin In directory sc8-pr-cvs1:/tmp/cvs-serv7141 Modified Files: imaps.vim Log Message: Bug: If an abbreviatin contains \ or " characters, then the abbreviation is not expanded properly. (D. MacAlpine) Fix: Those characters need to be escaped before the quoting. Index: imaps.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/plugin/imaps.vim,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** imaps.vim 25 Mar 2003 08:20:11 -0000 1.30 --- imaps.vim 25 Mar 2003 19:11:40 -0000 1.31 *************** *** 245,249 **** let @a = _a ! let abbreviationRHS = escape(abbreviationRHS, '<') exec 'let abbreviationRHS = "'.abbreviationRHS.'"' --- 245,249 ---- let @a = _a ! let abbreviationRHS = escape(abbreviationRHS, '\<"') exec 'let abbreviationRHS = "'.abbreviationRHS.'"' |
From: <sri...@us...> - 2003-03-25 08:20:20
|
Update of /cvsroot/vim-latex/vimfiles/plugin In directory sc8-pr-cvs1:/tmp/cvs-serv8363 Modified Files: imaps.vim Log Message: Bug: Incorrect detection of abbreviations. If there was (were) abbreviations starting with the letter 'a', then typing 'a<space>' would trigger an expansion. Cause: The :iab command also echoes for partial completions. Solution: Check more thoroughly whether a word is an abbreviation LHS or not. Index: imaps.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/plugin/imaps.vim,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** imaps.vim 5 Feb 2003 23:29:04 -0000 1.29 --- imaps.vim 25 Mar 2003 08:20:11 -0000 1.30 *************** *** 235,243 **** " doesn't have the equivalent of the :mapcheck() function for " abbreviations. exec "redir @a | silent! iab ".lastword." | redir END" ! if @a =~ "No abbreviation found" return a:char endif ! let abbreviationRHS = matchstr(@a, "\n".'i\s\+\k\+\s\+@\?\zs.*') let abbreviationRHS = escape(abbreviationRHS, '<') exec 'let abbreviationRHS = "'.abbreviationRHS.'"' --- 235,248 ---- " doesn't have the equivalent of the :mapcheck() function for " abbreviations. + let _a = @a exec "redir @a | silent! iab ".lastword." | redir END" ! let abbreviationRHS = matchstr(@a."\n", "\n".'i\s\+'.lastword.'\+\s\+@\?\zs.*\ze'."\n") ! ! if @a =~ "No abbreviation found" || abbreviationRHS == "" ! let @a = _a return a:char endif ! ! let @a = _a let abbreviationRHS = escape(abbreviationRHS, '<') exec 'let abbreviationRHS = "'.abbreviationRHS.'"' |
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages In directory sc8-pr-cvs1:/tmp/cvs-serv14137 Added Files: flafter floatflt fn2end graphpap letterspace lscape multibox plain Log Message: new package files --- NEW FILE: flafter --- let g:TeX_package_option_flafter = '' let g:TeX_package_flafter = 'noo:suppressfloats,noo:suppress' " vim:ft=vim:ff=unix: --- NEW FILE: floatflt --- let g:TeX_package_option_floatflt = 'rflt,lflt,vflt' let g:TeX_package_floatflt = \ 'ens:floatingfigure:[<+loc+>]{<+spec+>},' \.'ens:floatingtable:[<+loc+>]{<+spec+>}' " vim:ft=vim:ff=unix: --- NEW FILE: fn2end --- let g:TeX_package_option_fn2end = '' let g:TeX_package_fn2end = 'makeendnotes,theendnotes' " vim:ft=vim:ff=unix: --- NEW FILE: graphpap --- let g:TeX_package_option_graphpap = '' let g:TeX_package_graphpap = 'brs:graphpaper[<+step+>](<+x1,y1+>)(<+x2,y2+>)' " vim:ft=vim:ff=unix: --- NEW FILE: letterspace --- let g:TeX_package_option_letterspace = '' let g:TeX_package_letterspace = 'nor:letterspace' " vim:ft=vim:ff=unix: --- NEW FILE: lscape --- let g:TeX_package_option_lscape = '' let g:TeX_package_lscape = 'env:landscape' " vim:ft=vim:ff=unix: --- NEW FILE: multibox --- let g:TeX_package_option_multibox = '' let g:TeX_package_multibox = 'multimake,multiframe' " vim:ft=vim:ff=unix: --- NEW FILE: plain --- let g:TeX_package_option_plain = '' let g:TeX_package_plain = 'env:plain' " vim:ft=vim:ff=unix: |
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages In directory sc8-pr-cvs1:/tmp/cvs-serv13958 Added Files: array bm bophook cases ccaption comma dropping enumerate everyshi times Log Message: new package files --- NEW FILE: array --- let g:TeX_package_option_array = '' let g:TeX_package_array = \ 'brs:newcolumntype{<+type+>}[<+no+>]{<+preamble+>},' \.'arraycolsep,' \.'tabcolsep,' \.'arrayrulewidth,' \.'doublerulesep,' \.'arraystretch,' \.'extrarowheight' " vim:ft=vim:ff=unix: --- NEW FILE: bm --- let g:TeX_package_option_bm = '' let g:TeX_package_bm = 'bra:bm' " vim:ft=vim:ff=unix: --- NEW FILE: bophook --- let g:TeX_package_option_bophook = '' let g:TeX_package_bophook = \ 'bra:AtBeginPage,' \.'bra:PageLayout' " vim:ft=vim:ff=unix: --- NEW FILE: cases --- let g:TeX_package_option_cases = '' let g:TeX_package_cases = \ 'ens:numcases:{<+label+>},' \.'ens:subnumcases:{<+label+>}' " vim:ft=vim:ff=unix: --- NEW FILE: ccaption --- let g:TeX_package_option_ccaption = '' let g:TeX_package_ccaption = \ 'bra:contcaption,' \.'bra:legend,' \.'bra:namedlegend,' \.'abovelegendskip,' \.'belowlegendskip,' \.'brd:newfixedcaption,' \.'brd:renewfixedcaption,' \.'brd:providefixedcaption,' \.'brs:newfloatenv[<+counter+>]{<+name+>}{<+ext+>}{<+etiq+>},' \.'brd:listfloats' " vim:ft=vim:ff=unix: --- NEW FILE: comma --- let g:TeX_package_option_comma = '' let g:TeX_package_comma = \ 'bra:commaform,' \.'bra:commaformtoken' " vim:ft=vim:ff=unix: --- NEW FILE: dropping --- let g:TeX_package_option_dropping = '' let g:TeX_package_dropping = \ 'brs:bigdrop{<+indent+>}{<+big+>}{<+font+>}{<+text+>},' \.'brs:dropping[<+indent+>]{<+big+>}{<+text+>}' " vim:ft=vim:ff=unix: --- NEW FILE: enumerate --- let g:TeX_package_option_enumerate = '' let g:TeX_package_enumerate = 'ens:enumerate:[<+prefix+>]' " vim:ft=vim:ff=unix: --- NEW FILE: everyshi --- let g:TeX_package_option_everyshi = '' let g:TeX_package_everyshi = 'bra:EveryShipOut' " vim:ft=vim:ff=unix: --- NEW FILE: times --- let g:TeX_package_option_times = '' let g:TeX_package_times = '' " vim:ft=vim:ff=unix: |