vim-latex-cvs Mailing List for Vim-Latex (Page 23)
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-23 17:29:03
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv31422/doc
Modified Files:
latex-suite.txt
Log Message:
Included project features
Index: latex-suite.txt
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** latex-suite.txt 13 Apr 2003 02:03:53 -0000 1.19
--- latex-suite.txt 23 Apr 2003 17:28:27 -0000 1.20
***************
*** 1,5 ****
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Sat Apr 12 06:00 PM 2003
By Srinath Avadhanula <sr...@fa...>,
--- 1,5 ----
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Sat Apr 16 06:00 PM 2003
By Srinath Avadhanula <sr...@fa...>,
***************
*** 554,557 ****
--- 554,586 ----
You can ofcourse place your own templates in this directory.
+
+ }}}
+ ===========================================================================
+ LATEX PROJECT *latex-project* {{{
+
+ LaTeX-suite is quite smart with looking for components of LaTeX document. In
+ simple projects which can be put in one, two or three directories LaTeX-suite
+ can find bibliography, included or image files. But it is impossible to guess
+ all combinations, especially in projects dispersed in many directories, in
+ deep levels. For such situations you can create projects.
+
+ Creating project
+
+ To create project file make sure you don't have *.latexmain file
+ (|latex-master-file|). Open file which is the skelet of your whole work. Use
+ |:TProjectEdit| command. It will create file "yourmainfile.tex.latexmain" and
+ read in template of project file. This is just Vim file. Now you have two
+ commented variables: g:projName and g:projFiles. First isn't obligatory. It
+ will be visible in Explorer window to show you are editing project. This is
+ list of files separated with commas. File/dir name cannot contain
+ spaces. Example:
+ >
+ let g:projFiles="main.tex,roz1/roz1.tex,roz1/roz1.bib,main.bib,newfile.tex"
+
+ Editing project file
+
+ After |:TProjectEdit| screen will be split and you can make corrections,
+ comments or new files to project. To make changes available to Vim issue
+ command |:TProjectWrite|. This will save file and source it immediately.
}}}
|
|
From: <mi...@us...> - 2003-04-23 17:28:36
|
Update of /cvsroot/vim-latex/vimfiles/plugin
In directory sc8-pr-cvs1:/tmp/cvs-serv31422/plugin
Modified Files:
explorer.vim
Log Message:
Included project features
Index: explorer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/plugin/explorer.vim,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** explorer.vim 4 Apr 2003 23:27:45 -0000 1.1
--- explorer.vim 23 Apr 2003 17:28:32 -0000 1.2
***************
*** 96,99 ****
--- 96,110 ----
endif
+ " Project files
+ if !exists("g:projFiles")
+ let g:projFiles=''
+ endif
+
+ if !exists("g:projName")
+ let g:projName='[No Name]'
+ endif
+
+
+
" Field to sort by
if !exists("g:explSortBy")
***************
*** 305,308 ****
--- 316,328 ----
endif
+ " Set filter for project files
+ let b:projFormula = substitute(g:projFiles, '\([^\\]\),', '\1\\|', 'g')
+ let b:projFormula = substitute(b:projFormula, '^', '\\(', '')
+ let b:projFormula = substitute(b:projFormula, '$', '\\)', '')
+ if b:projFormula != '\(\)'
+ let b:proj="\n\" Project Name: " . g:projName
+ else
+ let b:proj=''
+ endif
" Show the files
call s:ShowDirectory()
***************
*** 650,655 ****
else
let fileLen=strlen(currLine)
! if (b:filterFormula!="") && (currLine =~ b:filterFormula)
! " Don't show the file if it is to be filtered.
d _
endif
--- 670,684 ----
else
let fileLen=strlen(currLine)
! if !exists("w:projView") || w:projView == 0
! let w:projView = 0
! else
! let b:projdir = Tex_GetMainFileName(":p:h")
! if (b:projFormula!='')&&(b:completePath.currLine!~b:projdir.'/'.b:projFormula)
! " Show only files in project
! d _
! endif
! endif
! if (b:filterFormula!="") && (currLine =~ b:filterFormula)
! "Don't show the file if it is to be filtered.
d _
endif
***************
*** 749,753 ****
let @f="\" Press ? for keyboard shortcuts\n"
endif
! let @f=@f."\" Sorted by ".w:sortdirlabel.w:sorttype.b:suffixeslast.b:filtering."\n"
let @f=@f."\"= ".b:completePath."\n"
put! f
--- 778,782 ----
let @f="\" Press ? for keyboard shortcuts\n"
endif
! let @f=@f."\" Sorted by ".w:sortdirlabel.w:sorttype.b:suffixeslast.b:filtering.b:proj."\n"
let @f=@f."\"= ".b:completePath."\n"
put! f
|
|
From: <mi...@us...> - 2003-04-23 17:28:36
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv31422/ftplugin/tex
Modified Files:
texviewer.vim
Log Message:
Included project features
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** texviewer.vim 11 Apr 2003 23:31:10 -0000 1.11
--- texviewer.vim 23 Apr 2003 17:28:32 -0000 1.12
***************
*** 77,80 ****
--- 77,81 ----
if bibfiles != ''
exe 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
+ let g:bbb = 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
endif
if bblfiles != ''
***************
*** 182,188 ****
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 " }}}
" Tex_explore_window: settings for completion of filenames {{{
" Description:
--- 183,198 ----
nnoremap <buffer> <silent> K :wincmd j<cr><c-y>:wincmd k<cr>
! exe 'nnoremap <buffer> <silent> q :call Tex_CloseSmallWindows()<cr>'
endfunction " }}}
+ " Tex_CloseSmallWindows: {{{
+ " Description:
+ "
+ function! Tex_CloseSmallWindows()
+ exe s:winnum.' wincmd w'
+ pclose!
+ cclose
+ exe s:pos
+ endfunction " }}}
" Tex_explore_window: settings for completion of filenames {{{
" Description:
***************
*** 360,393 ****
function! s:Tex_FindBibFiles()
! let bibfiles = ''
! let bibfiles2 = ''
! let curdir = expand("%:p:h")
! let curdir = substitute(curdir, ' ', "\\", 'ge')
- if search('\\bibliography{', 'w')
- let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
- let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
- let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
else
! let bibfiles = glob(curdir.'/*.bib')
! let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
! endif
- if Tex_GetMainFileName() != ''
- let mainfname = Tex_GetMainFileName()
- let mainfdir = fnamemodify(mainfname, ":p:h")
- exe 'bot 1 split '.mainfname
if search('\\bibliography{', 'w')
! let bibfiles2 = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles2 = substitute(bibfiles2, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles2 = substitute(bibfiles2, '\(^\| \)', ' '.curdir.'/', 'ge')
! elseif mainfdir != curdir
! let bibfiles2 = glob(mainfdir.'/*.bib')
! let bibfiles2 = substitute(bibfiles2, '\n', ' ', 'ge')
endif
- wincmd q
- endif
! return bibfiles.' '.bibfiles2
endfunction " }}}
--- 370,420 ----
function! s:Tex_FindBibFiles()
! if g:projFiles != ''
! let bibfiles = ''
! let i = 1
! while Tex_Strntok(g:projFiles, ',', i) != ''
! let curfile = Tex_Strntok(g:projFiles, ',', i)
! if curfile =~ '\.bib'
! let curfile = substitute(curfile, '.*', s:search_directory.'\0', '')
! let bibfiles = bibfiles.'"'.curfile.'" '
! endif
! let i = i + 1
! endwhile
!
! let g:bibf = bibfiles
! return bibfiles
else
! let bibfiles = ''
! let bibfiles2 = ''
! let curdir = expand("%:p:h")
! let curdir = substitute(curdir, ' ', "\\", 'ge')
if search('\\bibliography{', 'w')
! let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
! else
! let bibfiles = glob(curdir.'/*.bib')
! let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
endif
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
! exe 'bot 1 split '.mainfname
! if search('\\bibliography{', 'w')
! let bibfiles2 = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles2 = substitute(bibfiles2, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles2 = substitute(bibfiles2, '\(^\| \)', ' '.curdir.'/', 'ge')
! elseif mainfdir != curdir
! let bibfiles2 = glob(mainfdir.'/*.bib')
! let bibfiles2 = substitute(bibfiles2, '\n', ' ', 'ge')
! endif
! wincmd q
! endif
!
! return bibfiles.' '.bibfiles2
! endif
endfunction " }}}
***************
*** 397,419 ****
function! s:Tex_FindBblFiles()
! let bblfiles = ''
! let bblfiles2 = ''
! let curdir = expand("%:p:h")
! let bblfiles = glob(curdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
- if mainfdir != curdir
- let bblfiles = glob(mainfdir.'/*.tex')
- let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
endif
endif
-
- return bblfiles.' '.bblfiles2
endfunction " }}}
--- 424,462 ----
function! s:Tex_FindBblFiles()
! if g:projFiles != ''
! let bblfiles = ''
! let i = 1
! while Tex_Strntok(g:projFiles, ',', i) != ''
! let curfile = Tex_Strntok(g:projFiles, ',', i)
! if curfile =~ '\.tex'
! let curfile = substitute(curfile, '.*', s:search_directory.'\0', '')
! let bblfiles = bblfiles.'"'.curfile.'" '
! endif
! let i = i + 1
! endwhile
! return bblfiles
! else
! let bblfiles = ''
! let bblfiles2 = ''
! let curdir = expand("%:p:h")
!
! let bblfiles = glob(curdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
!
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
!
! if mainfdir != curdir
! let bblfiles = glob(mainfdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
! endif
endif
+ return bblfiles.' '.bblfiles2
endif
endfunction " }}}
|
|
From: <mi...@us...> - 2003-04-21 19:36:05
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv12913
Modified Files:
Tag: texproject-branch
latex-suite.txt
Log Message:
short help for project commands
Index: latex-suite.txt
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v
retrieving revision 1.19
retrieving revision 1.19.2.1
diff -C2 -d -r1.19 -r1.19.2.1
*** latex-suite.txt 13 Apr 2003 02:03:53 -0000 1.19
--- latex-suite.txt 21 Apr 2003 19:35:59 -0000 1.19.2.1
***************
*** 1,5 ****
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Sat Apr 12 06:00 PM 2003
By Srinath Avadhanula <sr...@fa...>,
--- 1,5 ----
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Sat Apr 16 06:00 PM 2003
By Srinath Avadhanula <sr...@fa...>,
***************
*** 554,557 ****
--- 554,586 ----
You can ofcourse place your own templates in this directory.
+
+ }}}
+ ===========================================================================
+ LATEX PROJECT *latex-project* {{{
+
+ LaTeX-suite is quite smart with looking for components of LaTeX document. In
+ simple projects which can be put in one, two or three directories LaTeX-suite
+ can find bibliography, included or image files. But it is impossible to guess
+ all combinations, especially in projects dispersed in many directories, in
+ deep levels. For such situations you can create projects.
+
+ Creating project
+
+ To create project file make sure you don't have *.latexmain file
+ (|latex-master-file|). Open file which is the skelet of your whole work. Use
+ |:TProjectEdit| command. It will create file "yourmainfile.tex.latexmain" and
+ read in template of project file. This is just Vim file. Now you have two
+ commented variables: g:projName and g:projFiles. First isn't obligatory. It
+ will be visible in Explorer window to show you are editing project. This is
+ list of files separated with commas. File/dir name cannot contain
+ spaces. Example:
+ >
+ let g:projFiles="main.tex,roz1/roz1.tex,roz1/roz1.bib,main.bib,newfile.tex"
+
+ Editing project file
+
+ After |:TProjectEdit| screen will be split and you can make corrections,
+ comments or new files to project. To make changes available to Vim issue
+ command |:TProjectWrite|. This will save file and source it immediately.
}}}
|
|
From: <mi...@us...> - 2003-04-18 19:33:05
|
Update of /cvsroot/vim-latex/vimfiles/plugin
In directory sc8-pr-cvs1:/tmp/cvs-serv24393
Modified Files:
Tag: texproject-branch
explorer.vim
Log Message:
Introduction of texproject:
1. explorer.vim
Changes responsible for showing only files belonging to project
2. texmenuconf.vim
Menu for project
3. main.vim
Sourcing of latex-suite/texproject.vim
4. texviewer.vim
Changes responsible for ref/cite completion from project (if exists)
5. texproject.vim
Functions and command for project actions
6. projecttemplate.vim
Template of project file.
Index: explorer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/plugin/explorer.vim,v
retrieving revision 1.1
retrieving revision 1.1.2.1
diff -C2 -d -r1.1 -r1.1.2.1
*** explorer.vim 4 Apr 2003 23:27:45 -0000 1.1
--- explorer.vim 18 Apr 2003 19:33:01 -0000 1.1.2.1
***************
*** 96,99 ****
--- 96,110 ----
endif
+ " Project files
+ if !exists("g:projFiles")
+ let g:projFiles=''
+ endif
+
+ if !exists("g:projName")
+ let g:projName='[No Name]'
+ endif
+
+
+
" Field to sort by
if !exists("g:explSortBy")
***************
*** 305,308 ****
--- 316,328 ----
endif
+ " Set filter for project files
+ let b:projFormula = substitute(g:projFiles, '\([^\\]\),', '\1\\|', 'g')
+ let b:projFormula = substitute(b:projFormula, '^', '\\(', '')
+ let b:projFormula = substitute(b:projFormula, '$', '\\)', '')
+ if b:projFormula != '\(\)'
+ let b:proj="\n\" Project Name: " . g:projName
+ else
+ let b:proj=''
+ endif
" Show the files
call s:ShowDirectory()
***************
*** 650,655 ****
else
let fileLen=strlen(currLine)
! if (b:filterFormula!="") && (currLine =~ b:filterFormula)
! " Don't show the file if it is to be filtered.
d _
endif
--- 670,684 ----
else
let fileLen=strlen(currLine)
! if !exists("w:projView") || w:projView == 0
! let w:projView = 0
! else
! let b:projdir = Tex_GetMainFileName(":p:h")
! if (b:projFormula!='')&&(b:completePath.currLine!~b:projdir.'/'.b:projFormula)
! " Show only files in project
! d _
! endif
! endif
! if (b:filterFormula!="") && (currLine =~ b:filterFormula)
! "Don't show the file if it is to be filtered.
d _
endif
***************
*** 749,753 ****
let @f="\" Press ? for keyboard shortcuts\n"
endif
! let @f=@f."\" Sorted by ".w:sortdirlabel.w:sorttype.b:suffixeslast.b:filtering."\n"
let @f=@f."\"= ".b:completePath."\n"
put! f
--- 778,782 ----
let @f="\" Press ? for keyboard shortcuts\n"
endif
! let @f=@f."\" Sorted by ".w:sortdirlabel.w:sorttype.b:suffixeslast.b:filtering.b:proj."\n"
let @f=@f."\"= ".b:completePath."\n"
put! f
|
|
From: <mi...@us...> - 2003-04-18 19:32:09
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv23878/tex
Modified Files:
Tag: texproject-branch
texviewer.vim
Log Message:
Introduction of texproject:
1. explorer.vim
Changes responsible for showing only files belonging to project
2. texmenuconf.vim
Menu for project
3. main.vim
Sourcing of latex-suite/texproject.vim
4. texviewer.vim
Changes responsible for ref/cite completion from project (if exists)
5. texproject.vim
Functions and command for project actions
6. projecttemplate.vim
Template of project file.
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.11
retrieving revision 1.11.2.1
diff -C2 -d -r1.11 -r1.11.2.1
*** texviewer.vim 11 Apr 2003 23:31:10 -0000 1.11
--- texviewer.vim 18 Apr 2003 19:32:05 -0000 1.11.2.1
***************
*** 77,80 ****
--- 77,81 ----
if bibfiles != ''
exe 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
+ let g:bbb = 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
endif
if bblfiles != ''
***************
*** 182,188 ****
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 " }}}
" Tex_explore_window: settings for completion of filenames {{{
" Description:
--- 183,198 ----
nnoremap <buffer> <silent> K :wincmd j<cr><c-y>:wincmd k<cr>
! exe 'nnoremap <buffer> <silent> q :call Tex_CloseSmallWindows()<cr>'
endfunction " }}}
+ " Tex_CloseSmallWindows: {{{
+ " Description:
+ "
+ function! Tex_CloseSmallWindows()
+ exe s:winnum.' wincmd w'
+ pclose!
+ cclose
+ exe s:pos
+ endfunction " }}}
" Tex_explore_window: settings for completion of filenames {{{
" Description:
***************
*** 360,393 ****
function! s:Tex_FindBibFiles()
! let bibfiles = ''
! let bibfiles2 = ''
! let curdir = expand("%:p:h")
! let curdir = substitute(curdir, ' ', "\\", 'ge')
- if search('\\bibliography{', 'w')
- let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
- let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
- let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
else
! let bibfiles = glob(curdir.'/*.bib')
! let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
! endif
- if Tex_GetMainFileName() != ''
- let mainfname = Tex_GetMainFileName()
- let mainfdir = fnamemodify(mainfname, ":p:h")
- exe 'bot 1 split '.mainfname
if search('\\bibliography{', 'w')
! let bibfiles2 = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles2 = substitute(bibfiles2, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles2 = substitute(bibfiles2, '\(^\| \)', ' '.curdir.'/', 'ge')
! elseif mainfdir != curdir
! let bibfiles2 = glob(mainfdir.'/*.bib')
! let bibfiles2 = substitute(bibfiles2, '\n', ' ', 'ge')
endif
- wincmd q
- endif
! return bibfiles.' '.bibfiles2
endfunction " }}}
--- 370,420 ----
function! s:Tex_FindBibFiles()
! if g:projFiles != ''
! let bibfiles = ''
! let i = 1
! while Tex_Strntok(g:projFiles, ',', i) != ''
! let curfile = Tex_Strntok(g:projFiles, ',', i)
! if curfile =~ '\.bib'
! let curfile = substitute(curfile, '.*', s:search_directory.'\0', '')
! let bibfiles = bibfiles.'"'.curfile.'" '
! endif
! let i = i + 1
! endwhile
!
! let g:bibf = bibfiles
! return bibfiles
else
! let bibfiles = ''
! let bibfiles2 = ''
! let curdir = expand("%:p:h")
! let curdir = substitute(curdir, ' ', "\\", 'ge')
if search('\\bibliography{', 'w')
! let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
! else
! let bibfiles = glob(curdir.'/*.bib')
! let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
endif
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
! exe 'bot 1 split '.mainfname
! if search('\\bibliography{', 'w')
! let bibfiles2 = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
! let bibfiles2 = substitute(bibfiles2, '\(,\|$\)', '.bib ', 'ge')
! let bibfiles2 = substitute(bibfiles2, '\(^\| \)', ' '.curdir.'/', 'ge')
! elseif mainfdir != curdir
! let bibfiles2 = glob(mainfdir.'/*.bib')
! let bibfiles2 = substitute(bibfiles2, '\n', ' ', 'ge')
! endif
! wincmd q
! endif
!
! return bibfiles.' '.bibfiles2
! endif
endfunction " }}}
***************
*** 397,419 ****
function! s:Tex_FindBblFiles()
! let bblfiles = ''
! let bblfiles2 = ''
! let curdir = expand("%:p:h")
! let bblfiles = glob(curdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
- if mainfdir != curdir
- let bblfiles = glob(mainfdir.'/*.tex')
- let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
endif
endif
-
- return bblfiles.' '.bblfiles2
endfunction " }}}
--- 424,462 ----
function! s:Tex_FindBblFiles()
! if g:projFiles != ''
! let bblfiles = ''
! let i = 1
! while Tex_Strntok(g:projFiles, ',', i) != ''
! let curfile = Tex_Strntok(g:projFiles, ',', i)
! if curfile =~ '\.tex'
! let curfile = substitute(curfile, '.*', s:search_directory.'\0', '')
! let bblfiles = bblfiles.'"'.curfile.'" '
! endif
! let i = i + 1
! endwhile
! return bblfiles
! else
! let bblfiles = ''
! let bblfiles2 = ''
! let curdir = expand("%:p:h")
!
! let bblfiles = glob(curdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
!
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! let mainfdir = fnamemodify(mainfname, ":p:h")
!
! if mainfdir != curdir
! let bblfiles = glob(mainfdir.'/*.tex')
! let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
! endif
endif
+ return bblfiles.' '.bblfiles2
endif
endfunction " }}}
|
|
From: <mi...@us...> - 2003-04-18 19:32:08
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv23878/latex-suite
Modified Files:
Tag: texproject-branch
main.vim texmenuconf.vim
Added Files:
Tag: texproject-branch
texproject.vim projecttemplate.vim
Log Message:
Introduction of texproject:
1. explorer.vim
Changes responsible for showing only files belonging to project
2. texmenuconf.vim
Menu for project
3. main.vim
Sourcing of latex-suite/texproject.vim
4. texviewer.vim
Changes responsible for ref/cite completion from project (if exists)
5. texproject.vim
Functions and command for project actions
6. projecttemplate.vim
Template of project file.
--- NEW FILE: texproject.vim ---
"=============================================================================
" File: texproject.vim
" Author: Mikolaj Machowski
" Version: 1.0
" Created: Wen Apr 16 05:00 PM 2003
"
" Description: Handling tex projects.
"
"=============================================================================
let s:path = expand("<sfile>:p:h")
command! -nargs=0 TProjectEdit :call <SID>Tex_ProjectEdit()
command! -nargs=0 TProjectWrite :call <SID>Tex_ProjectWrite()
command! -nargs=0 TProject :call <SID>Tex_Project()
" Tex_ProjectEdit: Edit project file " {{{
" Description: If project file exists (*.latexmain) open it in window created
" with ':split', if no create ':new' window and read there
" project template
"
function! s:Tex_ProjectEdit()
let file = expand("%:p")
if Tex_GetMainFileName() != ''
exe 'split '.Tex_GetMainFileName(":p")
else
exe 'split '.s:path.'/projecttemplate.vim'
exe 'saveas '.file.'.latexmain'
let g:Tex_ProjectExists = 1
endif
endfunction " }}}
" Tex_ProjectWrite: write project and source it to refresh changed vars {{{
" Description:
"
function! s:Tex_ProjectWrite()
if expand("%") =~ 'latexmain$'
write!
exe 'source '.Tex_GetMainFileName(":p")
q
else
echoerr "Sorry, this is not project file"
return
endif
endfunction " }}}
" Tex_Project: open project view in explorer {{{
" Description:
"
function! s:Tex_Project()
if g:Tex_ProjectExists == 1
new
let w:projView = 1
:Explore
else
echoerr "Sorry, no project file exists"
finish
endif
endfunction " }}}
" Load project file if exists
if Tex_GetMainFileName() != ''
exe 'source '.Tex_GetMainFileName(":p")
let g:Tex_ProjectExists = 1
else
let g:Tex_ProjectExists = 0
endif
" vim:fdm=marker:ff=unix:noet:ts=4:sw=4
--- NEW FILE: projecttemplate.vim ---
" Project name
" let g:projName = ''
"
" Project files
" let g:projFiles = ''
" Vim settings/maps/abbrs specific for this project
" Modeline for this file
" vim:fdm=marker:ff=unix:noet:ts=4:sw=4:ft=vim
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.36
retrieving revision 1.36.2.1
diff -C2 -d -r1.36 -r1.36.2.1
*** main.vim 11 Apr 2003 21:21:50 -0000 1.36
--- main.vim 18 Apr 2003 19:32:04 -0000 1.36.2.1
***************
*** 403,406 ****
--- 403,411 ----
exe 'cd '.expand('%:p:h')
let lheadfile = glob('*.latexmain')
+ " dirty hack to check in dir one level up. TODO: while with ":h" mod.
+ if lheadfile == ''
+ cd ..
+ let lheadfile = glob('*.latexmain')
+ endif
if lheadfile != ''
let lheadfile = fnamemodify(lheadfile, modifier)
***************
*** 526,529 ****
--- 531,535 ----
exe 'source '.s:path.'/bibtex.vim'
exe 'source '.s:path.'/diacritics.vim'
+ exe 'source '.s:path.'/texproject.vim'
" ==============================================================================
Index: texmenuconf.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texmenuconf.vim,v
retrieving revision 1.11
retrieving revision 1.11.2.1
diff -C2 -d -r1.11 -r1.11.2.1
*** texmenuconf.vim 14 Apr 2003 17:14:38 -0000 1.11
--- texmenuconf.vim 18 Apr 2003 19:32:04 -0000 1.11.2.1
***************
*** 54,57 ****
--- 54,64 ----
exec 'inoremenu 80.100 '.s:mainmenuname.'C&omplete\ Ref/Cite'.
\' <Esc>:call Tex_viewer("default","text")<CR>'
+ " project
+ exec 'anoremenu 80.105 '.s:mainmenuname.'Project.&Project<tab>:TProject'.
+ \' :TProject<CR>'
+ exec 'anoremenu 80.106 '.s:mainmenuname.'Project.Project&Edit<tab>:TProjectEdit'.
+ \' :TProjectEdit<CR>'
+ exec 'anoremenu 80.107 '.s:mainmenuname.'Project.Project&Write<tab>:TProjectWrite'.
+ \' :TProjectWrite<CR>'
exec 'anoremenu 80.110 '.s:mainmenuname.'-sepsuite1- :'
" refreshing folds
|
|
From: <mi...@us...> - 2003-04-15 10:26:28
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv31307
Modified Files:
compiler.vim
Log Message:
- use makefile always if exists, .latexmain only if makefile
doesn't exist.
Index: compiler.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/compiler.vim,v
retrieving revision 1.25
retrieving revision 1.26
diff -C2 -d -r1.25 -r1.26
*** compiler.vim 14 Apr 2003 17:14:46 -0000 1.25
--- compiler.vim 15 Apr 2003 10:26:23 -0000 1.26
***************
*** 115,119 ****
" if a makefile and no *.latexmain exists, just use the make utility
" this also sets mainfname for the rest of the function
! if (glob('makefile') != '' || glob('Makefile') != '') && mainfname == ''
let mainfname = expand("%:t:r")
let _makeprg = &l:makeprg
--- 115,119 ----
" if a makefile and no *.latexmain exists, just use the make utility
" this also sets mainfname for the rest of the function
! if (glob('makefile') != '' || glob('Makefile') != '')
let mainfname = expand("%:t:r")
let _makeprg = &l:makeprg
|
|
From: <mi...@us...> - 2003-04-14 17:14:59
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv28510
Modified Files:
wizardfuncs.vim
Log Message:
- proper handling of <Plug> thing, remove hard map to F10
- temporary file has .tex extension
Index: wizardfuncs.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/wizardfuncs.vim,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** wizardfuncs.vim 6 Apr 2003 22:59:37 -0000 1.11
--- wizardfuncs.vim 14 Apr 2003 17:14:55 -0000 1.12
***************
*** 236,246 ****
" ==============================================================================
"
! 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")
--- 236,245 ----
" ==============================================================================
"
! noremap <buffer> <silent> <Plug>Tex_PartCompilation :call Tex_PartCompilation("f","l","v")<CR>
if !hasmapto('<Plug>Tex_PartCompilation',"v")
! vmap <buffer> <silent> <F10> <Plug>Tex_PartCompilation
endif
command! -nargs=0 -range TPartComp silent! call Tex_PartCompilation(<line1>,<line2>, "c")
command! -nargs=0 TPartView silent! call ViewLaTeX("part")
***************
*** 258,266 ****
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
--- 257,266 ----
let tmpfile = tempname()
let g:tfile = tmpfile
+ let tmpfile = tmpfile.'.tex'
"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(":p:r")
if mainfile != ''
exe 'bot 1 split '.mainfile
***************
*** 271,275 ****
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
--- 271,275 ----
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
|
|
From: <mi...@us...> - 2003-04-14 17:14:52
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv28423
Modified Files:
compiler.vim
Log Message:
- proper handling various compilation situations - partial, makefile (Alan Schmitt)
- mappings of partial compilation
Index: compiler.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/compiler.vim,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** compiler.vim 7 Apr 2003 10:52:11 -0000 1.24
--- compiler.vim 14 Apr 2003 17:14:46 -0000 1.25
***************
*** 91,114 ****
pclose!
! " If a *.latexmain file is found, then use that file to
! " construct a main file.
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! else
! " otherwise just use this file.
! let mainfname = expand("%:t:r")
! endif
!
! " if a makefile exists, just use the make utility
! if glob('makefile') != '' || glob('Makefile') != ''
! let _makeprg = &l:makeprg
! let &l:makeprg = 'make $*'
! if exists('s:target')
! exec 'make '.s:target
! else
! exec 'make'
! endif
! 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
--- 91,106 ----
pclose!
! " Logic to choose how to compile:
! " if g:partcomp is set
! " do partial compilation
! " else if there is a makefile and no .latexmain
! " do make
! " else
! " call the latex compiler on
! " the current file if there is not .latexmain
! " .latexmain if there is one
! "
! " if partial compilation is wanted
! if 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
***************
*** 119,125 ****
exec 'make '.g:tfile
exe 'lcd '.curdir
! else
! exec 'make '.mainfname
! endif
let winnum = winnr()
--- 111,137 ----
exec 'make '.g:tfile
exe 'lcd '.curdir
! else
! let mainfname = Tex_GetMainFileName()
! " if a makefile and no *.latexmain exists, just use the make utility
! " this also sets mainfname for the rest of the function
! if (glob('makefile') != '' || glob('Makefile') != '') && mainfname == ''
! let mainfname = expand("%:t:r")
! let _makeprg = &l:makeprg
! let &l:makeprg = 'make $*'
! if exists('s:target')
! exec 'make '.s:target
! else
! exec 'make'
! endif
! let &l:makeprg = _makeprg
! else
! " otherwise, if a *.latexmain file is found, then use that file to
! " construct a main file.
! if mainfname == ''
! let mainfname = expand("%:t:r")
! endif
! exec 'make '.mainfname
! endif
! endif
let winnum = winnr()
***************
*** 456,459 ****
--- 468,472 ----
if has("gui")
nnoremap <buffer> <Leader>ll :silent! call RunLaTeX()<cr>
+ vnoremap <buffer> <Leader>lc :call Tex_PartCompilation("f","l","v")<cr>
nnoremap <buffer> <Leader>lv :silent! call ViewLaTeX("all")<cr>
nnoremap <buffer> <Leader>lp :silent! call ViewLaTeX("part")<cr>
***************
*** 461,464 ****
--- 474,478 ----
else
nnoremap <buffer> <Leader>ll :call RunLaTeX()<cr>
+ vnoremap <buffer> <Leader>lc :call Tex_PartCompilation("f","l","v")<cr>
nnoremap <buffer> <Leader>lv :call ViewLaTeX("all")<cr>
nnoremap <buffer> <Leader>lp :call ViewLaTeX("part")<cr>
|
|
From: <mi...@us...> - 2003-04-14 17:14:45
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv28394
Modified Files:
texmenuconf.vim
Log Message:
Partial compilation menu element didn't work. Change element to visual
only.
Index: texmenuconf.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texmenuconf.vim,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** texmenuconf.vim 14 Apr 2003 11:23:24 -0000 1.10
--- texmenuconf.vim 14 Apr 2003 17:14:38 -0000 1.11
***************
*** 36,41 ****
exec 'anoremenu 80.30 '.s:mainmenuname.'&Compile<tab>\\ll'.
\' :silent! call RunLaTeX()<CR>'
! exec 'anoremenu 80.35 '.s:mainmenuname.'Compile&Part<tab>\\lc'.
! \' :silent! call Tex_PartCompilation("fline","lline", "v")<CR>'
exec 'anoremenu 80.40 '.s:mainmenuname.'&View<tab>\\lv'.
\' :silent! call ViewLaTeX("all")<CR>'
--- 36,41 ----
exec 'anoremenu 80.30 '.s:mainmenuname.'&Compile<tab>\\ll'.
\' :silent! call RunLaTeX()<CR>'
! exec 'vnoremenu 80.35 '.s:mainmenuname.'Compile&Part<tab>\\lc'.
! \' :call Tex_PartCompilation("f","l","v")<CR>'
exec 'anoremenu 80.40 '.s:mainmenuname.'&View<tab>\\lv'.
\' :silent! call ViewLaTeX("all")<CR>'
|
|
From: <mi...@us...> - 2003-04-14 11:23:29
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv9602
Modified Files:
texmenuconf.vim
Log Message:
proper calling partial compilation from menu, forgotten commit :/
Index: texmenuconf.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texmenuconf.vim,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** texmenuconf.vim 4 Apr 2003 00:55:57 -0000 1.9
--- texmenuconf.vim 14 Apr 2003 11:23:24 -0000 1.10
***************
*** 37,41 ****
\' :silent! call RunLaTeX()<CR>'
exec 'anoremenu 80.35 '.s:mainmenuname.'Compile&Part<tab>\\lc'.
! \' :silent! call Tex_PartCompilation()<CR>'
exec 'anoremenu 80.40 '.s:mainmenuname.'&View<tab>\\lv'.
\' :silent! call ViewLaTeX("all")<CR>'
--- 37,41 ----
\' :silent! call RunLaTeX()<CR>'
exec 'anoremenu 80.35 '.s:mainmenuname.'Compile&Part<tab>\\lc'.
! \' :silent! call Tex_PartCompilation("fline","lline", "v")<CR>'
exec 'anoremenu 80.40 '.s:mainmenuname.'&View<tab>\\lv'.
\' :silent! call ViewLaTeX("all")<CR>'
|
|
From: <sri...@us...> - 2003-04-13 02:03:57
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv25983
Modified Files:
latex-suite.txt
Log Message:
improvements in the newly added "Latex Completion" section.
Index: latex-suite.txt
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -d -r1.18 -r1.19
*** latex-suite.txt 7 Apr 2003 20:53:27 -0000 1.18
--- latex-suite.txt 13 Apr 2003 02:03:53 -0000 1.19
***************
*** 1,5 ****
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Tue Dec 31 01:00 AM 2002 PST
By Srinath Avadhanula <sr...@fa...>,
--- 1,5 ----
*latex-suite* Tools for an enhanced LaTeX environment in Vim
For Vim version 6.0 and above.
! Last Change: Sat Apr 12 06:00 PM 2003
By Srinath Avadhanula <sr...@fa...>,
***************
*** 49,58 ****
< set sw=2 >
" TIP: if you write your \label's as \label{fig:something}, then if you
! " type in \ref{fig: and press <C-n> you will automatically cycle through
" all the figure labels. Very useful!
< 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
--- 49,58 ----
< set sw=2 >
" TIP: if you write your \label's as \label{fig:something}, then if you
! " type in \ref{fig: and press <C-n> you will automatically cycle through
" all the figure labels. Very useful!
< 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
***************
*** 65,69 ****
===========================================================================
TABLE OF CONTENTS *latex-suite-toc* {{{
!
Editing
=======
--- 65,69 ----
===========================================================================
TABLE OF CONTENTS *latex-suite-toc* {{{
!
Editing
=======
***************
*** 76,82 ****
|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|
--- 76,82 ----
|latex-completion|
! Easily insert references to labels, bibliographic entries. The same
! key also works to insert file names for things such as
! \includegraphics{}.
|latex-bracketing-macros|
***************
*** 96,100 ****
Compiling/Viewing/Searching
===========================
! |latex-compiling|
A customizable compiler which can be dynamically reconfigured to
change what kinds of warnings/errors to ignore.
--- 96,100 ----
Compiling/Viewing/Searching
===========================
! |latex-compiling|
A customizable compiler which can be dynamically reconfigured to
change what kinds of warnings/errors to ignore.
***************
*** 115,119 ****
Folding
=======
! |latex-folding|
Manual folding based on LaTeX syntax elements.
--- 115,119 ----
Folding
=======
! |latex-folding|
Manual folding based on LaTeX syntax elements.
***************
*** 126,135 ****
Miscelleneous Stuff
===================
! |latex-help|
LaTeX's tex-info file translated into a Vim help file.
!
! |latex-dictionary|
A dictionary of standard LaTeX terms.
!
|latex-tools|
This version of latex-suite also ships with an external tools:
--- 126,135 ----
Miscelleneous Stuff
===================
! |latex-help|
LaTeX's tex-info file translated into a Vim help file.
!
! |latex-dictionary|
A dictionary of standard LaTeX terms.
!
|latex-tools|
This version of latex-suite also ships with an external tools:
***************
*** 141,145 ****
Latex-Suite ships with a very comprehensive set of insert mode and visual mode
! mappings and menu items to typeset most of the LaTeX elements.
*placeholders* *placeholder*
--- 141,145 ----
Latex-Suite ships with a very comprehensive set of insert mode and visual mode
! mappings and menu items to typeset most of the LaTeX elements.
*placeholders* *placeholder*
***************
*** 204,210 ****
starting with an E. The following subsection describes this in detail. The
sequence of 3 letters generally tries to follow the following rules:
!
1. All environment mappings begin with 'E'
!
2. If the environment can be broken up into 2 distinct words, such as
flushright (flush + right), then the next 2 letters are the first
--- 204,210 ----
starting with an E. The following subsection describes this in detail. The
sequence of 3 letters generally tries to follow the following rules:
!
1. All environment mappings begin with 'E'
!
2. If the environment can be broken up into 2 distinct words, such as
flushright (flush + right), then the next 2 letters are the first
***************
*** 214,218 ****
flushright (_f_lush + _r_ight) ---> EFR
eqnarray (_e_qn + _a_rray) ---> EEA
!
< If on the other hand, the environment name cannot be broken up into 2
distinct words, then the next 2 letters are the first 2 letters of the name
--- 214,218 ----
flushright (_f_lush + _r_ight) ---> EFR
eqnarray (_e_qn + _a_rray) ---> EEA
!
< If on the other hand, the environment name cannot be broken up into 2
distinct words, then the next 2 letters are the first 2 letters of the name
***************
*** 220,224 ****
Example: >
equation (_eq_uation) ---> EEQ
!
< Of course, not every last one of the environments can follow this rule
because of ambiguities. In case of doubt, pull down the
--- 220,224 ----
Example: >
equation (_eq_uation) ---> EEQ
!
< Of course, not every last one of the environments can follow this rule
because of ambiguities. In case of doubt, pull down the
***************
*** 265,269 ****
}}}
---------------------------------------------------------------------------
! Section Mappings: {{{
Inserts LaTeX sections: >
--- 265,269 ----
}}}
---------------------------------------------------------------------------
! Section Mappings: {{{
Inserts LaTeX sections: >
***************
*** 295,299 ****
}}}
---------------------------------------------------------------------------
! AUC-TEX key bindings: {{{
These are simple 2 key expansions for some very commonly used LaTeX elements.
--- 295,299 ----
}}}
---------------------------------------------------------------------------
! AUC-TEX key bindings: {{{
These are simple 2 key expansions for some very commonly used LaTeX elements.
***************
*** 326,330 ****
`| expands to \Big|
`I expands to \int_{<++>}^{<++>}<++>"
! <
(again, notice the convenient place-holders)
--- 326,330 ----
`| expands to \Big|
`I expands to \int_{<++>}^{<++>}<++>"
! <
(again, notice the convenient place-holders)
***************
*** 350,355 ****
< where <l> is a letter ('a' to 'z' and 'A' to 'Z')
>
! +} expands to \"{a}
! +: expands to \^{o}
<
Latex-Suite also ships with a function SmartBS(), which offers another
--- 350,355 ----
< where <l> is a letter ('a' to 'z' and 'A' to 'Z')
>
! +} expands to \"{a}
! +: expands to \^{o}
<
Latex-Suite also ships with a function SmartBS(), which offers another
***************
*** 420,475 ****
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
! 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. 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
! 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.
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.
*latex-completion-explorer*
--- 420,504 ----
LATEX COMPLETION *latex-completion* {{{
! This module provides an easy way to insert references to labels and
! bibliographic entries. Suppose you want to refer to an equation which is
! labelled as "eqn:eq-1" using the \label{eqn:eq-1} command. Somewhere in the
! text, you write "\ref{" with the cursor after the {. Now if you press <F9>,
! Latex-suite will try to search through all the .tex files in the present
! directory for lines beginning with "\label{". It will provide you with a list
! of all such matches in two small windows.
! +========================================================+
! | I want to insert a reference to equation 1. Therefore |
! | I will write \ref{ |
! | |
! | |
! | |
! | |
! | |
! +--------------------------------------------------------+
! +file1.tex +
! +========================================================+
! |file1.tex|100| \label{eqn:eq-1} |
! |file1.tex|110| \label{eqn:eq-2} |
! |file2.tex|178| \label{tab:table1} |
! +--------------------------------------------------------+
! +[Error List] +
! +========================================================+
! |\begin{equation} |
! | e^{j*pi} + 1 = 0 \label{eqn:eq-1} |
! |\end{equation} |
! |And there was some text after this. I dont remember |
! +--------------------------------------------------------+
! +file1.tex [Preview] +
! +========================================================+
! The first window (shown as "[Error List]" above) is a |cwindow| containing a
! list of matches and you will be left in it. The window beneath it is a
! |preview-window| showing the context of the match. When you move up and down
! in the "[Error List]" window, the preview window will be scrolled to keep in
! sync with the label. Pressing the "J" and "K" keys in the "[Error List]"
! window scrolls the preview window enabling you to see more context if you
! desire. After positioning yourself on a label which you want to insert, press
! <CR>. This will automatically close all the new windows, take you back to the
! file being edited and insert the chosen label in place. Pressing "q" in the
! "[Error List]" window closes all windows without inserting anything.
! As can be seen above, the matches include everything which begins with \label.
! If you have the habit of prefixing all equation labels with "eqn:" or
! something similar, then you can restrict the matches to only equations by
! first typing "\ref{eqn:" and then pressing <F9>. This only brings up matches
! starting with "\label{eqn:" thus allowing you to skip table and figure labels.
! The same mechanism also works with citations by pressing <F9> after typing
! "\cite{". In the case of citations, Latex-suite automatically displays a list
! of bibliographic entries found in .bib files in the present directory.
! This mechanism in fact works with all commands with "ref" or "cite" in them.
! Thus you will get completion with \citen, \citenum or \pageref. If you want
! to create your own command which uses 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 as: "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.
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.
!
! The functionality in this module is also available via three command-line
! utilities: |TLook|, |TLookBib| and |TLookAll|.
!
! You can use the g:Tex_ViewerCwindowHeight and g:Tex_ViewerPreviewHeight
! options in texrc to configure the heights of the "[Error List]" and preview
! window.
*latex-completion-explorer*
***************
*** 506,510 ****
and creates menu items based on the files found there. When you select a
template from this menu, the file will be read in above the first line of the
! current file.
A template file can use |placeholders| for easy cursor movement. In addition,
--- 535,539 ----
and creates menu items based on the files found there. When you select a
template from this menu, the file will be read in above the first line of the
! current file.
A template file can use |placeholders| for easy cursor movement. In addition,
***************
*** 550,554 ****
{New} Creates a new (unnamed) buffer in the latex-suite/macros/
! directory.
Use the command :TexMacroNew in non-gui mode.
--- 579,583 ----
{New} Creates a new (unnamed) buffer in the latex-suite/macros/
! directory.
Use the command :TexMacroNew in non-gui mode.
***************
*** 556,560 ****
Use :TexMacroEdit in non-gui mode.
! {Delete} Deletes the corresponding macro.
Use the prefixed numbers for fast navigation of menus.
Use :TexMacroDelete in non-gui mode.
--- 585,589 ----
Use :TexMacroEdit in non-gui mode.
! {Delete} Deletes the corresponding macro.
Use the prefixed numbers for fast navigation of menus.
Use :TexMacroDelete in non-gui mode.
***************
*** 564,573 ****
}}}
===========================================================================
! LATEX COMPILING *latex-compiling* {{{
This functionality is available via the TeX-Suite menu.
Latex-suite ships with a set of tools to compile LaTeX files into various
! formats and view them.
If you are using commonly used LaTeX tools, then you should be all set as soon
--- 593,602 ----
}}}
===========================================================================
! LATEX COMPILING *latex-compiling* {{{
This functionality is available via the TeX-Suite menu.
Latex-suite ships with a set of tools to compile LaTeX files into various
! formats and view them.
If you are using commonly used LaTeX tools, then you should be all set as soon
***************
*** 588,591 ****
--- 617,621 ----
|latex-compiler-customization| : customizing the output of the
latex-compiler.
+ |latex-part-compiling| : compiling only a part of a file.
*latex-compiler-target*
***************
*** 609,613 ****
|:TTarget| command. You can also set the viewer and compiler to different
formats, by using the menu items or using the commands |:TCTarget| and
! |:TVTarget|.
NOTE: If you try choosing a format for which a rule is not defined, you
--- 639,643 ----
|:TTarget| command. You can also set the viewer and compiler to different
formats, by using the menu items or using the commands |:TCTarget| and
! |:TVTarget|.
NOTE: If you try choosing a format for which a rule is not defined, you
***************
*** 635,641 ****
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*
--- 665,671 ----
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-latex 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*
***************
*** 650,655 ****
chapter.tex is being \input'ed into ~/thesis/main.tex, then create a file
called >
! main.tex.latexmain
! <
in the ~/thesis directory. This will then run "latex main.tex"
NOTE: Here main.tex.latexmain is a different file from main.tex itself.
--- 680,685 ----
chapter.tex is being \input'ed into ~/thesis/main.tex, then create a file
called >
! main.tex.latexmain
! <
in the ~/thesis directory. This will then run "latex main.tex"
NOTE: Here main.tex.latexmain is a different file from main.tex itself.
***************
*** 661,665 ****
compiler plugin maintained by Artem Chuprina. The modifications allow this
version to be customizable. i.e the user can set a verbosity level for the
! compiler.
By default it is set up in a "non-verbose", "ignore-common-warnings" mode,
--- 691,695 ----
compiler plugin maintained by Artem Chuprina. The modifications allow this
version to be customizable. i.e the user can set a verbosity level for the
! compiler.
By default it is set up in a "non-verbose", "ignore-common-warnings" mode,
***************
*** 671,675 ****
of 3 for instance means that messages of type 1-3 will be ignored. By default,
the ignore level is set to 4. (You can change this by setting
! g:Tex_IgnoreLevel in your .vimrc).
1. LaTeX Warning: Underfull box ...
--- 701,705 ----
of 3 for instance means that messages of type 1-3 will be ignored. By default,
the ignore level is set to 4. (You can change this by setting
! g:Tex_IgnoreLevel in your .vimrc).
1. LaTeX Warning: Underfull box ...
***************
*** 677,685 ****
both these warnings (very common) are due to \hbox settings not being
satisfied nicely.
! 3. LaTeX Warning: Specifier 'h' changed to 't'.
This errors occurs when TeX is not able to correctly place a floating
object at a specified location, because of which it defaulted to the
top of the page.
! 4. LaTeX Warning: You have requested ...,
This warning occurs in slitex when using the xypic package.
5. Missing number error:
--- 707,715 ----
both these warnings (very common) are due to \hbox settings not being
satisfied nicely.
! 3. LaTeX Warning: Specifier 'h' changed to 't'.
This errors occurs when TeX is not able to correctly place a floating
object at a specified location, because of which it defaulted to the
top of the page.
! 4. LaTeX Warning: You have requested ...,
This warning occurs in slitex when using the xypic package.
5. Missing number error:
***************
*** 718,723 ****
<
*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
--- 748,753 ----
<
*latex-part-compiling*
! You can compile only fragment of document. This can be useful while working on
! one sophisticated equation or one chapter.
Mark fragment in Visual mode and press <F10> (or choose this option from
***************
*** 744,750 ****
*latex-searching*
! Yap for windows, some versions of xdvi for windows and xdvi for unices provide
! the ability to do "forward searching" on the .dvi file. This means that you
! can have the DVI viewer jump to a specified location.
Pressing \ls while viewing a LaTeX file will perform this function, i.e the
--- 774,780 ----
*latex-searching*
! Yap for windows, some versions of xdvi for windows and xdvi for unices provide
! the ability to do "forward searching" on the .dvi file. This means that you
! can have the DVI viewer jump to a specified location.
Pressing \ls while viewing a LaTeX file will perform this function, i.e the
***************
*** 812,825 ****
directory, then creates a sub-menu based on the specification found in that
file.
! Often preamble is too long and you can put whole stuff into your own package
! and place it somewhere. Most obvious place is directory of edited file. But
! LaTeX looks for this such packages in places pointed in $TEXINPUTS environment
! variable. You can copy this variable to your texrc file in g:Tex_TEXINPUTS
variable. Example: >
TexLet g:Tex_TEXINPUTS = '.:~/texmf//:'
! Short explanation. '.' means looking in current directory, '~/texmf//' in
! ~/texmf directory and its all subdirectories. Last ':' means looking in normal
! TeX directories. Alas, Vim cannot (yet :) look in all subdirectories. Thus it
! find only '~/texmf/mypack.sty' and '~/texmf/sty/mypack.sty' but not
'~texmf/tex/sty/mypack.sty'.
--- 842,855 ----
directory, then creates a sub-menu based on the specification found in that
file.
! Often preamble is too long and you can put whole stuff into your own package
! and place it somewhere. Most obvious place is directory of edited file. But
! LaTeX looks for this such packages in places pointed in $TEXINPUTS environment
! variable. You can copy this variable to your texrc file in g:Tex_TEXINPUTS
variable. Example: >
TexLet g:Tex_TEXINPUTS = '.:~/texmf//:'
! Short explanation. '.' means looking in current directory, '~/texmf//' in
! ~/texmf directory and its all subdirectories. Last ':' means looking in normal
! TeX directories. Alas, Vim cannot (yet :) look in all subdirectories. Thus it
! find only '~/texmf/mypack.sty' and '~/texmf/sty/mypack.sty' but not
'~texmf/tex/sty/mypack.sty'.
***************
*** 840,847 ****
|latex-suite-maintainer|.
! Example:
From the packages menu, choose the >
! Tex-Packages.Supported.SIunits
option. This will insert a line of form: >
\usepackage[<++>]<++>{SIunits}<++>
--- 870,877 ----
|latex-suite-maintainer|.
! Example:
From the packages menu, choose the >
! Tex-Packages.Supported.SIunits
option. This will insert a line of form: >
\usepackage[<++>]<++>{SIunits}<++>
***************
*** 851,855 ****
SIunits package.You can use this sub-menu to insert commands from the package,
add options to the package etc.
!
NOTE: Since the package file is a Vim script, you could define custom
functions there, add mappings etc.
--- 881,885 ----
SIunits package.You can use this sub-menu to insert commands from the package,
add options to the package etc.
!
NOTE: Since the package file is a Vim script, you could define custom
functions there, add mappings etc.
***************
*** 865,869 ****
\usepackage lines and if latexSuite supports the detected
packages, then sub-menus containing the package options and
! commands is created.
A |latex-package-dictionary| might also be created.
--- 895,899 ----
\usepackage lines and if latexSuite supports the detected
packages, then sub-menus containing the package options and
! commands is created.
A |latex-package-dictionary| might also be created.
***************
*** 903,907 ****
{env:command} Environment: creates simple environment template >
\begin{command}
! x
\end{command}<<>>
{eno:command} Environment with option: >
--- 933,937 ----
{env:command} Environment: creates simple environment template >
\begin{command}
! x
\end{command}<<>>
{eno:command} Environment with option: >
***************
*** 945,949 ****
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
--- 975,979 ----
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
***************
*** 960,964 ****
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.
It is also possible to load custom dictionaries automatically when packages
--- 990,994 ----
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.
It is also possible to load custom dictionaries automatically when packages
***************
*** 1075,1082 ****
Command accepts also latexSuite mappings (|latex-macros|)
without preceding S and in lowercase: >
! :TSection pa
< will result in \part{}. It is possible to use full names of
sections: >
! :TSection part
<
:TSectionAdvanced *TSectionAdvanced*
--- 1105,1112 ----
Command accepts also latexSuite mappings (|latex-macros|)
without preceding S and in lowercase: >
! :TSection pa
< will result in \part{}. It is possible to use full names of
sections: >
! :TSection part
<
:TSectionAdvanced *TSectionAdvanced*
***************
*** 1088,1112 ****
: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.
--- 1118,1142 ----
: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: <mi...@us...> - 2003-04-11 23:31:14
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv965
Modified Files:
texviewer.vim
Log Message:
bad use of matchstr() with s:type, use substitute() instead
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** texviewer.vim 11 Apr 2003 21:21:58 -0000 1.10
--- texviewer.vim 11 Apr 2003 23:31:10 -0000 1.11
***************
*** 65,69 ****
let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$')
let s:typeoption = matchstr(s:type, '\zs[.*]\ze')
! let s:type = matchstr(s:type, '.\{-}\ze')
if exists("s:type") && s:type =~ 'ref'
--- 65,69 ----
let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$')
let s:typeoption = matchstr(s:type, '\zs[.*]\ze')
! let s:type = substitute(s:type, '[.*', '', 'e')
if exists("s:type") && s:type =~ 'ref'
***************
*** 191,195 ****
exe g:Tex_ExplorerHeight.' wincmd _'
- let g:type = a:type
if a:type =~ 'includegraphics\|bibliography\|includefile'
--- 191,194 ----
|
|
From: <mi...@us...> - 2003-04-11 21:22:02
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv2443
Modified Files:
texviewer.vim
Log Message:
make explorer completion pluginable; small cleaning of the code
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** texviewer.vim 11 Apr 2003 16:41:50 -0000 1.9
--- texviewer.vim 11 Apr 2003 21:21:58 -0000 1.10
***************
*** 40,44 ****
endif
! " CompletionVars: similar variables can be set in package files
let g:Tex_completion_bibliographystyle = 'abbr,alpha,plain,unsrt'
let g:Tex_completion_addtocontents = 'lof}{,lot}{,toc}{'
--- 40,44 ----
endif
! " CompletionVars: similar variables can be set in package files {{{
let g:Tex_completion_bibliographystyle = 'abbr,alpha,plain,unsrt'
let g:Tex_completion_addtocontents = 'lof}{,lot}{,toc}{'
***************
*** 46,49 ****
--- 46,50 ----
\ 'toc}{section}{,toc}{subsection}{,toc}{paragraph}{,'.
\ 'toc}{subparagraph}{'
+ " }}}
" Tex_viewer: main function {{{
***************
*** 59,66 ****
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{.\{-}$')
! let g:type1 = s:type
if exists("s:type") && s:type =~ 'ref'
--- 60,69 ----
if a:where == "text"
" What to do after <F9> depending on context
+ let s:curfile = expand("%:p")
let s:curline = strpart(getline('.'), col('.') - 40, 40)
let s:prefix = matchstr(s:curline, '{\zs.\{-}$')
let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$')
! let s:typeoption = matchstr(s:type, '\zs[.*]\ze')
! let s:type = matchstr(s:type, '.\{-}\ze')
if exists("s:type") && s:type =~ 'ref'
***************
*** 72,77 ****
let bibfiles = <SID>Tex_FindBibFiles()
let bblfiles = <SID>Tex_FindBblFiles()
- let g:bib = bibfiles
- let g:bbl = bblfiles
if bibfiles != ''
exe 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
--- 75,78 ----
***************
*** 85,89 ****
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")
--- 86,89 ----
***************
*** 92,96 ****
let s:storehidefiles = g:explHideFiles
let g:explHideFiles = '^\.,\.[^b]..$'
- let s:curfile = expand("%:p")
exe 'silent! Sexplore '.s:search_directory
call <SID>Tex_explore_window("bibliography")
--- 92,95 ----
***************
*** 99,115 ****
let s:storehidefiles = g:explHideFiles
let g:explHideFiles = '^\.,\.[^t]..$'
- let s:curfile = expand("%:p")
exe 'silent! Sexplore '.s:search_directory
call <SID>Tex_explore_window("includefile")
elseif exists("s:type") && s:type == 'input'
- let s:curfile = expand("%:p")
exe 'silent! Sexplore '.s:search_directory
call <SID>Tex_explore_window("input")
elseif exists("g:Tex_completion_{s:type}")
- let g:type = s:type
call <SID>CompleteName('plugin_'.s:type)
else
let s:word = matchstr(s:curline, '\zs\k\{-}$')
--- 98,115 ----
let s:storehidefiles = g:explHideFiles
let g:explHideFiles = '^\.,\.[^t]..$'
exe 'silent! Sexplore '.s:search_directory
call <SID>Tex_explore_window("includefile")
elseif exists("s:type") && s:type == 'input'
exe 'silent! Sexplore '.s:search_directory
call <SID>Tex_explore_window("input")
elseif exists("g:Tex_completion_{s:type}")
call <SID>CompleteName('plugin_'.s:type)
+ elseif exists("s:type") && g:Tex_completion_explorer =~ ','.s:type
+ exe 'silent! Sexplore '.s:search_directory
+ call <SID>Tex_explore_window("plugintype")
+
else
let s:word = matchstr(s:curline, '\zs\k\{-}$')
***************
*** 140,144 ****
call <SID>Tex_c_window_setup()
! elseif a:where == "all"
" Process :TLookAll command
exe 'silent! grep! "'.a:what.'" '.s:search_directory.'*'
--- 140,144 ----
call <SID>Tex_c_window_setup()
! elseif a:where == 'all'
" Process :TLookAll command
exe 'silent! grep! "'.a:what.'" '.s:search_directory.'*'
***************
*** 191,202 ****
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>
! elseif a:type == 'includefile'
! nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("includefile")<CR>
! elseif a:type == 'input'
! nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("input")<CR>
endif
--- 191,200 ----
exe g:Tex_ExplorerHeight.' wincmd _'
! let g:type = a:type
!
! if a:type =~ 'includegraphics\|bibliography\|includefile'
! nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("expl_noext")<CR>
! elseif a:type =~ 'input\|plugintype'
! nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("expl_ext")<CR>
endif
***************
*** 287,291 ****
let completeword = strpart(label, strlen(s:prefix))
! elseif a:type =~ 'includegraphics\|\<bibliography\>\|includefile\|\<input\>'
let line = substitute(strpart(getline('.'),0,b:maxFileLen),'\s\+$','','')
if isdirectory(b:completePath.line)
--- 285,289 ----
let completeword = strpart(label, strlen(s:prefix))
! elseif a:type =~ 'expl_ext\|expl_noext'
let line = substitute(strpart(getline('.'),0,b:maxFileLen),'\s\+$','','')
if isdirectory(b:completePath.line)
***************
*** 296,300 ****
else
! if a:type != 'input'
let ifile = substitute(line, '\..\{-}$', '', '')
else
--- 294,298 ----
else
! if a:type == 'expl_noext'
let ifile = substitute(line, '\..\{-}$', '', '')
else
***************
*** 303,307 ****
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)
--- 301,305 ----
let filename = b:completePath.ifile
! if g:Tex_ImageDir != '' && s:type =~ 'includegraphics'
let imagedir = s:curfile . g:Tex_ImageDir
let completeword = <SID>Tex_RelPath(filename, imagedir)
***************
*** 315,320 ****
elseif a:type =~ '^plugin_'
let type = substitute(a:type, '^plugin_', '', '')
! let completeword = Tex_DoCompletion(type)
! let g:comp = completeword
endif
--- 313,317 ----
elseif a:type =~ '^plugin_'
let type = substitute(a:type, '^plugin_', '', '')
! let completeword = <SID>Tex_DoCompletion(type)
endif
***************
*** 325,329 ****
pclose!
cclose
! elseif s:type =~ '\<bibliography\>\|include\|input'
wincmd q
endif
--- 322,326 ----
pclose!
cclose
! elseif a:type =~ 'expl_ext\|expl_noext'
wincmd q
endif
***************
*** 333,338 ****
" Complete word, check if add closing }
exe 'normal! a'.completeword."\<Esc>"
- let g:cword = completeword
- let g:cwlast = getline('.')[col('.')-1]
if getline('.')[col('.')-1] !~ '{' && getline('.')[col('.')] !~ '}'
--- 330,333 ----
***************
*** 369,372 ****
--- 364,368 ----
let bibfiles2 = ''
let curdir = expand("%:p:h")
+ let curdir = substitute(curdir, ' ', "\\", 'ge')
if search('\\bibliography{', 'w')
***************
*** 426,430 ****
" PromptForCompletion: prompts for a completion {{{
" Description:
! function! PromptForCompletion(texcommand,ask)
let common_completion_prompt =
--- 422,426 ----
" PromptForCompletion: prompts for a completion {{{
" Description:
! function! s:PromptForCompletion(texcommand,ask)
let common_completion_prompt =
***************
*** 444,448 ****
" Description:
"
! function! Tex_DoCompletion(texcommand)
let completion = PromptForCompletion(a:texcommand,'Choose a completion to insert: ')
if completion != ''
--- 440,444 ----
" Description:
"
! function! s:Tex_DoCompletion(texcommand)
let completion = PromptForCompletion(a:texcommand,'Choose a completion to insert: ')
if completion != ''
|
|
From: <mi...@us...> - 2003-04-11 21:21:53
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv2343 Modified Files: main.vim Log Message: add variable g:Tex_completion_explorer, necessary to whole thing work Index: main.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v retrieving revision 1.35 retrieving revision 1.36 diff -C2 -d -r1.35 -r1.36 *** main.vim 17 Jan 2003 09:13:31 -0000 1.35 --- main.vim 11 Apr 2003 21:21:50 -0000 1.36 *************** *** 565,569 **** --- 565,574 ---- " }}} + " This variable has to be set before sourcing package files to add names of + " commands to completion + let g:Tex_completion_explorer = ',' + " Mappings defined in package files will overwrite all other + exe 'source '.s:path.'/packages.vim' |
|
From: <mi...@us...> - 2003-04-11 21:21:44
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages
In directory sc8-pr-cvs1:/tmp/cvs-serv2299
Modified Files:
moreverb
Log Message:
first example of pluginable explorer completion - verbatimtabinput command
Index: moreverb
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages/moreverb,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** moreverb 5 Jan 2003 21:47:08 -0000 1.1
--- moreverb 11 Apr 2003 21:21:39 -0000 1.2
***************
*** 12,15 ****
--- 12,17 ----
\.'brs:verbatimtabinput[<++>]{<++>}'
+ let g:Tex_completion_explorer = g:Tex_completion_explorer.'verbatimtabinput,'
+
syn region texZone start="\\begin{verbatimwrite}" end="\\end{verbatimwrite}\|%stopzone\>" fold
syn region texZone start="\\begin{verbatimtab}" end="\\end{verbatimtab}\|%stopzone\>" fold
|
|
From: <mi...@us...> - 2003-04-11 16:41:54
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv3456
Modified Files:
texviewer.vim
Log Message:
completion is now pluginable through PromptFor mechanism, added completion for addcontentsline, addtocontents, bibliographystyle
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** texviewer.vim 11 Apr 2003 11:27:25 -0000 1.8
--- texviewer.vim 11 Apr 2003 16:41:50 -0000 1.9
***************
*** 40,43 ****
--- 40,50 ----
endif
+ " CompletionVars: similar variables can be set in package files
+ let g:Tex_completion_bibliographystyle = 'abbr,alpha,plain,unsrt'
+ let g:Tex_completion_addtocontents = 'lof}{,lot}{,toc}{'
+ let g:Tex_completion_addcontentsline = 'lof}{figure}{,lot}{table}{,toc}{chapter}{,toc}{part}{,'.
+ \ 'toc}{section}{,toc}{subsection}{,toc}{paragraph}{,'.
+ \ 'toc}{subparagraph}{'
+
" Tex_viewer: main function {{{
" Description:
***************
*** 55,58 ****
--- 62,66 ----
let s:prefix = matchstr(s:curline, '{\zs.\{-}$')
let s:type = matchstr(s:curline, '\\\zs.\{-}\ze{.\{-}$')
+ let g:type1 = s:type
if exists("s:type") && s:type =~ 'ref'
***************
*** 81,87 ****
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
--- 89,95 ----
call <SID>Tex_explore_window("includegraphics")
! elseif exists("s:type") && s:type == 'bibliography'
let s:storehidefiles = g:explHideFiles
! let g:explHideFiles = '^\.,\.[^b]..$'
let s:curfile = expand("%:p")
exe 'silent! Sexplore '.s:search_directory
***************
*** 100,103 ****
--- 108,115 ----
call <SID>Tex_explore_window("input")
+ elseif exists("g:Tex_completion_{s:type}")
+ let g:type = s:type
+ call <SID>CompleteName('plugin_'.s:type)
+
else
let s:word = matchstr(s:curline, '\zs\k\{-}$')
***************
*** 275,279 ****
let completeword = strpart(label, strlen(s:prefix))
! elseif a:type =~ 'includegraphics\|bibliography\|includefile\|input'
let line = substitute(strpart(getline('.'),0,b:maxFileLen),'\s\+$','','')
if isdirectory(b:completePath.line)
--- 287,291 ----
let completeword = strpart(label, strlen(s:prefix))
! elseif a:type =~ 'includegraphics\|\<bibliography\>\|includefile\|\<input\>'
let line = substitute(strpart(getline('.'),0,b:maxFileLen),'\s\+$','','')
if isdirectory(b:completePath.line)
***************
*** 300,303 ****
--- 312,320 ----
let g:explHideFiles = s:storehidefiles
endif
+
+ elseif a:type =~ '^plugin_'
+ let type = substitute(a:type, '^plugin_', '', '')
+ let completeword = Tex_DoCompletion(type)
+ let g:comp = completeword
endif
***************
*** 308,321 ****
pclose!
cclose
! exe s:pos
! elseif s:type =~ 'bibliography\|include\|input'
wincmd q
- exe s:pos
endif
" Complete word, check if add closing }
exe 'normal! a'.completeword."\<Esc>"
! if getline('.')[col('.')] != '}'
exe "normal! a}\<Esc>"
endif
--- 325,340 ----
pclose!
cclose
! elseif s:type =~ '\<bibliography\>\|include\|input'
wincmd q
endif
+ exe s:pos
+
" Complete word, check if add closing }
exe 'normal! a'.completeword."\<Esc>"
+ let g:cword = completeword
+ let g:cwlast = getline('.')[col('.')-1]
! if getline('.')[col('.')-1] !~ '{' && getline('.')[col('.')] !~ '}'
exe "normal! a}\<Esc>"
endif
***************
*** 405,408 ****
--- 424,455 ----
endfunction " }}}
+ " PromptForCompletion: prompts for a completion {{{
+ " Description:
+ function! PromptForCompletion(texcommand,ask)
+
+ let common_completion_prompt =
+ \ Tex_CreatePrompt(g:Tex_completion_{a:texcommand}, 2, ',') . "\n" .
+ \ 'Enter number or completion : '
+
+ let inp = input(a:ask."\n".common_completion_prompt)
+ if inp =~ '^[0-9]\+$'
+ let completion = Tex_Strntok(g:Tex_completion_{a:texcommand}, ',', inp)
+ else
+ let completion = inp
+ endif
+
+ return completion
+ endfunction " }}}
+ " Tex_DoCompletion: fast insertion of completion {{{
+ " Description:
+ "
+ function! Tex_DoCompletion(texcommand)
+ let completion = PromptForCompletion(a:texcommand,'Choose a completion to insert: ')
+ if completion != ''
+ return completion
+ else
+ return ''
+ endif
+ endfunction " }}}
" Tex_Common: common part of strings {{{
|
|
From: <mi...@us...> - 2003-04-11 11:27:29
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv21062a
Modified Files:
texviewer.vim
Log Message:
add completion for include, includeonly, input; remove unnecessary g:variables; localization of Tex_Find functions
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** texviewer.vim 10 Apr 2003 22:03:31 -0000 1.7
--- texviewer.vim 11 Apr 2003 11:27:25 -0000 1.8
***************
*** 62,67 ****
elseif exists("s:type") && s:type =~ 'cite'
silent! grep! nothing %
! let bibfiles = Tex_FindBibFiles()
! let bblfiles = Tex_FindBblFiles()
let g:bib = bibfiles
let g:bbl = bblfiles
--- 62,67 ----
elseif exists("s:type") && s:type =~ 'cite'
silent! grep! nothing %
! let bibfiles = <SID>Tex_FindBibFiles()
! let bblfiles = <SID>Tex_FindBblFiles()
let g:bib = bibfiles
let g:bbl = bblfiles
***************
*** 88,91 ****
--- 88,103 ----
call <SID>Tex_explore_window("bibliography")
+ elseif exists("s:type") && s:type =~ 'include\(only\)\='
+ let s:storehidefiles = g:explHideFiles
+ let g:explHideFiles = '^\.,\.[^t]..$'
+ let s:curfile = expand("%:p")
+ exe 'silent! Sexplore '.s:search_directory
+ call <SID>Tex_explore_window("includefile")
+
+ elseif exists("s:type") && s:type == 'input'
+ let s:curfile = expand("%:p")
+ exe 'silent! Sexplore '.s:search_directory
+ call <SID>Tex_explore_window("input")
+
else
let s:word = matchstr(s:curline, '\zs\k\{-}$')
***************
*** 171,176 ****
--- 183,194 ----
elseif a:type == 'bibliography'
nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("bibliography")<CR>
+ elseif a:type == 'includefile'
+ nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("includefile")<CR>
+ elseif a:type == 'input'
+ nnoremap <silent> <buffer> <cr> :silent! call <SID>CompleteName("input")<CR>
endif
+ nnoremap <silent> <buffer> q :wincmd q<cr>
+
endfunction " }}}
" UpdateViewerWindow: update error and preview window {{{
***************
*** 257,270 ****
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
--- 275,292 ----
let completeword = strpart(label, strlen(s:prefix))
! elseif a:type =~ 'includegraphics\|bibliography\|includefile\|input'
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>'
! nnoremap <silent> <buffer> q :wincmd q<cr>
return
else
! if a:type != 'input'
! let ifile = substitute(line, '\..\{-}$', '', '')
! else
! let ifile = line
! endif
let filename = b:completePath.ifile
***************
*** 287,291 ****
cclose
exe s:pos
! elseif s:type =~ 'includegraphics\|bibliography'
wincmd q
exe s:pos
--- 309,313 ----
cclose
exe s:pos
! elseif s:type =~ 'bibliography\|include\|input'
wincmd q
exe s:pos
***************
*** 323,327 ****
" Description: scan files looking for \bibliography entries
"
! function! Tex_FindBibFiles()
let bibfiles = ''
--- 345,349 ----
" Description: scan files looking for \bibliography entries
"
! function! s:Tex_FindBibFiles()
let bibfiles = ''
***************
*** 331,344 ****
if search('\\bibliography{', 'w')
let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
- let g:b1 = bibfiles
let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
- let g:b2 = bibfiles
let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
- let g:b3 = bibfiles
else
let bibfiles = glob(curdir.'/*.bib')
- let g:b4 = bibfiles
let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
- let g:b5 = bibfiles
endif
--- 353,361 ----
***************
*** 358,362 ****
endif
! return bibfiles.bibfiles2
endfunction " }}}
--- 375,379 ----
endif
! return bibfiles.' '.bibfiles2
endfunction " }}}
***************
*** 364,368 ****
" Description: scan files looking for \bibitem entries
"
! function! Tex_FindBblFiles()
let bblfiles = ''
--- 381,385 ----
" Description: scan files looking for \bibitem entries
"
! function! s:Tex_FindBblFiles()
let bblfiles = ''
***************
*** 384,388 ****
endif
! return bblfiles.bblfiles2
endfunction " }}}
--- 401,405 ----
endif
! return bblfiles.' '.bblfiles2
endfunction " }}}
|
|
From: <mi...@us...> - 2003-04-11 11:27:22
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages
In directory sc8-pr-cvs1:/tmp/cvs-serv20988
Modified Files:
polski
Log Message:
SmartQuotes for polski (Jakub Turski)
Index: polski
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages/polski,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** polski 5 Jan 2003 21:47:08 -0000 1.10
--- polski 11 Apr 2003 11:27:16 -0000 1.11
***************
*** 54,57 ****
--- 54,61 ----
" --------8<-------------
+ " Polskie znaki cudzyslowow
+ TexLet g:Tex_SmartQuoteOpen = ",,"
+ TexLet g:Tex_SmartQuoteClose = "''"
+
" Zmodyfikowana i rozwinieta funkcja Andrzeja Ostruszki
" Z dodatkiem od Benjiego Fishera (sprawdzanie sk³adni)
***************
*** 87,91 ****
function! s:Tex_polish_space()
"Nic magicznego w matematyce
! if synIDattr(synID(line('.'),col('.')-1,0),"name") =~ '^texMath\|^texZone'
return ' '
else
--- 91,95 ----
function! s:Tex_polish_space()
"Nic magicznego w matematyce
! if synIDattr(synID(line('.'),col('.')-1,0),"name") =~ '^texMath\|^texZone\^texRefZone'
return ' '
else
|
|
From: <mi...@us...> - 2003-04-10 22:03:37
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv30590
Modified Files:
texviewer.vim
Log Message:
more robust bib finder - not only scans current directory for .bib files but uses \bibliography commands in current and, if exists main file
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** texviewer.vim 5 Apr 2003 21:35:50 -0000 1.6
--- texviewer.vim 10 Apr 2003 22:03:31 -0000 1.7
***************
*** 61,72 ****
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()
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
--- 61,80 ----
elseif exists("s:type") && s:type =~ 'cite'
! silent! grep! nothing %
! let bibfiles = Tex_FindBibFiles()
! let bblfiles = Tex_FindBblFiles()
! let g:bib = bibfiles
! let g:bbl = bblfiles
! if bibfiles != ''
! exe 'silent! grepadd! "@.*{'.s:prefix.'" '.bibfiles
! endif
! if bblfiles != ''
! exe 'silent! grepadd! "bibitem{'.s:prefix.'" '.bblfiles
! endif
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
***************
*** 312,315 ****
--- 320,391 ----
endfunction " }}}
+ " Tex_FindBibFiles: find *.bib files {{{
+ " Description: scan files looking for \bibliography entries
+ "
+ function! Tex_FindBibFiles()
+
+ let bibfiles = ''
+ let bibfiles2 = ''
+ let curdir = expand("%:p:h")
+
+ if search('\\bibliography{', 'w')
+ let bibfiles = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
+ let g:b1 = bibfiles
+ let bibfiles = substitute(bibfiles, '\(,\|$\)', '.bib ', 'ge')
+ let g:b2 = bibfiles
+ let bibfiles = substitute(bibfiles, '\(^\| \)', ' '.curdir.'/', 'ge')
+ let g:b3 = bibfiles
+ else
+ let bibfiles = glob(curdir.'/*.bib')
+ let g:b4 = bibfiles
+ let bibfiles = substitute(bibfiles, '\n', ' ', 'ge')
+ let g:b5 = bibfiles
+ endif
+
+ if Tex_GetMainFileName() != ''
+ let mainfname = Tex_GetMainFileName()
+ let mainfdir = fnamemodify(mainfname, ":p:h")
+ exe 'bot 1 split '.mainfname
+ if search('\\bibliography{', 'w')
+ let bibfiles2 = matchstr(getline('.'), '\\bibliography{\zs.\{-}\ze}')
+ let bibfiles2 = substitute(bibfiles2, '\(,\|$\)', '.bib ', 'ge')
+ let bibfiles2 = substitute(bibfiles2, '\(^\| \)', ' '.curdir.'/', 'ge')
+ elseif mainfdir != curdir
+ let bibfiles2 = glob(mainfdir.'/*.bib')
+ let bibfiles2 = substitute(bibfiles2, '\n', ' ', 'ge')
+ endif
+ wincmd q
+ endif
+
+ return bibfiles.bibfiles2
+
+ endfunction " }}}
+ " Tex_FindBblFiles: find bibitem entries in tex files {{{
+ " Description: scan files looking for \bibitem entries
+ "
+ function! Tex_FindBblFiles()
+
+ let bblfiles = ''
+ let bblfiles2 = ''
+ let curdir = expand("%:p:h")
+
+ let bblfiles = glob(curdir.'/*.tex')
+ let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
+
+ if Tex_GetMainFileName() != ''
+ let mainfname = Tex_GetMainFileName()
+ let mainfdir = fnamemodify(mainfname, ":p:h")
+
+ if mainfdir != curdir
+ let bblfiles = glob(mainfdir.'/*.tex')
+ let bblfiles = substitute(bblfiles, '\n', ' ', 'ge')
+ endif
+
+ endif
+
+ return bblfiles.bblfiles2
+
+ endfunction " }}}
+
" Tex_Common: common part of strings {{{
|
|
From: <mi...@us...> - 2003-04-08 08:45:07
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv19697 Modified Files: packages.vim Log Message: replaced endwhile and endif. I dont know how it passed :( Index: packages.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** packages.vim 7 Apr 2003 20:53:03 -0000 1.31 --- packages.vim 8 Apr 2003 08:45:01 -0000 1.32 *************** *** 416,422 **** let id = id + 1 ! endif - endwhile let fn = fn + 1 --- 416,423 ---- let id = id + 1 ! endwhile ! ! endif let fn = fn + 1 |
|
From: <mi...@us...> - 2003-04-07 20:54:03
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv7282
Modified Files:
latex-suite.txt
Log Message:
info about improved scanning features
Index: latex-suite.txt
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** latex-suite.txt 4 Apr 2003 23:24:39 -0000 1.17
--- latex-suite.txt 7 Apr 2003 20:53:27 -0000 1.18
***************
*** 804,807 ****
--- 804,808 ----
This functionality is avaiable via the Tex-Packages menu.
+ *latex-package-scanning*
This module provides ways of customizing the menus based on which packages
are being used in the current LaTeX file. When latex-suite first starts up, it
***************
*** 811,814 ****
--- 812,826 ----
directory, then creates a sub-menu based on the specification found in that
file.
+ Often preamble is too long and you can put whole stuff into your own package
+ and place it somewhere. Most obvious place is directory of edited file. But
+ LaTeX looks for this such packages in places pointed in $TEXINPUTS environment
+ variable. You can copy this variable to your texrc file in g:Tex_TEXINPUTS
+ variable. Example: >
+ TexLet g:Tex_TEXINPUTS = '.:~/texmf//:'
+ Short explanation. '.' means looking in current directory, '~/texmf//' in
+ ~/texmf directory and its all subdirectories. Last ':' means looking in normal
+ TeX directories. Alas, Vim cannot (yet :) look in all subdirectories. Thus it
+ find only '~/texmf/mypack.sty' and '~/texmf/sty/mypack.sty' but not
+ '~texmf/tex/sty/mypack.sty'.
*latex-package-dictionary*
|
|
From: <mi...@us...> - 2003-04-07 20:53:42
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv7359
Modified Files:
texrc
Log Message:
new variable g:Tex_TEXINPUTS
Index: texrc
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texrc,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** texrc 4 Apr 2003 23:25:11 -0000 1.24
--- texrc 7 Apr 2003 20:53:31 -0000 1.25
***************
*** 383,390 ****
--- 383,392 ----
" treated as single characters for backspacing.
" Setting this to zero will leave the <BS> key unmapped.
+ " Default: 1
TexLet g:Tex_SmartKeyBS = 1
" Pressing " (english double quote) will insert `` or '' by making an
" intelligent guess about whether we intended to open or close a quote.
+ " Default: 1
TexLet g:Tex_SmartKeyQuote = 1
***************
*** 399,402 ****
--- 401,405 ----
" broken across lines.
" NOTE: Setting this to 1 has the side-effect of making the 'tw' setting be 0.
+ " Default:
TexLet g:Tex_SmartKeySpace = 0
***************
*** 408,412 ****
" to $1,\ldots,n$. The amsmath package actually provides a command \dots
" which does this. Maybe use that if amsmath is detected?
! "
TexLet g:Tex_SmartKeyDot = 1
--- 411,415 ----
" to $1,\ldots,n$. The amsmath package actually provides a command \dots
" which does this. Maybe use that if amsmath is detected?
! " Default: 1
TexLet g:Tex_SmartKeyDot = 1
***************
*** 416,429 ****
--- 419,437 ----
" Options for preview window for ref/cite completion.
" Height of cwindow
+ " Default: 5
TexLet g:Tex_ViewerCwindowHeight = 5
" Height of preview window
+ " Default: 10
TexLet g:Tex_ViewerPreviewHeight = 10
" Options for explorer completion.
" Height of explorer window
+ " Default: 10
TexLet g:Tex_ExplorerHeight = 10
" Directory for images. Read |latex-completion-explorer| before changing
+ " Default: ''
TexLet g:Tex_ImageDir = ''
+
" }}}
***************
*** 440,443 ****
--- 448,452 ----
" mathematical fonts (\mathrm), mathematical diacritics (\dot), binary
" relational operators etc. This menu compromises about 75% of the menus.
+ " Default: 1
TexLet g:Tex_MathMenus = 1
***************
*** 447,450 ****
--- 456,460 ----
" be collected together into a single 'Tex-Elements' menu. Setting this to 0
" creates seperate menus for each of them.
+ " Default: 1
TexLet g:Tex_NestElementMenus = 1
***************
*** 458,462 ****
" menu.
" Default: 1
! TexLet g:Tex_NestPackagesMenu = 0
" This is the prefix added to the menu names created by latex suite. Add a
--- 468,472 ----
" menu.
" Default: 1
! TexLet g:Tex_NestPackagesMenu = 1
" This is the prefix added to the menu names created by latex suite. Add a
***************
*** 465,468 ****
--- 475,479 ----
" NOTE: With a '.' as the last character of the following setting, every
" single menu created by latex suite will be nested under the same menu.
+ " Default: 'TeX-'
TexLet g:Tex_MenuPrefix = 'TeX-'
***************
*** 486,489 ****
--- 497,510 ----
" by g:Tex_Folding), so you can do <F6> or \rf to refresh/create folds.
TexLet g:Tex_AutoFolding = 1
+
+ " }}}
+ " ==============================================================================
+ " TEXINPUTS: check this directories for user packages {{{
+ " Search some directories for user packages. They can contain, \usepackage,
+ " \newcommand etc. commands. LaTeX uses $TEXINPUTS variable. Because relations
+ " between Vim and shell aren't straightforward copy it here. Use exact syntax.
+ " Example g:Tex_TEXINPUTS = '.:~/texmf//:'. More in |latex-package-scanning|.
+ " Default: ''
+ TexLet g:Tex_TEXINPUTS = ''
" }}}
|
|
From: <mi...@us...> - 2003-04-07 20:53:11
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv7179
Modified Files:
packages.vim
Log Message:
Dealing with TEXINPUTS and packages.
Unfortunately relations of Vim with shell are not
straightforwart. We cannot assume that always we
will know its value. Much simplier (although not
so elegant) is g:Tex_TEXINPUTS variable.
This should be equal to real $TEXINPUTS. More info
in latex-suite.txt - |latex-package-scanning|
Index: packages.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v
retrieving revision 1.30
retrieving revision 1.31
diff -C2 -d -r1.30 -r1.31
*** packages.vim 6 Apr 2003 22:59:50 -0000 1.30
--- packages.vim 7 Apr 2003 20:53:03 -0000 1.31
***************
*** 310,315 ****
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
--- 310,315 ----
endif
! " Check if one of declared packages isn't user package in current
! " Basing on TEXINPUTS.
if !exists("s:Tex_up_check")
" Prevents endless loop
***************
*** 326,344 ****
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
--- 326,422 ----
let stypath = expand("%:p:h").'/'.userpackage.'.sty'
! " If package with given name exists in current dir
" check if there are usepackage commands, newcommand etc.
if filereadable(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
+
+ " Check list of locations from $TEXINPUTS variable. But before simple
+ " trick - add current directory to make everything in one loop
+ if g:Tex_TEXINPUTS != ''
+ let inputdirs = g:Tex_TEXINPUTS
+
+ let id = 1
+ while Tex_Strntok(inputdirs, ':', id) != ''
+ let cur_input_dir = Tex_Strntok(inputdirs, ':', id)
+
+ " Skip current directory, we checked it already
+ if cur_input_dir == "\\." || cur_input_dir == "\\./"
+ let g:cid1 = cur_input_dir
+ let id = id + 1
+ continue
+
+ " Deal with ./ entries
+ elseif cur_input_dir =~ "^\\./"
+ let g:cid2 = cur_input_dir
+
+ let cur_dir = expand("%:p:h")
+
+ if cur_input_dir == './/'
+ let stypath = globpath(cur_dir.'/*', userpackage.'.sty')
+ if filereadable(stypath)
+ call Tex_pack_all(stypath)
+ exe 'bwipe '.stypath
+ exe 'setlocal complete+=s'.stypath
+ endif
+
+ else
+ let cur_input_dir = substitute(cur_input_dir,'./','','e')
+ let stypath = cur_dir.'/'.cur_input_dir.'/'.userpackage.'.sty'
+ if filereadable(stypath)
+ call Tex_pack_all(stypath)
+ exe 'bwipe '.stypath
+ exe 'setlocal complete+=s'.stypath
+ endif
+
+ endif
+
+ " Check one-level directory item variable.
+ elseif cur_input_dir !~ '//$'
+ let cur_input_dir = substitute(cur_input_dir,'/*$','','ge')
+ let stypath = cur_input_dir.'/'.userpackage.'.sty'
+ let stypath = fnamemodify(stypath, ':p')
+ if filereadable(stypath)
+ call Tex_pack_all(stypath)
+ exe 'bwipe '.stypath
+ exe 'setlocal complete+=s'.stypath
+ endif
+
+ " Check the rest. Now this is fake because currently Vim
+ " doesn't accept ** in globpath(). Solution with '/*'
+ " provides only one level depth but ** in globpath() is on
+ " TODO list. In future versions of Vim we will only need
+ " to add one * in globpath.
+ else
+ let cur_input_dir = substitute(cur_input_dir,'/*$','','ge')
+ let stypath = fnamemodify(cur_input_dir, ':p:h')
+
+ let stypath2 = stypath.'/'.userpackage.'.sty'
+ if filereadable(stypath2)
+ call Tex_pack_all(stypath2)
+ exe 'bwipe '.stypath2
+ exe 'setlocal complete+=s'.stypath2
+ endif
+
+ let stypathglob = globpath(stypath.'/*', userpackage.'.sty')
+ if filereadable(stypathglob)
+ call Tex_pack_all(stypathglob)
+ exe 'bwipe '.stypathglob
+ exe 'setlocal complete+=s'.stypathglob
+ endif
+
+ endif
+
+ let id = id + 1
+
+ endif
+
+ endwhile
let fn = fn + 1
|