vim-latex-cvs Mailing List for Vim-Latex (Page 12)
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: <sri...@us...> - 2003-12-19 03:06:29
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv11801
Modified Files:
templates.vim
Log Message:
Bug: When the user's 'fo' setting had 'ro' included in it, then inserting
templates would result in strange leading indentation (it would be
doubled etc).
Why: IMAP_PutTextWithMovement simulates key-presses. Therefore if 2
successive lines in the template begin with ``%`` and ``'fo'`` has
``ro``, then the second line will have an extra ``%`` character.
Fix: Set ``'fo'`` temporarily to an empty string.
Index: templates.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/templates.vim,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** templates.vim 16 Dec 2003 20:29:25 -0000 1.16
--- templates.vim 19 Dec 2003 03:06:26 -0000 1.17
***************
*** 70,76 ****
--- 70,84 ----
normal! ggVG"ax
+ let _fo = &fo
+ " Since IMAP_PutTextWithMovement simulates the key-presses, leading
+ " indendatation can get duplicated in strange ways if ``fo`` is non-empty.
+ " NOTE: the indentexpr thingie is still respected with an empty fo so that
+ " environments etc are properly indented.
+ set fo=
+
call Tex_Debug("normal! i\<C-r>=IMAP_PutTextWithMovement(@a, '".s:phsTemp."', '".s:pheTemp."')\<CR>", 'templates')
exec "normal! i\<C-r>=IMAP_PutTextWithMovement(@a, '".s:phsTemp."', '".s:pheTemp."')\<CR>"
+ let &fo = _fo
let @a = _a
|
|
From: <sri...@us...> - 2003-12-17 06:24:22
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv6838
Modified Files:
texviewer.vim
Log Message:
Bug: A very restrictive RE sometimes did not match the bib-key which was
being completed.
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.36
retrieving revision 1.37
diff -C2 -d -r1.36 -r1.37
*** texviewer.vim 16 Dec 2003 23:41:10 -0000 1.36
--- texviewer.vim 17 Dec 2003 06:24:19 -0000 1.37
***************
*** 333,337 ****
let bibkey = matchstr(getline('.'), '\\bibitem{\zs.\{-}\ze}')
else
! let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze,')
endif
let completeword = strpart(bibkey, strlen(s:prefix))
--- 333,337 ----
let bibkey = matchstr(getline('.'), '\\bibitem{\zs.\{-}\ze}')
else
! let bibkey = matchstr(getline('.'), '{\zs.\{-}\ze\(,\|$\)')
endif
let completeword = strpart(bibkey, strlen(s:prefix))
|
|
From: <sri...@us...> - 2003-12-17 03:12:33
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8712
Modified Files:
packages.vim
Log Message:
Bug: loading templates no longer works.
Why: Apparently if one is editing a file, say file.tex which is modified,
then one cannot do ":split file.tex"
Fix: Only split a window if the main file name is not the current file.
TODO: What happens if the main file is being opened in a seperate
window and is modified?
Index: packages.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -d -r1.44 -r1.45
*** packages.vim 15 Dec 2003 03:33:52 -0000 1.44
--- packages.vim 17 Dec 2003 03:12:31 -0000 1.45
***************
*** 139,144 ****
let g:Tex_PromptedCommands = g:Tex_PromptedCommandsDefault
! call Tex_Debug(':Tex_pack_updateall: split '.Tex_EscapeSpaces(fname), 'pack')
! exe 'split '.Tex_EscapeSpaces(fname)
call Tex_ScanForPackages()
q
--- 139,150 ----
let g:Tex_PromptedCommands = g:Tex_PromptedCommandsDefault
! if expand('%:p') != fname
! call Tex_Debug(':Tex_pack_updateall: split '.Tex_EscapeSpaces(fname), 'pack')
! exe 'split '.Tex_EscapeSpaces(fname)
! else
! call Tex_Debug(':Tex_pack_updateall: split')
! split
! endif
!
call Tex_ScanForPackages()
q
|
|
From: <sri...@us...> - 2003-12-16 23:41:15
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv4145
Modified Files:
texviewer.vim
Log Message:
Bug: \cite completion did not work. The prefix was not honored and
therefore all the matches would be shown and moreover the text would
not be inserted properly.
Cause: We had used the pattern::
let s:prefix = matchstr(s:prefix, '\([^,]\+,\)\+\zs\([^,]\+\)\ze$')
to modify the prefix. However, this only succeeds when there are
more than 1 items in the \cite. i.e, \cite{key1,pre. s:prefix
becomes empty if we do try to complete just \cite{pre
Fix: Change the prefix to::
let s:prefix = matchstr(s:prefix, '\([^,]\+,\)*\zs\([^,]\+\)\ze$')
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.35
retrieving revision 1.36
diff -C2 -d -r1.35 -r1.36
*** texviewer.vim 15 Dec 2003 00:55:26 -0000 1.35
--- texviewer.vim 16 Dec 2003 23:41:10 -0000 1.36
***************
*** 59,63 ****
let s:curfile = expand("%:p")
let s:curline = strpart(getline('.'), col('.') - 40, 40)
! let s:prefix = matchstr(s:curline, '.*{\zs.\{-}$')
" a command is of the type
" \psfig[option=value]{figure=}
--- 59,63 ----
let s:curfile = expand("%:p")
let s:curline = strpart(getline('.'), col('.') - 40, 40)
! let s:prefix = matchstr(s:curline, '.*{\zs.\{-}\(}\|$\)')
" a command is of the type
" \psfig[option=value]{figure=}
***************
*** 87,96 ****
" TODO: Is there a way to clear the search-history w/o making a
" useless, inefficient search?
! let s:prefix = matchstr(s:prefix, '\([^,]\+,\)\+\zs\([^,]\+\)\ze$')
silent! grep! ____HIGHLY_IMPROBABLE___ %
if g:Tex_RememberCiteSearch && exists('s:citeSearchHistory')
call <SID>Tex_SetupCWindow(s:citeSearchHistory)
else
! call Tex_Debug('calling Tex_GrepForBibItems', 'bib')
call Tex_GrepForBibItems(s:prefix)
redraw!
--- 87,96 ----
" TODO: Is there a way to clear the search-history w/o making a
" useless, inefficient search?
! let s:prefix = matchstr(s:prefix, '\([^,]\+,\)*\zs\([^,]\+\)\ze$')
silent! grep! ____HIGHLY_IMPROBABLE___ %
if g:Tex_RememberCiteSearch && exists('s:citeSearchHistory')
call <SID>Tex_SetupCWindow(s:citeSearchHistory)
else
! call Tex_Debug('calling Tex_GrepForBibItems', 'view')
call Tex_GrepForBibItems(s:prefix)
redraw!
***************
*** 169,173 ****
" Tex_CompleteWord: inserts a word at the chosen location {{{
! " Description:
function! Tex_CompleteWord(completeword)
exe s:pos
--- 169,175 ----
" Tex_CompleteWord: inserts a word at the chosen location {{{
! " Description: This function is meant to be called when the user press
! " ``<enter>`` in one of the [Error List] windows which shows the list of
! " matches. completeword is the rest of the word which needs to be inserted.
function! Tex_CompleteWord(completeword)
exe s:pos
***************
*** 346,349 ****
--- 348,352 ----
call Tex_CloseSmallWindows()
+ call Tex_Debug(":Tex_CompleteRefCiteCustom: completing with ".completeword, "view")
call Tex_CompleteWord(completeword)
endfunction " }}}
***************
*** 495,499 ****
" as soon as the first \bibliography or \begin{thebibliography} is found.
function! Tex_ScanFileForCite(prefix)
! call Tex_Debug('searching for bibkeys in '.bufname('%').' (buffer #'.bufnr('%').')', 'bib')
let presBufNum = bufnr('%')
--- 498,502 ----
" as soon as the first \bibliography or \begin{thebibliography} is found.
function! Tex_ScanFileForCite(prefix)
! call Tex_Debug('searching for bibkeys in '.bufname('%').' (buffer #'.bufnr('%').')', 'view')
let presBufNum = bufnr('%')
***************
*** 503,507 ****
" bibliography.
if search('\\bibliography{', 'w')
! call Tex_Debug('found bibliography command in '.bufname('%'), 'bib')
" convey that we have found a bibliography command. we do not need to
" proceed any further.
--- 506,510 ----
" bibliography.
if search('\\bibliography{', 'w')
! call Tex_Debug('found bibliography command in '.bufname('%'), 'view')
" convey that we have found a bibliography command. we do not need to
" proceed any further.
***************
*** 512,516 ****
let bibnames = substitute(bibnames, '\s', '', 'g')
! call Tex_Debug('trying to search through ['.bibnames.']', 'bib')
let i = 1
--- 515,519 ----
let bibnames = substitute(bibnames, '\s', '', 'g')
! call Tex_Debug('trying to search through ['.bibnames.']', 'view')
let i = 1
***************
*** 524,531 ****
split
let thisbufnum = bufnr('%')
! call Tex_Debug('silent! find '.Tex_Strntok(bibnames, ',', i).'.bib', 'bib')
exec 'silent! find '.Tex_Strntok(bibnames, ',', i).'.bib'
if bufnr('%') != thisbufnum
! call Tex_Debug('finding .bib file ['.bufname('%').']', 'bib')
lcd %:p:h
" use the appropriate syntax for the .bib file.
--- 527,535 ----
split
let thisbufnum = bufnr('%')
! call Tex_Debug('silent! find '.Tex_Strntok(bibnames, ',', i).'.bib', 'view')
exec 'silent! find '.Tex_Strntok(bibnames, ',', i).'.bib'
if bufnr('%') != thisbufnum
! call Tex_Debug('finding .bib file ['.bufname('%').']', 'view')
! call Tex_Debug('using pattern '.Tex_EscapeForGrep('@.*{'.a:prefix), 'view')
lcd %:p:h
" use the appropriate syntax for the .bib file.
***************
*** 534,540 ****
let thisbufnum = bufnr('%')
exec 'silent! find '.Tex_Strntok(bibnames, ',', i).'.bbl'
! call Tex_Debug('now in bufnum#'.bufnr('%'), 'bib')
if bufnr('%') != thisbufnum
! call Tex_Debug('finding .bbl file ['.bufname('.').']', 'bib')
lcd %:p:h
exec "silent! grepadd ".Tex_EscapeForGrep('\\bibitem{'.a:prefix)." %"
--- 538,544 ----
let thisbufnum = bufnr('%')
exec 'silent! find '.Tex_Strntok(bibnames, ',', i).'.bbl'
! call Tex_Debug('now in bufnum#'.bufnr('%'), 'view')
if bufnr('%') != thisbufnum
! call Tex_Debug('finding .bbl file ['.bufname('.').']', 'view')
lcd %:p:h
exec "silent! grepadd ".Tex_EscapeForGrep('\\bibitem{'.a:prefix)." %"
***************
*** 556,560 ****
" upwards by returning 1.
if search('^\s*\\begin{thebibliography}', 'w')
! call Tex_Debug('got a thebibliography environment in '.bufname('%'), 'bib')
let foundCiteFile = 1
--- 560,564 ----
" upwards by returning 1.
if search('^\s*\\begin{thebibliography}', 'w')
! call Tex_Debug('got a thebibliography environment in '.bufname('%'), 'view')
let foundCiteFile = 1
***************
*** 585,589 ****
if bufnr('%') != thisbufnum
" DANGER! recursive call.
! call Tex_Debug('scanning recursively in ['.bufname('%').']', 'bib')
let foundCiteFile = Tex_ScanFileForCite(a:prefix)
endif
--- 589,593 ----
if bufnr('%') != thisbufnum
" DANGER! recursive call.
! call Tex_Debug('scanning recursively in ['.bufname('%').']', 'view')
let foundCiteFile = Tex_ScanFileForCite(a:prefix)
endif
|
|
From: <sri...@us...> - 2003-12-16 21:27:24
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/templates
In directory sc8-pr-cvs1:/tmp/cvs-serv5270
Modified Files:
IEEEtran.tex
Log Message:
Bug: IEEEtran.tex template inserted needless indentation. There was also an
extra ``\begin{document}`` and some mismatched curly braces.
Please follow the following guidelines henceforth in creating templates:
1. The first placeholder in the template should be an empty placeholder
As of now, vim does not provide the equivalent of a "startinsert"
command for leaving in visual mode.
2. There should not be any indentation in the file. For example, if the
template contains a ``\begin{eqnarray}``, it should be written as::
\begin{eqnarray}
<+write equation here+>
\end{eqnarray}
instead of::
\begin{eqnarray}
<+write equation here+>
\end{eqnarray}
``IMAP_PutTextWithMovement`` automatically inserts the correct
indentation according to the user's ``'sw'`` and other indent settings.
3. No trailing empty lines after the ``\end{document}``.
Index: IEEEtran.tex
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/templates/IEEEtran.tex,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** IEEEtran.tex 29 Jan 2003 03:17:20 -0000 1.1
--- IEEEtran.tex 16 Dec 2003 21:27:20 -0000 1.2
***************
*** 19,24 ****
%
\documentclass[journal]{IEEEtran}
- \begin{document}
-
\usepackage{cite, graphicx, subfigure, amsmath}
--- 19,22 ----
***************
*** 29,33 ****
% There should be no need to do such things with IEEEtran.cls V1.6 and later.
!
% correct bad hyphenation here
\hyphenation{<+op-tical net-works semi-conduc-tor+>}
--- 27,31 ----
% There should be no need to do such things with IEEEtran.cls V1.6 and later.
! <++>
% correct bad hyphenation here
\hyphenation{<+op-tical net-works semi-conduc-tor+>}
***************
*** 48,56 ****
% was not built to handle multiple paragraphs
\author{<+Sumit Bhardwaj+>~\IEEEmembership{<+Student~Member,~IEEE,+>}
! <+John~Doe+>,~\IEEEmembership{<+Fellow,~OSA,+>}
! <+and~Jane~Doe,+>~\IEEEmembership{<+Life~Fellow,~IEEE+>}% <-this % stops a space
\thanks{<+Manuscript received January 20, 2002; revised August 13, 2002.
! This work was supported by the IEEE.+>}% <-this % stops a space
! \thanks{<+S. Bhardwaj is with the Indian Institute of Technology, Delhi.+>}}
%
% The paper headers
--- 46,54 ----
% was not built to handle multiple paragraphs
\author{<+Sumit Bhardwaj+>~\IEEEmembership{<+Student~Member,~IEEE,+>}
! <+John~Doe+>,~\IEEEmembership{<+Fellow,~OSA,+>}
! <+and~Jane~Doe,+>~\IEEEmembership{<+Life~Fellow,~IEEE+>}}% <-this % stops a space
\thanks{<+Manuscript received January 20, 2002; revised August 13, 2002.
! This work was supported by the IEEE.+>}% <-this % stops a space
! \thanks{<+S. Bhardwaj is with the Indian Institute of Technology, Delhi.+>}
%
% The paper headers
***************
*** 108,112 ****
\bibitem{IEEEhowto:kopka}
H.~Kopka and P.~W. Daly, \emph{A Guide to {\LaTeX}}, 3rd~ed.\hskip 1em plus
! 0.5em minus 0.4em\relax Harlow, England: Addison-Wesley, 1999.
\end{thebibliography}
--- 106,110 ----
\bibitem{IEEEhowto:kopka}
H.~Kopka and P.~W. Daly, \emph{A Guide to {\LaTeX}}, 3rd~ed.\hskip 1em plus
! 0.5em minus 0.4em\relax Harlow, England: Addison-Wesley, 1999.
\end{thebibliography}
***************
*** 143,146 ****
\end{document}
-
-
--- 141,142 ----
|
|
From: <sri...@us...> - 2003-12-16 20:29:28
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv22479
Modified Files:
templates.vim
Log Message:
Bug: When g:Imap_PlaceHolderStart and/or g:Imap_PlaceHolderEnd settings
were not ascii and encoding=utf8, then reading in a template did not
work as advertised (placeholders are shown as <ab><bb> etc)
Why: templates.vim still used simple pattern substitution to replace the
placeholder characters, which does not work in the above setting.
Fix: Use IMAP_PutTextWithMovement which handles the above situation.
Index: templates.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/templates.vim,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -d -r1.15 -r1.16
*** templates.vim 16 Nov 2003 15:12:31 -0000 1.15
--- templates.vim 16 Dec 2003 20:29:25 -0000 1.16
***************
*** 24,30 ****
endif
exe "amenu ".g:Tex_TemplatesMenuLocation."&".i.":<Tab>".fname." ".
! \":call <SID>ReadTemplate('".fname."')<CR>".
! \":call <SID>ProcessTemplate()<CR>:0<CR>".
! \"i<C-r>=IMAP_Jumpfunc('', 1)<CR>"
let i = i + 1
endwhile
--- 24,28 ----
endif
exe "amenu ".g:Tex_TemplatesMenuLocation."&".i.":<Tab>".fname." ".
! \":call <SID>ReadTemplate('".fname."')<CR>"
let i = i + 1
endwhile
***************
*** 51,55 ****
--- 49,55 ----
let fname = Tex_FindInRtp(filename.'.tex', 'templates', ':p')
call Tex_Debug("0read ".fname, 'templates')
+
silent! exe "0read ".fname
+
" The first line of the file contains the specifications of what the
" placeholder characters and the other special characters are.
***************
*** 61,68 ****
let s:comTemp = substitute(getline(1), pattern, '\4', '')
! call Tex_Debug('phs = '.s:phsTemp.', phe = '.s:pheTemp.', exe = '.s:exeTemp.', com = '.s:comTemp, 'templates')
! " delete the first line into ze blackhole.
! 0 d _
call Tex_pack_updateall(1)
--- 61,79 ----
let s:comTemp = substitute(getline(1), pattern, '\4', '')
! call s:ProcessTemplate()
! 0 d_
! " Do not handle the placeholders here. Let IMAP_PutTextWithMovement do it
! " because it handles UTF-8 character substitutions etc. Therefore delete
! " the text into @a and paste it using IMAP_PutTextWithMovement().
! let _a = @a
! normal! ggVG"ax
!
! call Tex_Debug("normal! i\<C-r>=IMAP_PutTextWithMovement(@a, '".s:phsTemp."', '".s:pheTemp."')\<CR>", 'templates')
! exec "normal! i\<C-r>=IMAP_PutTextWithMovement(@a, '".s:phsTemp."', '".s:pheTemp."')\<CR>"
!
! let @a = _a
!
! call Tex_Debug('phs = '.s:phsTemp.', phe = '.s:pheTemp.', exe = '.s:exeTemp.', com = '.s:comTemp, 'templates')
call Tex_pack_updateall(1)
***************
*** 81,89 ****
exec 'silent! g/'.s:comTemp.s:comTemp.'/d'
- let phsUser = IMAP_GetPlaceHolderStart()
- let pheUser = IMAP_GetPlaceHolderEnd()
-
- exec 'silent! %s/'.s:phsTemp.'\(.\{-}\)'.s:pheTemp.'/'.phsUser.'\1'.pheUser.'/ge'
-
" A function only puts one item into the search history...
call Tex_CleanSearchHistory()
--- 92,95 ----
***************
*** 109,115 ****
if v:version >= 602
com! -complete=custom,Tex_CompleteTemplateName -nargs=? TTemplate :call <SID>ReadTemplate(<f-args>)
- \| :call <SID>ProcessTemplate()
- \| :0
- \| :exec "normal! i\<C-r>=IMAP_Jumpfunc('', 1)\<CR>"
\| :startinsert
--- 115,118 ----
***************
*** 129,135 ****
else
com! -nargs=? TTemplate :call <SID>ReadTemplate(<f-args>)
- \| :call <SID>ProcessTemplate()
- \| :0
- \| :exec "normal! i\<C-r>=IMAP_Jumpfunc('', 1)\<CR>"
\| :startinsert
--- 132,135 ----
|
|
From: <sri...@us...> - 2003-12-16 19:43:25
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv10974
Modified Files:
main.vim
Log Message:
Recently, I had to fix a bug in packages.vim which made vim quit as soon as
it was open. Since I couldn't use the Tex_PrintDebug() function, I made a
little change which created a log file in the /tmp directory. This might be
a useful thing to have in the future, but ofcourse, it should definitely be
off by default.
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.58
retrieving revision 1.59
diff -C2 -d -r1.58 -r1.59
*** main.vim 15 Dec 2003 03:33:52 -0000 1.58
--- main.vim 16 Dec 2003 19:43:22 -0000 1.59
***************
*** 592,598 ****
\ . pattern.' : '.a:str."\n"
! redir! >> /tmp/ls.log
! silent! echo pattern.' : '.a:str
! redir END
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
--- 592,600 ----
\ . pattern.' : '.a:str."\n"
! if Tex_GetVarValue('Tex_DebugLog', '') != ''
! exec 'redir! >> '.Tex_GetVarValue('Tex_DebugLog', '')
! silent! echo pattern.' : '.a:str
! redir END
! endif
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
|
|
From: <sri...@us...> - 2003-12-16 04:40:41
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv8332 Added Files: latex-suite-quickstart.css Log Message: --- NEW FILE: latex-suite-quickstart.css --- /* * Authors: Srinath Avadhanula and Mikolaj Machowski * This style file borrows some elements from main.css, the style file used * in cream.sf.net * * */ P { font-size : 12pt ; font-family : helvetica, arial, verdana, sans-serif ; vertical-align : top; } DT { font-size : 11pt ; font-family : helvetica, arial, verdana, sans-serif ; vertical-align : top; } LI { font-size : 12pt ; font-family : helvetica, arial, verdana, sans-serif ; vertical-align : top; } DIV.header { margin : 0.5cm ; width : 800px ; height : 100 } .note { } TD { font-size : 11pt ; font-family : helvetica, arial, verdana, sans-serif ; vertical-align : top; } TD.menu { text-align : center ; font-family : verdana, helvetica, sans-serif } TD.footright { text-align : right ; font-size : 10pt ; font-family : verdana, helvetica, sans-serif } TD.leftpanel { font-size: 14px ; font-family: verdana, helvetica, sans-serif ; vertical-align: top ; width: 150px; padding: 15px; background-color: #88aaaa; } TD.mainpanel { font-size : 12pt ; font-family : helvetica, arial, verdana, sans-serif ; vertical-align : top; padding: 15px; } TD.footpanel { font-size: 12px ; font-family: verdana, helvetica, sans-serif ; vertical-align: top ; text-align: right; padding: 5px; background-color: #88aaaa; } .navigation { vertical-align: top; width: 150px; padding: 15px; background-color: #445555; color: #fffcfc; } .navheader { margin-top: -0.5em; margin-bottom: 0.5em; text-align: right; color: #446644; font-size: 14px; font-weight: bold; } SPAN.menu { text-align : center ; font-size : 12pt ; font-family : verdana, helvetica, sans-serif } DIV.merit { margin : 0.5cm ; width : 800px } TABLE.meritum { margin : 0.5cm ; border : 0 } .foot { margin : 0.5cm ; width : 800px } .head { margin : 0.5cm ; } CODE { font-family: "Andale Mono", "Courier New", "Courier", monospace; background-color: #eef0f3; white-space: nowrap; } .singlesmall { font-size: 14px; } .doublesmall { font-size: 12px; } DIV.footer { margin : 0.5cm ; width : 800px } .qa { margin : 0.5cm ; font-size : 16px; font-weight : bold; } .ans { margin : 0.5cm ; font-weight : normal; } H2.hline { text-align : center ; font-family : verdana, helvetica, sans-serif } A.extlinks { font-size : 11pt ; font-family : verdana, helvetica, sans-serif ; font-weight : bold } TT { font-family: courier,sans-serif; font-size: 11pt; } PRE.programlisting { font-family: courier,sans-serif; font-size: 10pt; background-color:#eef0f3; border-color: #000000; border-width: 1px; border-style: solid; } SPAN.conflict { font-size : small ; font-family: courier,sans-serif; color : #DD4444; } HR.navig { color: #446644; height: 1px; margin-top: 1em; border-top: 0px; /* Mozilla work-around to eliminate "groove" */ } A.question { color: #000000; height: 1px; margin-top: 1em; border-top: 0px; /* Mozilla work-around to eliminate "groove" */ } A.question:hover { color: #000000; background-color: #eef0f3; height: 1px; margin-top: 1em; border-top: 0px; /* Mozilla work-around to eliminate "groove" */ } |
|
From: <sri...@us...> - 2003-12-16 04:04:49
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv2807
Added Files:
latex-suite-quickstart.txt latex-suite-quickstart.xml
Log Message:
adding quick-start tutorial files
--- NEW FILE: latex-suite-quickstart.txt ---
A (very) quick introduction to Latex-Suite
*latex-suite-quickstart.txt*
Srinath Avadhanula <srinath AT fastmail DOT fm>
Abstract
========
Latex-Suite is a comprehensive set of scripts to aid in editing, compiling and
viewing LaTeX documents. A thorough explanation of the full capabilities of
Latex-Suite is described in the user manual. This guide on the other hand,
provides a quick 30-45 minute running start to some of the more commonly used
functionalities of Latex-Suite.
*latex-suite-quickstart.txt-toc*
|lq_1| Using this tutorial
|lq_2| Inserting a template
|lq_3| Inserting a package
|lq_4| Inserting an Environment
|lq_5| A few keyboard shortcuts
|lq_6| Folding in Latex-Suite
|lq_7| Inserting a Reference
|lq_8| Compiling a document
|lq_8_1| Debugging LaTeX source files
|lq_9| Viewing DVI files
|lq_9_1| Performing forward searches
|lq_9_2| Performing inverse searches
|lq_10| Conclusions
================================================================================
Viewing this file
This file can be viewed with all the sections and subsections folded to ease
navigation. By default, vim does not fold help documents. To create the folds,
press za now. The folds are created via a foldexpr which can be seen in the
last section of this file.
See |usr_28.txt| for an introduction to folding and |fold-commands| for key
sequences and commands to work with folds.
================================================================================
Using this tutorial *lq_1* *lq_a_bc*
*lsq-using-tutorial*
This tutorial assumes that you have vim version 6.1+ installed on your machine.
To check, open vim and type >
:ver
You will see the version in the first line of the output. Get the latest vim
version from http://vim.sf.net |lq_u_1|.
Assuming you have Vim 6.1+ already up and running, follow the instructions here
|lq_u_2| to set up Latex-Suite. Remember to make sure your 'grepprg' setting of
Vim works.
Good, now you are all set to start the tutorial. Since this tutorial aims to
explain the newbie-friendly version of Latex-Suite, it needs some GUI
functionality. Therefore, at least for this tutorial, open the gui version of
vim. (On MS windows, this is the default). Open up this help file in either the
same gvim session in a split window or in a different session and follow the
(friendly) instructions.
================================================================================
Inserting a template *lq_2* *lq_a_bd*
*lsq-inserting-template*
Start up gvim and begin editing a new file. >
e newfile.tex
If the installation went well, you should see a new set of menus appear. Goto
Tex-Suite > Templates. You will see a number of templates to choose from. For
now, choose to insert a template for an article. You should get the following in
the main vim window (after possibly a hit-enter prompt). >
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Sun Jun 22 04:00 PM 2003 P
4 %
5 \documentclass[a4paper]{article}
6 \begin{document}
7
8 \end{document}
9
10 ~
11 ~
12 ~
13 ~
-- INSERT -- 7,1 All
The cursor is left on line 7 (just after the \begin{document} line) from where
you can start typing straight away. Trying to lessen movement is a recurring
theme in Latex-Suite.
================================================================================
Inserting a package *lq_3* *lq_a_be*
*lsq-lsq-inserting-package*
Assume that we are writing a mathematical paper and we want to use the popular
amsmath package. We will use some functionality which Latex-Suite provides
specifically for including LaTeX packages, providing options etc. Navigate to
before the \begin{document} line (The portion of the document before the
\begin{document} is called the _preamble_ in LaTeX). On an empty line in the
preamble, type the single word amsmath and then press <F5> in normal mode. The
line will change to >
\usepackage[]{amsmath}<++>
with the cursor positioned conviniently between the []'s. For now, do not worry
about the trailing <++> at the end of this line. Assume we want to provide the
sumlimits options to amsmath. You can either type in this option manually, or
choose from a menu of package options which Latex-Suite automatically creates
when you insert a package using <F5>. With the cursor still placed between the
[], goto TeX-Suite > Packages > amsmath Options. Choose the sumlimits option.
The package line should get converted to: >
\usepackage[sumlimits,]{amsmath}<++>
with the cursor before ]. Press <C-j> in insert mode. You will see the cursor
jump to the end of the package line and the trailing <++> will dissapear. What
just happened?! You had your first taste of _Placeholders_. Read more about them
(later) here |lq_u_3|. In short, pressing <C-j> in insert mode takes you to the
next <++> in the text.
================================================================================
Inserting an Environment *lq_4* *lq_a_bf*
*lsq-insert-environment*
Now let us type in a simple formula in LaTeX. Move back to the body of the
document (The portion of the document between \begin{document} and
\end{document} is called the body). Type in a few simple sentences and then on
an empty line, type the single word eqnarray. Escape to normal mode and press
<F5>. (Remember: <F5> is very useful!) This time, the line will change to: >
\begin{eqnarray}
\label{}<++>
\end{eqnarray}<++>
<with the cursor between the {}. Enter a label. We will use eqn:euler. After
typing in eqn:euler, press <C-j>. This will take you outside the curly-braces.
Another time you used a Placeholder!
================================================================================
A few keyboard shortcuts *lq_5* *lq_a_bg*
*lsq-keyboard-shortcuts*
Now to type in the famous Euler formula. Our aim is to type >
e^{j\pi} + 1 &=& 0
Instead of typing this blindly, let us use a few shortcuts to reduce movement.
Start out by typing e^. Now instead of typing {, type another ^. You will see
the e^^ change instantly to e^{}<++> with the cursor between {}'s. (The ^^
changed to ^{}<++>.) Continue with the following sequence of letters: j`p. This
will change instantly to j\pi. (The `p changed to \pi.) Having typed in all we
need to type between the {}'s, press <C-j>. You will pop back out of the
curly-braces. Continue typing the rest of the formula. You can use == as a
shortcut for &=&. Latex-Suite provides a large number of such shortcuts which
should making typing much more fun and fast if you get acquainted with them. A
list is provided here |lq_u_4|. Definitely spend some time getting a feel for
them. Most of them are pretty intuitive like `/ for \frac{}{}, `8 for \infty
etc.
In order to understand the next section better, it will be helpful to have one
more \label. Lets use the handy <F5> key to insert another equation. This time
something simple like the following will do: >
\begin{eqnarray}
\label{eqn:simple}
1 + 1 = 2
\end{eqnarray}
================================================================================
Folding in Latex-Suite *lq_6* *lq_a_bh* *lsq-folding*
Okay, we have typed enough. At this stage, hopefully, your file is looking
something like this: >
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Mon Dec 15 07:00 PM 2003
4 %
5 \documentclass[a4paper]{article}
6
7 \usepackage[sumlimits,]{amsmath}
8
9 \begin{document}
10 \begin{eqnarray}
11 \label{eqn:euler}
12 e^{j\pi} + 1 &=& 0
13 \end{eqnarray}
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
17 \begin{eqnarray}
18 \label{eqn:simple}
19 1 + 1 &=& 2
20 \end{eqnarray}
21 This is my contribution to mathematics.
22 \end{document}
In normal mode, press \rf. This will fold up the entire file and you should see
the file looking as below: >
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Mon Dec 15 07:00 PM 2003
4 %
5 +-- 4 lines: Preamble: \documentclass[a4paper]{article} -----
9 \begin{document}
10 +-- 4 lines: eqnarray (eqn:euler) \label{eqn:euler} -----------
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
10 +-- 4 lines: eqnarray (eqn:simple) \label{eqn:simple} ---------
21 This is my contribution to mathematics.
22 \end{document}
What has happened is that Latex-Suite folded away blocks of LaTeX code into
folded regions. You can open and close folds by using the command za in normal
mode.
================================================================================
Inserting a Reference *lq_7* *lq_a_bi*
*lsq-inserting-reference*
A necessary part of LaTeX editing is referencing equations, figures,
bibliographic entries etc. This is done with the \ref and the \cite commands.
Latex-Suite provides an easy way to do this. Somewhere in the body of the
document, type in the following sentence >
This is a reference to (\ref{}).
With the cursor between the {} press <F9> in insert mode. Your vim session will
sprout two new windows and it should look like below: >
9 \begin{document}
10 +-- 4 lines: eqnarray (eqn:euler) : \label{eqn:euler}-----------------------
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
17 +-- 4 lines: eqnarray (eqn:simple) : \label{eqn:simple}---------------------
21 This is my contribution to mathematics.
22 This is a reference to (\ref{}<++>)<++>
23 \end{document}
~
~
~
test.tex [+] 22,29 Bot
test.tex|11| \label{eqn:euler}
test.tex|18| \label{eqn:simple}
~
~
~
[Error List] 1,1 All
7 \usepackage[sumlimits,]{amsmath}
8
9 \begin{document}
10 \begin{eqnarray}
11 \label{eqn:euler}
12 e^{j\pi} + 1 &=& 0
13 \end{eqnarray}
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
test.tex [Preview][+] 11,2-5 46%
The cursor will relocate to the middle window which shows all \labels found in
all the .tex file in the current directory. You can scroll up and down in the
middle window till you reach the reference you want to insert. Notice how when
you scroll in the middle window, the bottom "Preview" window scrolls
automatically to show you the location of the current selection. This helps you
identify the reference with greater ease because often times, \labels are not
descriptive enough or there might be too many of them. To insert the reference,
just position the cursor on the relevant line in the middle window and press
<enter>. The line which you were editing will change to: >
This is a reference to (\ref{eqn:euler})
<and the bottom windows close automatically.
The <F9> key also works for inserting \cite commands to reference bibliographich
entries, inserting file names for the \inputgraphics command and just plain
searching for words. Click here |lq_u_5| for more information.
================================================================================
Compiling a document *lq_8* *lq_a_bj*
*lsq-compiling*
|lq_8_1| Debugging LaTeX source files
Great! We have just created a small latex file. The next step is to make the
latex compiler create a .dvi file from it. Compiling via latex-suite is simple.
Goto normal mode and press \ll (replace \ with whatever mapleader setting you
have). This will call the latex compiler. If all goes well, then the focus
should return to the vim window.
Nothing happend? Ouch! You might need to do some additional settings as
described here. |lq_u_6|
--------------------------------------------------------------------------------
Debugging LaTeX source files *lq_8_1* *lq_a_bk*
*lsq-debugging*
To illustrate the debugging procedure, let's create a few mistakes in the file.
Insert the following ``mistakes'' in the file: >
This is a $\mistake$.
And this is $\another$
Now press \ll again. This time you will notice that after compilation finishes,
the cursor automatically lands on $\mistake$. In addition, 2 new windows will
appear as shown here:
The middle window is an _Error List_ window showing you the errors which the
latex compiler found. Th bottom window is a _Log Preview_ window, which shows
you the context of the error made by displaying the relevant portion of the .log
file created during the latex compilation procedure. Jump to the _Error List_
window and try scrolling around in it using either the j, k keys or the arrow
keys. You will notice that the _Log Preview_ window scrolls automatically to
retain the context of the error you are currently located on. If you press
<enter> on any line, you will see the cursor jump to the location of the error.
Latex-Suite tries to guess the column location as best as it can so you can
continue typing straight away.
Having got a taste for compiling, proceed by deleting the erroneous lines and
re-compiling.
The Latex-Suite compiler is capable of much more including selectively filtering
out common errors which you might want to ignore for the moment, compiling parts
of a document, setting levels of verbosity in the compiler output etc. See here
|lq_u_7| for more.
================================================================================
Viewing DVI files *lq_9* *lq_a_bl*
*lsq-viewing-dvi*
|lq_9_1| Performing forward searches
|lq_9_2| Performing inverse searches
Now that you have compiled your first latex source, its time to view it. Again,
this should be pretty simple. Press \lv in normal mode. Depending on your
platform, a DVI viewer program should open up and display the dvi file generated
in compilation step previously.
Nothing happend? Ouch! You might need to do some additional settings as
described here. |lq_u_8|
--------------------------------------------------------------------------------
Performing forward searches *lq_9_1* *lq_a_bm*
*lsq-quick-forward-searching*
If you are using a modern DVI viewer, then it is possible to do what is called
forward and inverse searching. However, you will need to customize the standard
Latex-Suite distribution in order to utilize this functionality. Type in the
following on the command line: >
:let g:Tex_CompileRule_dvi = 'latex -src-specials -interaction=nonstopmode $*'
:TCTarget dvi
Now recompile the latex file by pressing \ll. This time, instead of pressing \lv
to view the file, press \ls from within the tex file. If the DVI viewer supports
forward searching (most of them do), then the viewer will actually display the
portion of the DVI file corresponding to the location where you were editing the
tex file.
NOTE: The reason Latex-Suite does not have this setting by default is that on
some systems this causes unpredictable results in the DVI output. If you
find the DVI output satisfactory, then you can insert the first of the 2
lines above into your $VIM/ftplugin/tex.vim file. $VIM is ~/vimfiles for
windows and ~/.vim for *nix machines.
--------------------------------------------------------------------------------
Performing inverse searches *lq_9_2* *lq_a_bn*
*lsq-quick-inverse-searching*
Most DVI viewers also support inverse searching, whereby you can make the DVI
viewer ask vim to display the tex source corresponding to the DVI file being
shown. This is extremeley helpful while proofreading large documents.
Simply double-click anywhere in the viewer window. If the viewer supports it,
then it will attempt to open an editor window at the location corresponding to
where you double-clicked. On *nix platforms, Latex-Suite attempts to start the
viewer program in such a way that it already knows to use vim to open the tex
source. Thus you should see a vim window open up showing the tex file. However,
if there is an error, or some other program is used, you will need to tell the
viewer program to use gvim as the editor. On windows platforms, if you use the
commonly available yap viewer (available as part of the miktex distribution),
then this option can be set from View > Options > Inverse Search. In the Command
line: window, write >
"C:\Program Files\vim\vim61\gvim" -c ":RemoteOpen +%l %f"
(Customize the path according to where you have installed gvim). If you double
click in the view pane now, you will see gvim start up and take you to the
relevant portion of the tex file.
================================================================================
Conclusions *lq_10* *lq_a_bo*
*lsq-conclusions*
Thats all folks! By now, you should know enough of the basic functions of
latex-suite. Ofcourse, latex-suite is capable of much, much more such as
compiling files multiple times to resolve changed labels, compiling
dependencies, handling user packages and more. To get a feel for that, you will
need to take a look at the Latex-Suite user manual. |lq_u_9|
================================================================================
URLs used in this file
*lq_u_1* : http://vim.sf.net
*lq_u_2* : http://vim-latex.sourceforge.net/index.php?subject=download&title=Download
*lq_u_3* : http://vim-latex.sourceforge.net/documentation/latex-suite/latex-macros.html
*lq_u_4* : http://vim-latex.sourceforge.net/documentation/latex-suite/auc-tex-mappings.html
*lq_u_5* : http://vim-latex.sourceforge.net/documentation/latex-suite/latex-completion.html
*lq_u_6* : http://vim-latex.sourceforge.net/index.php?subject=faq&title=FAQ#faq-2
*lq_u_7* : http://vim-latex.sourceforge.net/documentation/latex-suite/latex-compiling.html
*lq_u_8* : http://vim-latex.sourceforge.net/index.php?subject=faq&title=FAQ#faq-3
*lq_u_9* : http://vim-latex.sourceforge.net/index.php?subject=manual&title=Manual#user-manual
================================================================================
About this file
This file was created automatically from its XML variant using db2vim. db2vim is
a python script which understands a very limited subset of the Docbook XML 4.2
DTD and outputs a plain text file in vim help format.
db2vim can be obtained via anonymous CVS from sourceforge.net. Use
cvs -d:pserver:ano...@cv...:/cvsroot/vim-latex co db2vim
Or you can visit the web-interface to sourceforge CVS at:
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/vim-latex/db2vim/
The following modelines should nicely fold up this help manual.
vim:ft=help:fdm=expr:nowrap
vim:foldexpr=getline(v\:lnum-1)=~'-\\{80}'?'>2'\:getline(v\:lnum-1)=~'=\\{80}'?'>1'\:getline(v\:lnum)=~'=\\{80}'?'0'\:getline(v\:lnum)=~'-\\{80}'?'1'\:'='
vim:foldtext=substitute(v\:folddashes.substitute(getline(v\:foldstart),'\\s*\\*.*',"",""),'^--','\ \ \ \ \ \ ','')
================================================================================
--- NEW FILE: latex-suite-quickstart.xml ---
<?xml version='1.0' encoding='ISO-8859-1'?>
<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
"docbook-xml/docbookx.dtd"
[<!ENTITY dummy "dummy">
<!ENTITY date "$Date: 2003/12/16 04:04:45 $">
<!ENTITY ls "Latex-Suite">
<!ENTITY latex "LaTeX">
<!ENTITY vim "Vim">
<!ENTITY ph "<++>">
]>
<article lang="en">
<articleinfo id="lsq-articleinfo">
<title id="lsq-articleinfo-title">A (very) quick introduction to Latex-Suite</title>
<author>
<firstname>Srinath</firstname>
<surname>Avadhanula</surname>
<affiliation>
<address><email>srinath AT fastmail DOT fm</email></address>
</affiliation>
</author>
<abstract>
&ls; is a comprehensive set of scripts to aid in editing, compiling and
viewing &latex; documents. A thorough explanation of the full
capabilities of &ls; is described in the user manual. This guide on the
other hand, provides a quick 30-45 minute running start to some of the
more commonly used functionalities of &ls;.
</abstract>
<date>&date;</date>
</articleinfo>
<section id="lsq-using-tutorial">
<title id="using-tutorial">Using this tutorial</title>
<para>
This tutorial assumes that you have vim version 6.1+ installed on your
machine. To check, open vim and type
<programlisting>:ver</programlisting>
You will see the version in the first line of the output. Get the latest
vim version from <ulink url="http://vim.sf.net">http://vim.sf.net</ulink>.
</para>
<para>
Assuming you have Vim 6.1+ already up and running, follow the
instructions <ulink
url="http://vim-latex.sourceforge.net/index.php?subject=download&title=Download">here</ulink>
to set up Latex-Suite. Remember to make sure your
<literal>'grepprg'</literal> setting of &vim; works.
</para>
<para>
Good, now you are all set to start the tutorial. Since this tutorial
aims to explain the newbie-friendly version of &ls;, it needs some GUI
functionality. Therefore, at least for this tutorial, open the gui
version of vim. (On MS windows, this is the default). Open up this help
file in either the same gvim session in a split window or in a different
session and follow the (friendly) instructions.
</para>
</section>
<section id="lsq-inserting-template">
<title id="inserting-template-title">Inserting a template</title>
<para>
Start up gvim and begin editing a new file.
<programlisting>e newfile.tex</programlisting>
If the installation went well, you should see a new set of
menus appear. Goto <literal>Tex-Suite > Templates</literal>. You will see
a number of templates to choose from. For now, choose to insert a
template for an article. You should get the following in the main
vim window (after possibly a hit-enter prompt).
<programlisting>
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Sun Jun 22 04:00 PM 2003 P
4 %
5 \documentclass[a4paper]{article}
6 \begin{document}
7
8 \end{document}
9
10 ~
11 ~
12 ~
13 ~
-- INSERT -- 7,1 All
</programlisting>
</para>
<imageobject>
<imagedata fileref="" format="png"></imagedata>
</imageobject>
<para>
The cursor is left on line 7 (just after the
<literal>\begin{document}</literal> line) from where you can start
typing straight away. Trying to lessen movement is a recurring theme in
Latex-Suite.
</para>
</section>
<section id="lsq-lsq-inserting-package">
<title>Inserting a package</title>
<para>
Assume that we are writing a mathematical paper and we want to use the
popular amsmath package. We will use some functionality which
Latex-Suite provides specifically for including LaTeX packages,
providing options etc. Navigate to before the
<literal>\begin{document}</literal> line (The portion of the document
before the <literal>\begin{document}</literal> is called the
<emphasis>preamble</emphasis> in LaTeX). On an empty line in the
preamble, type the single word <literal>amsmath</literal> and then press
<literal><F5></literal> in normal mode. The line will change to
<programlisting>\usepackage[]{amsmath}&ph;</programlisting>
with the cursor positioned conviniently between the
<literal>[]</literal>'s. For now, do not worry about the trailing
<literal>&ph;</literal> at the end of this line. Assume we want to
provide the <literal>sumlimits</literal> options to amsmath. You can
either type in this option manually, or choose from a menu of package
options which Latex-Suite automatically creates when you insert a
package using <literal><F5></literal>. With the cursor still
placed between the <literal>[]</literal>, goto <literal>TeX-Suite >
Packages > amsmath Options</literal>. Choose the
<literal>sumlimits</literal> option. The package line should get
converted to:
<programlisting>\usepackage[sumlimits,]{amsmath}&ph;</programlisting>
</para>
<para>
with the cursor before <literal>]</literal>. Press
<literal><C-j></literal> in insert mode. You will see the cursor
jump to the end of the package line and the trailing
<literal>&ph;</literal> will dissapear. What just happened?! You had
your first taste of <emphasis>Placeholders</emphasis>. Read more about
them (later) <ulink
url="http://vim-latex.sourceforge.net/documentation/latex-suite/latex-macros.html">here</ulink>.
In short, pressing <literal><C-j></literal> in insert mode takes
you to the next <literal>&ph;</literal> in the text.
</para>
</section>
<section id="lsq-insert-environment">
<title>Inserting an Environment</title>
<para>
Now let us type in a simple formula in LaTeX. Move back to the body of
the document (The portion of the document between
<literal>\begin{document}</literal> and
<literal>\end{document}</literal> is called the body). Type in a few
simple sentences and then on an empty line, type the single word
<literal>eqnarray</literal>. Escape to normal mode and press
<literal><F5></literal>. (Remember:
<literal><F5></literal> is very useful!) This time, the line will
change to:
<programlisting>\begin{eqnarray}
\label{}&ph;
\end{eqnarray}&ph;</programlisting>
with the cursor between the <literal>{}</literal>. Enter a label. We
will use <literal>eqn:euler</literal>. After typing in
<literal>eqn:euler</literal>, press <literal><C-j></literal>. This
will take you outside the curly-braces. Another time you used a
Placeholder!
</para>
</section>
<section id="lsq-keyboard-shortcuts">
<title>A few keyboard shortcuts</title>
<para>
Now to type in the famous Euler formula. Our aim is to type
<programlisting>e^{j\pi} + 1 &=& 0</programlisting> Instead
of typing this blindly, let us use a few shortcuts to reduce
movement. Start out by typing <literal>e^</literal>. Now instead of
typing <literal>{</literal>, type another <literal>^</literal>. You
will see the <literal>e^^</literal> change instantly to
<literal>e^{}&ph;</literal> with the cursor between
<literal>{}</literal>'s. (The <literal>^^</literal> changed to
<literal>^{}&ph;</literal>.) Continue with the following sequence of
letters: <literal>j`p</literal>. This will change instantly to
<literal>j\pi</literal>. (The <literal>`p</literal> changed to
<literal>\pi</literal>.) Having typed in all we need to type between
the <literal>{}</literal>'s, press <literal><C-j></literal>.
You will pop back out of the curly-braces. Continue typing the rest
of the formula. You can use <literal>==</literal> as a shortcut for
<literal>&=&</literal>. Latex-Suite provides a large number
of such shortcuts which should making typing much more fun and fast
if you get acquainted with them. A list is provided <ulink
url="http://vim-latex.sourceforge.net/documentation/latex-suite/auc-tex-mappings.html">here</ulink>. Definitely spend some time getting a feel for
them. Most of them are pretty intuitive like <literal>`/</literal>
for <literal>\frac{}{}</literal>, <literal>`8</literal> for
<literal>\infty</literal> etc.
</para>
<para>
In order to understand the next section better, it will be helpful
to have one more <literal>\label</literal>. Lets use the handy
<literal><F5></literal>
key to insert another equation. This time something simple like the
following will do:
<programlisting>\begin{eqnarray}
\label{eqn:simple}
1 + 1 = 2
\end{eqnarray}</programlisting>
</para>
</section>
<section id="lsq-folding">
<title>Folding in &ls;</title>
<para>
Okay, we have typed enough. At this stage, hopefully, your file is
looking something like this:
<programlisting>
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Mon Dec 15 07:00 PM 2003
4 %
5 \documentclass[a4paper]{article}
6
7 \usepackage[sumlimits,]{amsmath}
8
9 \begin{document}
10 \begin{eqnarray}
11 \label{eqn:euler}
12 e^{j\pi} + 1 &=& 0
13 \end{eqnarray}
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
17 \begin{eqnarray}
18 \label{eqn:simple}
19 1 + 1 &=& 2
20 \end{eqnarray}
21 This is my contribution to mathematics.
22 \end{document}
</programlisting>
In normal mode, press <literal>\rf</literal>. This will fold up the
entire file and you should see the file looking as below:
<programlisting>
1 % File: sample.tex
2 % Created: Sun Jun 22 04:00 PM 2003 P
3 % Last Change: Mon Dec 15 07:00 PM 2003
4 %
5 +-- 4 lines: Preamble: \documentclass[a4paper]{article} -----
9 \begin{document}
10 +-- 4 lines: eqnarray (eqn:euler) \label{eqn:euler} -----------
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
10 +-- 4 lines: eqnarray (eqn:simple) \label{eqn:simple} ---------
21 This is my contribution to mathematics.
22 \end{document}
</programlisting>
What has happened is that &ls; folded away blocks of &latex; code into
folded regions. You can open and close folds by using the command
<literal>za</literal> in normal mode.
</para>
</section>
<section id="lsq-inserting-reference">
<title>Inserting a Reference</title>
<para>
A necessary part of LaTeX editing is referencing equations, figures,
bibliographic entries etc. This is done with the
<literal>\ref</literal> and the <literal>\cite</literal> commands.
Latex-Suite provides an easy way to do this. Somewhere in the body of
the document, type in the following sentence
<programlisting>This is a reference to (\ref{}).</programlisting>
With the cursor between the <literal>{}</literal> press
<literal><F9></literal> in insert mode. Your vim session will
sprout two new windows and it should look like below:
<programlisting>
9 \begin{document}
10 +-- 4 lines: eqnarray (eqn:euler) : \label{eqn:euler}-----------------------
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
17 +-- 4 lines: eqnarray (eqn:simple) : \label{eqn:simple}---------------------
21 This is my contribution to mathematics.
22 This is a reference to (\ref{}&lt;++&gt;)&lt;++&gt;
23 \end{document}
~
~
~
test.tex [+] 22,29 Bot
test.tex|11| \label{eqn:euler}
test.tex|18| \label{eqn:simple}
~
~
~
[Error List] 1,1 All
7 \usepackage[sumlimits,]{amsmath}
8
9 \begin{document}
10 \begin{eqnarray}
11 \label{eqn:euler}
12 e^{j\pi} + 1 &=& 0
13 \end{eqnarray}
14 This is the famous euler equation. I
15 will type another equation, just as
16 true:
test.tex [Preview][+] 11,2-5 46%
</programlisting>
</para>
<imageobject>
<imagedata fileref="" format=""></imagedata>
</imageobject>
<para>
The cursor will relocate to the middle window which shows all
<literal>\label</literal>s found in all the <literal>.tex</literal> file
in the current directory.
You can scroll up and down in the middle window till you reach the
reference you want to insert. Notice how when you scroll in the
middle window, the bottom "Preview" window scrolls automatically to
show you the location of the current selection. This helps you
identify the reference with greater ease because often times,
<literal>\labels</literal> are not descriptive enough or there might be too
many of them. To insert the reference, just position the cursor on
the relevant line in the middle window and press
<literal><enter></literal>. The line which you were editing will change
to:
<programlisting>This is a reference to (\ref{eqn:euler})</programlisting>
and the bottom windows close automatically.
</para>
<para>
The <literal><F9></literal> key also works for inserting
<literal>\cite</literal> commands to reference bibliographich entries,
inserting file names for the <literal>\inputgraphics</literal> command
and just plain searching for words. Click <ulink
url="http://vim-latex.sourceforge.net/documentation/latex-suite/latex-completion.html">here</ulink>
for more information.
</para>
</section>
<section id="lsq-compiling">
<title>Compiling a document</title>
<para>
Great! We have just created a small latex file. The next step is to
make the latex compiler create a .dvi file from it. Compiling via
latex-suite is simple. Goto normal mode and press <literal>\ll</literal>
(replace <literal>\</literal> with whatever <literal>mapleader</literal> setting you
have). This will call the latex compiler. If all goes well, then
the focus should return to the vim window.
</para>
<para>
Nothing happend? Ouch! You might need to do some additional settings as
described <ulink
url="http://vim-latex.sourceforge.net/index.php?subject=faq&title=FAQ#faq-2">here.</ulink>
</para>
<section id="lsq-debugging">
<title>Debugging LaTeX source files</title>
<para>
To illustrate the debugging procedure, let's create a few mistakes
in the file. Insert the following ``mistakes'' in the file:
<programlisting>This is a $\mistake$.
And this is $\another$</programlisting>
Now press <literal>\ll</literal> again. This time you will notice that
after compilation finishes, the cursor automatically lands on
<literal>$\mistake$</literal>. In addition, 2 new windows will appear
as shown here:
</para>
<imageobject>
<imagedata fileref="" format=""></imagedata>
</imageobject>
<para>
The middle window is an <emphasis>Error List</emphasis> window
showing you the errors which the latex compiler found. Th bottom
window is a <emphasis>Log Preview</emphasis> window, which shows you
the context of the error made by displaying the relevant portion of
the <literal>.log</literal> file created during the latex
compilation procedure. Jump to the <emphasis>Error List</emphasis>
window and try scrolling around in it using either the <literal>j,
k</literal> keys or the arrow keys. You will notice that the
<emphasis>Log Preview</emphasis> window scrolls automatically to
retain the context of the error you are currently located on. If you
press <literal><enter></literal> on any line, you will see the
cursor jump to the location of the error. Latex-Suite tries to guess
the column location as best as it can so you can continue typing
straight away.
</para>
</section>
<para>
Having got a taste for compiling, proceed by deleting the erroneous
lines and re-compiling.
</para>
<para>
The Latex-Suite compiler is capable of much more including
selectively filtering out common errors which you might want to
ignore for the moment, compiling parts of a document, setting
levels of verbosity in the compiler output etc. See <ulink
url="http://vim-latex.sourceforge.net/documentation/latex-suite/latex-compiling.html">here</ulink>
for more.
</para>
</section>
<section id="lsq-viewing-dvi">
<title>Viewing DVI files</title>
<para>
Now that you have compiled your first latex source, its time to
view it. Again, this should be pretty simple. Press
<literal>\lv</literal> in normal mode. Depending on your platform, a DVI
viewer program should open up and display the dvi file generated in
compilation step previously.
</para>
<para>
Nothing happend? Ouch! You might need to do some additional settings as
described <ulink
url="http://vim-latex.sourceforge.net/index.php?subject=faq&title=FAQ#faq-3">here.</ulink>
</para>
<section id="lsq-quick-forward-searching">
<title>Performing forward searches</title>
<para>
If you are using a modern DVI viewer, then it is possible to do what
is called forward and inverse searching. However, you will need to
customize the standard Latex-Suite distribution in order to utilize
this functionality. Type in the following on the command line:
<programlisting>:let g:Tex_CompileRule_dvi = 'latex -src-specials -interaction=nonstopmode $*'
:TCTarget dvi</programlisting>
Now recompile the latex file by pressing <literal>\ll</literal>.
This time, instead of pressing <literal>\lv</literal> to view the
file, press <literal>\ls</literal> from within the tex file. If the
DVI viewer supports forward searching (most of them do), then the
viewer will actually display the portion of the DVI file
corresponding to the location where you were editing the tex file.
</para>
<note>
<para>
The reason Latex-Suite does not have this setting by default is
that on some systems this causes unpredictable results in the DVI
output. If you find the DVI output satisfactory, then you can
insert the first of the 2 lines above into your
<literal>$VIM/ftplugin/tex.vim</literal> file.
<literal>$VIM</literal> is <literal>~/vimfiles</literal> for
windows and <literal>~/.vim</literal> for *nix machines.
</para>
</note>
</section>
<section id="lsq-quick-inverse-searching">
<title>Performing inverse searches</title>
<para>
Most DVI viewers also support inverse searching, whereby you can
make the DVI viewer ask vim to display the tex source corresponding
to the DVI file being shown. This is extremeley helpful while
proofreading large documents.
</para>
<para>
Simply double-click anywhere in the viewer window. If the viewer
supports it, then it will attempt to open an editor window at the
location corresponding to where you double-clicked. On *nix
platforms, Latex-Suite attempts to start the viewer program in such
a way that it already knows to use vim to open the tex source. Thus
you should see a vim window open up showing the tex file. However,
if there is an error, or some other program is used, you will need
to tell the viewer program to use gvim as the editor. On windows
platforms, if you use the commonly available <literal>yap</literal>
viewer (available as part of the miktex distribution), then this
option can be set from <literal>View > Options > Inverse
Search</literal>. In the <literal>Command line:</literal> window,
write
<programlisting>"C:\Program Files\vim\vim61\gvim" -c ":RemoteOpen +%l %f"</programlisting>
(Customize the path according to where you have installed gvim).
If you double click in the view pane now, you will see gvim start
up and take you to the relevant portion of the tex file.
</para>
</section>
</section>
<section id="lsq-conclusions">
<title>Conclusions</title>
<para>
Thats all folks! By now, you should know enough of the basic functions
of latex-suite. Ofcourse, latex-suite is capable of much, much more such
as compiling files multiple times to resolve changed labels, compiling
dependencies, handling user packages and more. To get a feel for that,
you will need to take a look at the <ulink
url="http://vim-latex.sourceforge.net/index.php?subject=manual&title=Manual#user-manual">&ls;
user manual.</ulink>
</para>
</section>
</article>
<!--
vim: et:sw=1:ts=1
-->
|
|
From: <sri...@us...> - 2003-12-15 03:33:55
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv25158
Modified Files:
custommacros.vim main.vim packages.vim texproject.vim
Log Message:
Yet more changes in the effort to make latex-suite support file names with
spaces. A new function ``Tex_EscapeSpaces`` which escapes spaces *only if
necessary*. This function should henceforth be used whenever we want to
split a new file, save a file etc etc. Example::
exec 'split '.Tex_EscapeSpaces(filename)
Index: custommacros.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/custommacros.vim,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** custommacros.vim 14 Dec 2003 22:08:48 -0000 1.19
--- custommacros.vim 15 Dec 2003 03:33:52 -0000 1.20
***************
*** 77,81 ****
endif
endif
! exe 'split '.s:macrodirpath.newmacroname
setlocal filetype=tex
endfunction
--- 77,81 ----
endif
endif
! exec 'split '.Tex_EscapeSpaces(s:macrodirpath.newmacroname)
setlocal filetype=tex
endfunction
***************
*** 134,138 ****
if filereadable(s:macrodirpath.filename)
" If file exists in local directory open it.
! exe 'split '.s:macrodirpath.filename
else
" But if file doesn't exist in local dir it probably is in user
--- 134,138 ----
if filereadable(s:macrodirpath.filename)
" If file exists in local directory open it.
! exec 'split '.Tex_EscapeSpaces(s:macrodirpath.filename)
else
" But if file doesn't exist in local dir it probably is in user
***************
*** 152,156 ****
\ "&Open\nOver&write\n&Cancel", 1)
if ch == 1
! exe 'split '.s:macrodirpath.filename.'-local'
elseif ch == 2
new
--- 152,156 ----
\ "&Open\nOver&write\n&Cancel", 1)
if ch == 1
! exec 'split '.Tex_EscapeSpaces(s:macrodirpath.filename.'-local')
elseif ch == 2
new
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.57
retrieving revision 1.58
diff -C2 -d -r1.57 -r1.58
*** main.vim 15 Dec 2003 00:53:27 -0000 1.57
--- main.vim 15 Dec 2003 03:33:52 -0000 1.58
***************
*** 592,596 ****
\ . pattern.' : '.a:str."\n"
! " exec '!echo '.pattern.' : '.a:str.' >> /tmp/ls.log'
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
--- 592,598 ----
\ . pattern.' : '.a:str."\n"
! redir! >> /tmp/ls.log
! silent! echo pattern.' : '.a:str
! redir END
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
***************
*** 642,646 ****
let filelist = globpath(&rtp, 'ftplugin/latex-suite/'.a:directory.'/'.pattern)."\n"
- call Tex_Debug("filelist = ".filelist, "main")
if filelist == "\n"
--- 644,647 ----
***************
*** 716,720 ****
" " Description:
function! Tex_CD(dirname)
! exec 'cd '.escape(a:dirname, ' ')
endfunction " }}}
--- 717,726 ----
" " Description:
function! Tex_CD(dirname)
! exec 'cd '.Tex_EscapeSpaces(a:dirname)
! endfunction " }}}
! " Tex_EscapeSpaces: escapes unescaped spaces from a path name {{{
! " Description:
! function! Tex_EscapeSpaces(path)
! return substitute(a:path, '[^\\]\(\\\\\)*\zs ', '\\ ', 'g')
endfunction " }}}
Index: packages.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -d -r1.43 -r1.44
*** packages.vim 14 Dec 2003 07:22:16 -0000 1.43
--- packages.vim 15 Dec 2003 03:33:52 -0000 1.44
***************
*** 116,120 ****
" Find out which file we need to scan.
! let fname = escape(Tex_GetMainFileName(':p'), ' ')
" If this is the same as last time, don't repeat.
--- 116,120 ----
" Find out which file we need to scan.
! let fname = Tex_GetMainFileName(':p')
" If this is the same as last time, don't repeat.
***************
*** 139,144 ****
let g:Tex_PromptedCommands = g:Tex_PromptedCommandsDefault
! call Tex_ScanForPackages(fname)
! call Tex_Debug('updateall: detected ['.g:Tex_package_detected.'] in first run', 'pack')
" Now for each package find out if this is a custom package and if so,
--- 139,148 ----
let g:Tex_PromptedCommands = g:Tex_PromptedCommandsDefault
! call Tex_Debug(':Tex_pack_updateall: split '.Tex_EscapeSpaces(fname), 'pack')
! exe 'split '.Tex_EscapeSpaces(fname)
! call Tex_ScanForPackages()
! q
!
! call Tex_Debug(':Tex_pack_updateall: detected ['.g:Tex_package_detected.'] in first run', 'pack')
" Now for each package find out if this is a custom package and if so,
***************
*** 164,168 ****
while packname != ''
! call Tex_Debug('scanning package '.packname, 'pack')
" Scan this package only if we have not scanned it before in this
--- 168,172 ----
while packname != ''
! call Tex_Debug(':Tex_pack_updateall: scanning package '.packname, 'pack')
" Scan this package only if we have not scanned it before in this
***************
*** 171,175 ****
let i = i + 1
! call Tex_Debug(packname.' already scanned', 'pack')
let packname = Tex_Strntok(g:Tex_package_detected, ',', i)
continue
--- 175,179 ----
let i = i + 1
! call Tex_Debug(':Tex_pack_updateall: '.packname.' already scanned', 'pack')
let packname = Tex_Strntok(g:Tex_package_detected, ',', i)
continue
***************
*** 181,188 ****
split
! call Tex_Debug('silent! find '.packname.'.sty', 'pack')
let thisbufnum = bufnr('%')
! exec 'silent! find '.packname.'.sty'
! call Tex_Debug('present file = '.bufname('%'), 'pack')
" If this file was not found, assume that it means its not a
--- 185,192 ----
split
! call Tex_Debug(':Tex_pack_updateall: silent! find '.Tex_EscapeSpaces(packname).'.sty', 'pack')
let thisbufnum = bufnr('%')
! exec 'silent! find '.Tex_EscapeSpaces(packname).'.sty'
! call Tex_Debug(':Tex_pack_updateall: present file = '.bufname('%'), 'pack')
" If this file was not found, assume that it means its not a
***************
*** 194,198 ****
q
! call Tex_Debug(packname.' not found anywhere', 'pack')
let i = i + 1
let packname = Tex_Strntok(g:Tex_package_detected, ',', i)
--- 198,202 ----
q
! call Tex_Debug(':Tex_pack_updateall: '.packname.' not found anywhere', 'pack')
let i = i + 1
let packname = Tex_Strntok(g:Tex_package_detected, ',', i)
***************
*** 205,211 ****
let &complete = &complete.'s'.packpath
! call Tex_Debug('found custom package '.packpath, 'pack')
! call Tex_ScanForPackages(packpath, line('$'), line('$'))
! call Tex_Debug('After scanning, g:Tex_package_detected = '.g:Tex_package_detected, 'pack')
let scannedPackages = scannedPackages.','.packname
--- 209,215 ----
let &complete = &complete.'s'.packpath
! call Tex_Debug(':Tex_pack_updateall: found custom package '.packpath, 'pack')
! call Tex_ScanForPackages(line('$'), line('$'))
! call Tex_Debug(':Tex_pack_updateall: After scanning, g:Tex_package_detected = '.g:Tex_package_detected, 'pack')
let scannedPackages = scannedPackages.','.packname
***************
*** 248,252 ****
--- 252,259 ----
" Throw an event that we are done scanning packages. Some packages might
" use this to change behavior based on which options have been used etc.
+ call Tex_Debug(":Tex_pack_updateall: throwing LatexSuiteScannedPackages event", "pack")
silent! do LatexSuite User LatexSuiteScannedPackages
+
+ call Tex_Debug("-Tex_pack_updateall", "pack")
endfunction
***************
*** 298,311 ****
" \newcommand lines and adds names to g:Tex_Prompted variables, they can be
" easy available through <F5> and <F7> shortcuts
! function! Tex_ScanForPackages(fname, ...)
! let pos = line('.').' | normal! '.virtcol('.').'|'
! let currfile = escape(expand('%:p'), ' ')
! call Tex_Debug('currfile = '.currfile.', a:fname = '.a:fname, 'pack')
! let toquit = 0
! if a:fname != currfile
! exe 'split '.a:fname
! let toquit = 1
! endif
" For package files without \begin and \end{document}, we might be told to
--- 305,312 ----
" \newcommand lines and adds names to g:Tex_Prompted variables, they can be
" easy available through <F5> and <F7> shortcuts
! function! Tex_ScanForPackages(...)
! call Tex_Debug("+Tex_ScanForPackages", "pack")
! let pos = line('.').' | normal! '.virtcol('.').'|'
" For package files without \begin and \end{document}, we might be told to
***************
*** 320,324 ****
let endline = a:2
endif
! call Tex_Debug('beginline = '.beginline.', endline = '.endline, 'pack')
--- 321,326 ----
let endline = a:2
endif
!
! call Tex_Debug(":Tex_ScanForPackages: Begining scans in [".bufname('%')."], beginline = ".beginline, "pack")
***************
*** 330,333 ****
--- 332,336 ----
let v:errmsg = erm
+ call Tex_Debug(":Tex_ScanForPackages: beginning scan for \\usepackage lines", "pack")
" The wrap trick enables us to match \usepackage on the first line as
" well.
***************
*** 336,340 ****
let wrap = 'W'
- call Tex_Debug('finding package on '.line('.'), 'pack')
if line('.') > beginline
break
--- 339,342 ----
***************
*** 389,395 ****
--- 391,400 ----
let @a = substitute(@a, ',', '","', 'g')
+ call Tex_Debug(":Tex_ScanForPackages: found package(s) [".@a."] on line ".line('.'), "pack")
+
" restore @a
let @a = saveA
endwhile
+ call Tex_Debug(":Tex_ScanForPackages: End scan \\usepackage, detected packages = ".g:Tex_package_detected, "pack")
" TODO: This needs to be changed. In the future, we might have
***************
*** 404,407 ****
--- 409,413 ----
let g:Tex_package_detected = substitute(g:Tex_package_detected, '^,', '', '')
+ call Tex_Debug(":Tex_ScanForPackages: Beginning scan for \\newcommand's", "pack")
" Scans whole file (up to \end{document}) for \newcommand and adds this
" commands to g:Tex_PromptedCommands variable, it is easily available
***************
*** 423,427 ****
" through <F5>
0
! call Tex_Debug('looking for newenvironments in '.bufname('%'), 'pack')
while search('^\s*\\newenvironment\*\?{.\{-}}', 'W')
--- 429,433 ----
" through <F5>
0
! call Tex_Debug(":Tex_ScanForPackages: Beginning scan for \\newenvironment's", 'pack')
while search('^\s*\\newenvironment\*\?{.\{-}}', 'W')
***************
*** 437,445 ****
endwhile
- if toquit
- call Tex_Debug("quitting from ".bufname('%'), "pack")
- q
- endif
-
exe pos
" first make a random search so that we push at least one item onto the
--- 443,446 ----
***************
*** 450,453 ****
--- 451,456 ----
" now delete it...
call histdel('/', -1)
+
+ call Tex_Debug("-Tex_ScanForPackages", "pack")
endfunction
***************
*** 458,462 ****
function! Tex_pack_supp_menu()
let suplist = Tex_FindInRtp('', 'packages')
- call Tex_Debug("suplist = [".suplist.']', "pack")
call Tex_MakeSubmenu(suplist, g:Tex_PackagesMenuLocation.'Supported.',
--- 461,464 ----
Index: texproject.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texproject.vim,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** texproject.vim 14 Dec 2003 07:23:55 -0000 1.4
--- texproject.vim 15 Dec 2003 03:33:52 -0000 1.5
***************
*** 25,32 ****
let mainfname = Tex_GetMainFileName()
if glob(mainfname.'.latexmain') != ''
! exe 'split '.mainfname.'.latexmain'
else
! exe 'split '.escape(s:path.'/projecttemplate.vim', ' ')
! exe 'saveas '.escape(file.'.latexmain', ' ')
let g:Tex_ProjectExists = 1
endif
--- 25,32 ----
let mainfname = Tex_GetMainFileName()
if glob(mainfname.'.latexmain') != ''
! exec 'split '.Tex_EscapeSpaces(mainfname.'.latexmain')
else
! exec 'split '.Tex_EscapeSpaces(s:path.'/projecttemplate.vim')
! exec 'saveas '.Tex_EscapeSpaces(file.'.latexmain')
let g:Tex_ProjectExists = 1
endif
|
|
From: <sri...@us...> - 2003-12-15 00:55:29
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv31913
Modified Files:
texviewer.vim
Log Message:
modifications to account for the changes in Tex_EscapeForGrep().
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.34
retrieving revision 1.35
diff -C2 -d -r1.34 -r1.35
*** texviewer.vim 14 Dec 2003 23:31:10 -0000 1.34
--- texviewer.vim 15 Dec 2003 00:55:26 -0000 1.35
***************
*** 76,81 ****
if exists("s:type") && s:type =~ 'ref'
! call Tex_Debug("silent! grep! ".Tex_EscapeForGrep('\label{'.s:prefix)." *.tex", 'view')
! exec "silent! grep! ".Tex_EscapeForGrep('\label{'.s:prefix)." *.tex"
redraw!
call <SID>Tex_SetupCWindow()
--- 76,81 ----
if exists("s:type") && s:type =~ 'ref'
! call Tex_Debug("silent! grep! ".Tex_EscapeForGrep('\\label{'.s:prefix)." *.tex", 'view')
! exec "silent! grep! ".Tex_EscapeForGrep('\\label{'.s:prefix)." *.tex"
redraw!
call <SID>Tex_SetupCWindow()
***************
*** 132,136 ****
else
! let s:word = matchstr(s:curline, '\zs\k\{-}$')
if s:word == ''
if col('.') == strlen(getline('.'))
--- 132,136 ----
else
! let s:word = expand('<cword>')
if s:word == ''
if col('.') == strlen(getline('.'))
***************
*** 143,148 ****
endif
endif
! call Tex_Debug("silent! grep! '\\<".s:word."' *.tex", 'view')
! exe "silent! grep! '\\<".s:word."' *.tex"
call <SID>Tex_SetupCWindow()
--- 143,148 ----
endif
endif
! call Tex_Debug("silent! grep! ".Tex_EscapeForGrep('\<'.s:word.'\>')." *.tex", 'view')
! exec "silent! grep! ".Tex_EscapeForGrep('\<'.s:word.'\>')." *.tex"
call <SID>Tex_SetupCWindow()
***************
*** 151,166 ****
elseif a:where == 'tex'
" Process :TLook command
! exe "silent! grep! '".a:what."' *.tex"
call <SID>Tex_SetupCWindow()
elseif a:where == 'bib'
" Process :TLookBib command
! exe "silent! grep! '".a:what."' *.bib"
! exe "silent! grepadd! '".a:what."' *.bbl"
call <SID>Tex_SetupCWindow()
elseif a:where == 'all'
" Process :TLookAll command
! exe "silent! grep! '".a:what."' *"
call <SID>Tex_SetupCWindow()
endif
--- 151,166 ----
elseif a:where == 'tex'
" Process :TLook command
! exe "silent! grep! ".Tex_EscapeForGrep(a:what)." *.tex"
call <SID>Tex_SetupCWindow()
elseif a:where == 'bib'
" Process :TLookBib command
! exe "silent! grep! ".Tex_EscapeForGrep(a:what)." *.bib"
! exe "silent! grepadd! ".Tex_EscapeForGrep(a:what)." *.bbl"
call <SID>Tex_SetupCWindow()
elseif a:where == 'all'
" Process :TLookAll command
! exe "silent! grep! ".Tex_EscapeForGrep(a:what)." *"
call <SID>Tex_SetupCWindow()
endif
***************
*** 538,542 ****
call Tex_Debug('finding .bbl file ['.bufname('.').']', 'bib')
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\bibitem{'.a:prefix)." %"
endif
endif
--- 538,542 ----
call Tex_Debug('finding .bbl file ['.bufname('.').']', 'bib')
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\\bibitem{'.a:prefix)." %"
endif
endif
***************
*** 562,566 ****
split
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\bibitem{'.a:prefix)." %")
q
--- 562,567 ----
split
lcd %:p:h
! call Tex_Debug("silent! grepadd ".Tex_EscapeForGrep('\\bibitem{'.a:prefix)." %", 'view')
! exec "silent! grepadd ".Tex_EscapeForGrep('\\bibitem{'.a:prefix)." %"
q
|
|
From: <sri...@us...> - 2003-12-15 00:53:31
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv31508
Modified Files:
main.vim
Log Message:
Change: Initially, Tex_EscapeForGrep would always double backslashes at
least once to account for the fact that the user means the external
grep command to see the string ``\\label`` when he passes
``\label`` to this function. But making such guesses is bad for
cases when we want to pass a single ``\`` to the external grep
command (for instance when we want to pass ``\<word\>`` to the
external grep command). Therefore, stop this function from making
any guesses about what the user might have wanted the external
command to see. This function now expects the user to pass the
exact string which he wants the external grep command to see.
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.56
retrieving revision 1.57
diff -C2 -d -r1.56 -r1.57
*** main.vim 14 Dec 2003 23:31:10 -0000 1.56
--- main.vim 15 Dec 2003 00:53:27 -0000 1.57
***************
*** 531,555 ****
let s:incnum = a:val
endfunction " }}}
! " Tex_EscapeForGrep: escapes \ and " the correct number of times {{{
" Description: This command escapes the backslash and double quotes in a
! " search pattern the correct number of times so it can be used in the :grep
! " command. This command is meant to be used as:
" exec "silent! grep ".Tex_EscapeForGrep(pattern)." file"
function! Tex_EscapeForGrep(string)
! " This first escaping is so that grep gets a string like '\\bibitem' when
! " we want to search for a string like '\bibitem'.
! let retVal = escape(a:string, "\\")
! " The next escape is because when the shellxquote is ", then the grep
! " commad is usually called as
! " bash -c "grep pattern filename"
! " which means that we need to escape backslashes (because they get halved)
! " and also double quotes.
if &shell =~ 'sh'
let retVal = escape(retVal, "\\")
if &shellxquote == '"'
let retVal = escape(retVal, "\"\\")
endif
endif
return retVal
--- 531,566 ----
let s:incnum = a:val
endfunction " }}}
! " Tex_EscapeForGrep: escapes back-slashes and doublequotes the correct number of times {{{
" Description: This command escapes the backslash and double quotes in a
! " search pattern the correct number of times so it can be used in the ``:grep``
! " command. This command is meant to be used as::
! "
" exec "silent! grep ".Tex_EscapeForGrep(pattern)." file"
+ "
+ " The input argument to this function should be the string which you want
+ " the external command to finally see. For example, to search for a string
+ " ``'\bibitem'``, the grep command needs to be passed a string like
+ " ``'\\bibitem'``. Examples::
+ "
+ " Tex_EscapeForGrep('\\bibitem') " correct
+ " Tex_EscapeForGrep('\bibitem') " wrong
+ " Tex_EscapeForGrep("\\bibitem") " wrong
+ " Tex_EscapeForGrep('\<word\>') " correct
+ "
function! Tex_EscapeForGrep(string)
! let retVal = a:string
! " The shell halves the backslashes.
if &shell =~ 'sh'
let retVal = escape(retVal, "\\")
+
+ " If shellxquote is set, then the backslashes are halved yet again.
if &shellxquote == '"'
let retVal = escape(retVal, "\"\\")
endif
+
endif
+ " escape special characters which bash/cmd.exe might interpret
+ let retVal = escape(retVal, "<>")
return retVal
|
|
From: <sri...@us...> - 2003-12-14 23:31:13
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv17343/latex-suite
Modified Files:
main.vim
Log Message:
Change: Making Tex_EscapeForGrep more cross-platform. Use this henceforth
whenever a :grep command needs to be issued.
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.55
retrieving revision 1.56
diff -C2 -d -r1.55 -r1.56
*** main.vim 14 Dec 2003 07:13:44 -0000 1.55
--- main.vim 14 Dec 2003 23:31:10 -0000 1.56
***************
*** 535,545 ****
" search pattern the correct number of times so it can be used in the :grep
" command. This command is meant to be used as:
! " exec "silent! grep '".Tex_EscapeForGrep(pattern)."' file"
! " NOTE: The pattern in the grep command should _always_ be enclosed in
! " single quotes (not double quotes) for robust performance.
function! Tex_EscapeForGrep(string)
" This first escaping is so that grep gets a string like '\\bibitem' when
" we want to search for a string like '\bibitem'.
let retVal = escape(a:string, "\\")
" The next escape is because when the shellxquote is ", then the grep
" commad is usually called as
--- 535,544 ----
" search pattern the correct number of times so it can be used in the :grep
" command. This command is meant to be used as:
! " exec "silent! grep ".Tex_EscapeForGrep(pattern)." file"
function! Tex_EscapeForGrep(string)
" This first escaping is so that grep gets a string like '\\bibitem' when
" we want to search for a string like '\bibitem'.
let retVal = escape(a:string, "\\")
+
" The next escape is because when the shellxquote is ", then the grep
" commad is usually called as
***************
*** 547,553 ****
" which means that we need to escape backslashes (because they get halved)
" and also double quotes.
! if &shellxquote == '"'
! let retVal = escape(retVal, "\"\\")
endif
return retVal
endfunction " }}}
--- 546,556 ----
" which means that we need to escape backslashes (because they get halved)
" and also double quotes.
! if &shell =~ 'sh'
! let retVal = escape(retVal, "\\")
! if &shellxquote == '"'
! let retVal = escape(retVal, "\"\\")
! endif
endif
+
return retVal
endfunction " }}}
|
|
From: <sri...@us...> - 2003-12-14 23:31:13
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/tex
In directory sc8-pr-cvs1:/tmp/cvs-serv17343/tex
Modified Files:
texviewer.vim
Log Message:
Change: Making Tex_EscapeForGrep more cross-platform. Use this henceforth
whenever a :grep command needs to be issued.
Index: texviewer.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/tex/texviewer.vim,v
retrieving revision 1.33
retrieving revision 1.34
diff -C2 -d -r1.33 -r1.34
*** texviewer.vim 26 Nov 2003 11:19:01 -0000 1.33
--- texviewer.vim 14 Dec 2003 23:31:10 -0000 1.34
***************
*** 76,81 ****
if exists("s:type") && s:type =~ 'ref'
! call Tex_Debug("silent! grep! '".Tex_EscapeForGrep('\label{'.s:prefix)."' *.tex", 'view')
! exec "silent! grep! '".Tex_EscapeForGrep('\label{'.s:prefix)."' *.tex"
redraw!
call <SID>Tex_SetupCWindow()
--- 76,81 ----
if exists("s:type") && s:type =~ 'ref'
! call Tex_Debug("silent! grep! ".Tex_EscapeForGrep('\label{'.s:prefix)." *.tex", 'view')
! exec "silent! grep! ".Tex_EscapeForGrep('\label{'.s:prefix)." *.tex"
redraw!
call <SID>Tex_SetupCWindow()
***************
*** 530,534 ****
lcd %:p:h
" use the appropriate syntax for the .bib file.
! exec "silent! grepadd '".Tex_EscapeForGrep('@.*{'.a:prefix)."' %"
else
let thisbufnum = bufnr('%')
--- 530,534 ----
lcd %:p:h
" use the appropriate syntax for the .bib file.
! exec "silent! grepadd ".Tex_EscapeForGrep('@.*{'.a:prefix)." %"
else
let thisbufnum = bufnr('%')
***************
*** 538,542 ****
call Tex_Debug('finding .bbl file ['.bufname('.').']', 'bib')
lcd %:p:h
! exec "silent! grepadd '".Tex_EscapeForGrep('\bibitem{'.a:prefix)."' %"
endif
endif
--- 538,542 ----
call Tex_Debug('finding .bbl file ['.bufname('.').']', 'bib')
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\bibitem{'.a:prefix)." %"
endif
endif
***************
*** 562,566 ****
split
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\bibitem{'.a:prefix)."' %")
q
--- 562,566 ----
split
lcd %:p:h
! exec "silent! grepadd ".Tex_EscapeForGrep('\bibitem{'.a:prefix)." %")
q
|
|
From: <sri...@us...> - 2003-12-14 22:08:51
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite In directory sc8-pr-cvs1:/tmp/cvs-serv1291 Modified Files: custommacros.vim Log Message: Index: custommacros.vim =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/custommacros.vim,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** custommacros.vim 29 Sep 2003 03:55:24 -0000 1.18 --- custommacros.vim 14 Dec 2003 22:08:48 -0000 1.19 *************** *** 4,8 **** " Version: 1.0 " Created: Tue Apr 23 05:00 PM 2002 PST ! " CVS: $Id$ " " Description: functions for processing custom macros in the --- 4,8 ---- " Version: 1.0 " Created: Tue Apr 23 05:00 PM 2002 PST ! " CVS: $Id$ " " Description: functions for processing custom macros in the |
|
From: <sri...@us...> - 2003-12-14 09:38:52
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv3973
Modified Files:
main.vim
Log Message:
A serious attempt at fixing the file names with spaces problems across
various platforms.
Change: Tex_GetMainFileName now applies the file name modifier to the
filename after removing the trailing .latexmain part if it exists.
Bug: Tex_FindInRtp would return a non-empty string even if a filename is
not found in the &rtp.
New: A trivial function Tex_CD() which just escapes spaces in the directory
name before cd'ing to it.
Use this function henceforth whenever you want to cd to another
directory instead of the
exec 'cd '.dirname
routine.
TODO: Maybe make this robust to detect previous attempts at escaping
spaces and if so, /not/ escape it again.
Index: main.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/main.vim,v
retrieving revision 1.54
retrieving revision 1.55
diff -C2 -d -r1.54 -r1.55
*** main.vim 30 Nov 2003 09:48:08 -0000 1.54
--- main.vim 14 Dec 2003 07:13:44 -0000 1.55
***************
*** 409,423 ****
endif
endfunction " }}}
! " Tex_GetMainFileName: gets the name (without extension) of the main file being compiled. {{{
! " Description: returns '' if .latexmain doesnt exist.
! " i.e if main.tex.latexmain exists, then returns:
! " d:/path/to/main
! " if a:1 is supplied, then it is used to modify the *.latexmain
! " file instead of using ':p:r:r'.
function! Tex_GetMainFileName(...)
if a:0 > 0
let modifier = a:1
else
! let modifier = ':p:r:r'
endif
--- 409,432 ----
endif
endfunction " }}}
! " Tex_GetMainFileName: gets the name of the main file being compiled. {{{
! " Description: returns the full path name of the main file.
! " This function checks for the existence of a .latexmain file
! " which might point to the location of a "main" latex file.
! " If .latexmain exists, then return the full path name of the
! " file being pointed to by it.
! "
! " Otherwise, return the full path name of the current buffer.
! "
! " You can supply an optional "modifier" argument to the
! " function, which will optionally modify the file name before
! " returning.
! " NOTE: From version 1.6 onwards, this function always trims
! " away the .latexmain part of the file name before applying the
! " modifier argument.
function! Tex_GetMainFileName(...)
if a:0 > 0
let modifier = a:1
else
! let modifier = ':p'
endif
***************
*** 433,438 ****
let dirmodifier = '%:p:h'
let dirLast = expand(dirmodifier)
! " escape spaces whenever we use cd (diego Caraffini)
! exe 'cd '.escape(dirLast, ' ')
" move up the directory tree until we find a .latexmain file.
--- 442,446 ----
let dirmodifier = '%:p:h'
let dirLast = expand(dirmodifier)
! call Tex_CD(dirLast)
" move up the directory tree until we find a .latexmain file.
***************
*** 446,460 ****
endif
let dirLast = expand(dirmodifier)
! exec 'cd '.escape(dirLast, ' ')
endwhile
let lheadfile = glob('*.latexmain')
if lheadfile != ''
! let lheadfile = fnamemodify(lheadfile, modifier)
endif
! exe 'cd '.escape(curd, ' ')
! return escape(lheadfile, ' ')
endfunction
--- 454,478 ----
endif
let dirLast = expand(dirmodifier)
! call Tex_CD(dirLast)
endwhile
let lheadfile = glob('*.latexmain')
if lheadfile != ''
! " Remove the trailing .latexmain part of the filename... We never want
! " that.
! let lheadfile = fnamemodify(substitute(lheadfile, '\.latexmain$', '', ''), modifier)
! else
! " If we cannot find any main file, just modify the filename of the
! " current buffer.
! let lheadfile = expand('%'.modifier)
endif
! call Tex_CD(curd)
! " NOTE: The caller of this function needs to escape spaces in the
! " file name as appropriate. The reason its not done here is that
! " escaping spaces is not safe if this file is to be used as part of
! " an external command on certain platforms.
! return lheadfile
endfunction
***************
*** 525,531 ****
let retVal = escape(a:string, "\\")
" The next escape is because when the shellxquote is ", then the grep
! " commad is usually called as bash -c "grep pattern filename" which means
! " that we need to escape backslashes (because they get halved) and also
! " double quotes.
if &shellxquote == '"'
let retVal = escape(retVal, "\"\\")
--- 543,550 ----
let retVal = escape(a:string, "\\")
" The next escape is because when the shellxquote is ", then the grep
! " commad is usually called as
! " bash -c "grep pattern filename"
! " which means that we need to escape backslashes (because they get halved)
! " and also double quotes.
if &shellxquote == '"'
let retVal = escape(retVal, "\"\\")
***************
*** 557,561 ****
let s:debugString_ = (exists('s:debugString_') ? s:debugString_ : '')
! \ . a:str."\n"
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
--- 576,582 ----
let s:debugString_ = (exists('s:debugString_') ? s:debugString_ : '')
! \ . pattern.' : '.a:str."\n"
!
! " exec '!echo '.pattern.' : '.a:str.' >> /tmp/ls.log'
endfunction " }}}
" Tex_PrintDebug: prings s:debugString {{{
***************
*** 608,612 ****
let filelist = globpath(&rtp, 'ftplugin/latex-suite/'.a:directory.'/'.pattern)."\n"
call Tex_Debug("filelist = ".filelist, "main")
! if filelist == ''
return ''
endif
--- 629,634 ----
let filelist = globpath(&rtp, 'ftplugin/latex-suite/'.a:directory.'/'.pattern)."\n"
call Tex_Debug("filelist = ".filelist, "main")
!
! if filelist == "\n"
return ''
endif
***************
*** 677,680 ****
--- 699,707 ----
endif
endfunction " }}}
+ " Tex_CD: cds to given directory escaping spaces if necessary {{{
+ " " Description:
+ function! Tex_CD(dirname)
+ exec 'cd '.escape(a:dirname, ' ')
+ endfunction " }}}
" source texproject.vim before other files
***************
*** 704,707 ****
--- 731,735 ----
endif
+
" ==============================================================================
" Finally set up the folding, options, mappings and quit.
***************
*** 717,721 ****
exe 'setlocal dict+='.s:path.'/dictionaries/dictionary'
! call Tex_Debug('SetTeXOptions: sourcing maps')
" smart functions
if g:Tex_SmartKeyQuote
--- 745,749 ----
exe 'setlocal dict+='.s:path.'/dictionaries/dictionary'
! call Tex_Debug('SetTeXOptions: sourcing maps', 'main')
" smart functions
if g:Tex_SmartKeyQuote
***************
*** 738,742 ****
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('main.vim: Catching LatexSuiteFileType event') |
\ call <SID>SetTeXOptions()
augroup END
--- 766,770 ----
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('main.vim: Catching LatexSuiteFileType event', 'main') |
\ call <SID>SetTeXOptions()
augroup END
***************
*** 889,892 ****
--- 917,921 ----
" }}}
+
let &cpo = s:save_cpo
***************
*** 897,900 ****
--- 926,930 ----
exec 'pyfile '.expand('<sfile>:p:h').'/pytools.py'
+
" vim:fdm=marker:ff=unix:noet:ts=4:sw=4:nowrap
|
|
From: <sri...@us...> - 2003-12-14 09:38:45
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv9042
Modified Files:
latex-suite.txt
Log Message:
Index: latex-suite.txt
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.txt,v
retrieving revision 1.51
retrieving revision 1.52
diff -C2 -d -r1.51 -r1.52
*** latex-suite.txt 2 Dec 2003 12:00:22 -0000 1.51
--- latex-suite.txt 14 Dec 2003 07:25:04 -0000 1.52
***************
*** 1802,1806 ****
This entry defines which sections will be folded. This setting is a comma
seperated list of section names. The default value is: >
! slide,part,chapter,section,%%fakesection,
subsection,subsubsection,paragraph
Each of the entries in the list will fold up a section of the corresponding
--- 1802,1806 ----
This entry defines which sections will be folded. This setting is a comma
seperated list of section names. The default value is: >
! part,chapter,section,%%fakesection,
subsection,subsubsection,paragraph
Each of the entries in the list will fold up a section of the corresponding
***************
*** 1835,1839 ****
This entry defines which commands will be folded. It is a comma seperated string
! of words each of which defines a single command. The defualt setting is empty,
i.e no commands are folded. The words need not be standard Latex commands. You
can use whatever words you like. Each word will fold all commands whose name
--- 1835,1839 ----
This entry defines which commands will be folded. It is a comma seperated string
! of words each of which defines a single command. The default setting is empty,
i.e no commands are folded. The words need not be standard Latex commands. You
can use whatever words you like. Each word will fold all commands whose name
|
|
From: <sri...@us...> - 2003-12-14 09:18:14
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8855
Modified Files:
texproject.vim
Log Message:
Changes to account for the changes in Tex_GetMainFileName()
Index: texproject.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/texproject.vim,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** texproject.vim 25 Jul 2003 01:21:26 -0000 1.3
--- texproject.vim 14 Dec 2003 07:23:55 -0000 1.4
***************
*** 23,28 ****
let file = expand("%:p")
! if Tex_GetMainFileName() != ''
! exe 'split '.Tex_GetMainFileName(":p")
else
exe 'split '.escape(s:path.'/projecttemplate.vim', ' ')
--- 23,29 ----
let file = expand("%:p")
! let mainfname = Tex_GetMainFileName()
! if glob(mainfname.'.latexmain') != ''
! exe 'split '.mainfname.'.latexmain'
else
exe 'split '.escape(s:path.'/projecttemplate.vim', ' ')
***************
*** 37,43 ****
function! s:Tex_ProjectWrite()
! if expand("%") =~ 'latexmain$'
write!
! exe 'source '.Tex_GetMainFileName(":p")
q
else
--- 38,44 ----
function! s:Tex_ProjectWrite()
! if expand("%:e") =~ 'latexmain$'
write!
! source %
q
else
***************
*** 64,69 ****
" Load project file if exists
! if Tex_GetMainFileName() != '' && Tex_GetMainFileName(':e') == 'latexmain'
! exe 'source '.Tex_GetMainFileName(":p")
let g:Tex_ProjectExists = 1
else
--- 65,70 ----
" Load project file if exists
! if glob(Tex_GetMainFileName().'.latexmain') != ''
! exe 'source '.Tex_GetMainFileName().'.latexmain'
let g:Tex_ProjectExists = 1
else
|
|
From: <sri...@us...> - 2003-12-14 09:18:03
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8076
Modified Files:
compiler.vim
Log Message:
Attempting to fix the filenames with spaces problem. Also since
Tex_GetMainFileName() _always_ returns a file name now, (even if a
.latexmain file does not exist), lots of redundant logic is now removed.
Index: compiler.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/compiler.vim,v
retrieving revision 1.57
retrieving revision 1.58
diff -C2 -d -r1.57 -r1.58
*** compiler.vim 2 Dec 2003 11:38:19 -0000 1.57
--- compiler.vim 14 Dec 2003 07:17:16 -0000 1.58
***************
*** 97,116 ****
pclose!
! " Logic to choose how to compile:
! " if b:fragmentFile exists, then this is a fragment
! " therefore, just compile this file
! " else
! " if makefile or Makefile exists, then use that
! " elseif *.latexmain exists
! " use that
! " else use current file
! "
! " if mainfname exists, then it means it was supplied to Tex_RunLaTeX().
! " Extract the complete file name including the extension.
! let mainfname = Tex_GetMainFileName(':r')
call Tex_Debug('Tex_CompileLatex: getting mainfname = ['.mainfname.'] from Tex_GetMainFileName', 'comp')
- if exists('b:fragmentFile') || mainfname == ''
- let mainfname = escape(expand('%:t'), ' ')
- endif
" if a makefile exists and the user wants to use it, then use that
--- 97,117 ----
pclose!
! let curd = getcwd()
!
! " Find the main file corresponding to this file. Always cd to the
! " directory containing the file to avoid problems with the directory
! " containing spaces.
! " Latex on linux seems to be unable to handle file names with spaces at
! " all! Therefore for the moment, do not attempt to handle spaces in the
! " file name.
! if exists('b:fragmentFile')
! let mainfname = expand('%:p:t')
! call Tex_CD(expand('%:p:h')
! else
! let mainfname = Tex_GetMainFileName(':p:t')
! call Tex_CD(Tex_GetMainFileName(':p:h'))
! end
!
call Tex_Debug('Tex_CompileLatex: getting mainfname = ['.mainfname.'] from Tex_GetMainFileName', 'comp')
" if a makefile exists and the user wants to use it, then use that
***************
*** 139,150 ****
endif
redraw!
endfunction " }}}
" Tex_SetupErrorWindow: sets up the cwindow and preview of the .log file {{{
" Description:
function! Tex_SetupErrorWindow()
! let mainfname = Tex_GetMainFileName(':r')
! if exists('b:fragmentFile') || mainfname == ''
! let mainfname = expand('%:t')
! endif
let winnum = winnr()
--- 140,150 ----
endif
redraw!
+
+ call Tex_CD(curd)
endfunction " }}}
" Tex_SetupErrorWindow: sets up the cwindow and preview of the .log file {{{
" Description:
function! Tex_SetupErrorWindow()
! let mainfname = Tex_GetMainFileName()
let winnum = winnr()
***************
*** 194,198 ****
let dir = expand("%:p:h").'/'
let curd = getcwd()
! exec 'cd '.expand("%:p:h")
" first get the dependency chain of this format.
--- 194,198 ----
let dir = expand("%:p:h").'/'
let curd = getcwd()
! call Tex_CD(expand("%:p:h"))
" first get the dependency chain of this format.
***************
*** 216,221 ****
--- 216,223 ----
if g:Tex_MultipleCompileFormats =~ '\<'.s:target.'\>'
+ call Tex_Debug("compiling file multiple times via Tex_CompileMultipleTimes", "comp")
call Tex_CompileMultipleTimes()
else
+ call Tex_Debug("compiling file once via Tex_CompileLatex", "comp")
call Tex_CompileLatex()
endif
***************
*** 233,237 ****
call Tex_SetupErrorWindow()
! exec 'cd '.curd
endfunction
--- 235,239 ----
call Tex_SetupErrorWindow()
! call Tex_CD(curd)
endfunction
***************
*** 250,264 ****
end
- let dir = expand("%:p:h").'/'
let curd = getcwd()
- exec 'cd '.expand("%:p:h")
" If b:fragmentFile is set, it means this file was compiled as a fragment
" using Tex_PartCompile, which means that we want to ignore any
" *.latexmain or makefile's.
! if Tex_GetMainFileName() != '' && !exists('b:fragmentFile')
! let mainfname = Tex_GetMainFileName()
else
let mainfname = expand("%:p:t:r")
endif
--- 252,268 ----
end
let curd = getcwd()
" If b:fragmentFile is set, it means this file was compiled as a fragment
" using Tex_PartCompile, which means that we want to ignore any
" *.latexmain or makefile's.
! if !exists('b:fragmentFile')
! " cd to the location of the file to avoid having to deal with spaces
! " in the directory name.
! let mainfname = Tex_GetMainFileName(':p:t:r')
! call Tex_CD(Tex_GetMainFileName(':p:h'))
else
let mainfname = expand("%:p:t:r")
+ call Tex_CD(expand("%:p:h"))
endif
***************
*** 306,310 ****
endif
! exec 'cd '.curd
endfunction
--- 310,314 ----
endif
! call Tex_CD(curd)
endfunction
***************
*** 336,348 ****
let viewer = g:Tex_ViewRule_dvi
- let dir = expand("%:p:h").'/'
let curd = getcwd()
- exec 'cd '.expand("%:p:h")
! if Tex_GetMainFileName() != ''
! let mainfname = Tex_GetMainFileName()
! else
! let mainfname = expand("%:p:t:r")
! endif
" inverse search tips taken from Dimitri Antoniou's tip and Benji Fisher's
--- 340,350 ----
let viewer = g:Tex_ViewRule_dvi
let curd = getcwd()
! let mainfname = Tex_GetMainFileName(':t')
! let mainfnameRoot = fnamemodify(Tex_GetMainFileName(), ':t:r')
! " cd to the location of the file to avoid problems with directory name
! " containing spaces.
! call Tex_CD(Tex_GetMainFileName(':p:h'))
" inverse search tips taken from Dimitri Antoniou's tip and Benji Fisher's
***************
*** 350,354 ****
if has('win32')
! let execString = 'silent! !start '. viewer.' -s '.line('.').expand('%:p:t').' '.mainfname
else
--- 352,356 ----
if has('win32')
! let execString = 'silent! !start '. viewer.' -s '.line('.').expand('%:p:t').' '.mainfnameRoot
else
***************
*** 358,364 ****
\ (viewer == "xdvi" || viewer == "xdvik")
! let execString = '!'.viewer.' -name xdvi -sourceposition '.line('.').expand('%').
\ ' -editor "gvim --servername '.v:servername.' --remote-silent +\%l \%f" '.
! \ mainfname.'.dvi &'
elseif exists('g:Tex_UseEditorSettingInDVIViewer') &&
--- 360,366 ----
\ (viewer == "xdvi" || viewer == "xdvik")
! let execString = '!'.viewer.' -name xdvi -sourceposition '.line('.').mainfname.
\ ' -editor "gvim --servername '.v:servername.' --remote-silent +\%l \%f" '.
! \ mainfnameRoot.'.dvi &'
elseif exists('g:Tex_UseEditorSettingInDVIViewer') &&
***************
*** 366,374 ****
\ viewer == "kdvi"
! let execString = 'silent! !kdvi --unique file:'.mainfname.'.dvi\#src:'.line('.').Tex_GetMainFileName(":p:t:r").' &'
else
! let execString = 'silent! !'.viewer.' -name xdvi -sourceposition '.line('.').expand('%').' '.mainfname.'.dvi &'
endif
--- 368,376 ----
\ viewer == "kdvi"
! let execString = 'silent! !kdvi --unique file:'.mainfnameRoot.'.dvi\#src:'.line('.').mainfname.' &'
else
! let execString = 'silent! !'.viewer.' -name xdvi -sourceposition '.line('.').mainfname.' '.mainfnameRoot.'.dvi &'
endif
***************
*** 381,385 ****
endif
! exec 'cd '.curd
endfunction
--- 383,387 ----
endif
! call Tex_CD(curd)
endfunction
***************
*** 425,435 ****
" otherwise do it from current file
let mainfile = Tex_GetMainFileName(":p:r")
! if mainfile != ''
! exe 'bot 1 split '.mainfile
! exe '1,/\s*\\begin{document}/w '.tmpfile
! wincmd q
! else
! exe '1,/\s*\\begin{document}/w '.tmpfile
! endif
exe a:firstline.','.a:lastline."w! >> ".tmpfile
--- 427,433 ----
" otherwise do it from current file
let mainfile = Tex_GetMainFileName(":p:r")
! exe 'bot 1 split '.escape(mainfile, ' ')
! exe '1,/\s*\\begin{document}/w '.tmpfile
! wincmd q
exe a:firstline.','.a:lastline."w! >> ".tmpfile
***************
*** 471,479 ****
" Description: compiles a file multiple times to get cross-references right.
function! Tex_CompileMultipleTimes()
! let mainFileName_root = Tex_GetMainFileName(':p:t:r:r')
!
! if mainFileName_root == ''
! let mainFileName_root = expand("%:p:t:r")
! endif
" First ignore undefined references and the
--- 469,477 ----
" Description: compiles a file multiple times to get cross-references right.
function! Tex_CompileMultipleTimes()
! " Just extract the root without any extension because we want to construct
! " the log file names etc from it.
! let curd = getcwd()
! let mainFileName_root = Tex_GetMainFileName(':p:t:r')
! call Tex_CD(Tex_GetMainFileName(':p:h'))
" First ignore undefined references and the
***************
*** 500,503 ****
--- 498,502 ----
" first run latex.
echomsg "latex run number : ".(runCount+1)
+ call Tex_Debug("Tex_CompileMultipleTimes: latex run number : ".(runCount+1), "comp")
silent! call Tex_CompileLatex()
***************
*** 506,510 ****
" away after compiling again or after bibtex is run etc.
let errlist = Tex_GetErrorList()
! call Tex_Debug("errors = [".errlist."]", "err")
if errlist =~ '\d\+\s\f\+:\d\+\serror'
--- 505,509 ----
" away after compiling again or after bibtex is run etc.
let errlist = Tex_GetErrorList()
! call Tex_Debug("errors = [".errlist."]", "comp")
if errlist =~ '\d\+\s\f\+:\d\+\serror'
***************
*** 567,570 ****
--- 566,571 ----
" emptied because of bibtex/makeindex being run as the last step.
exec 'silent! cfile '.mainFileName_root.'.log'
+
+ call Tex_CD(curd)
endfunction " }}}
***************
*** 764,768 ****
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('compiler.vim: Catching LatexSuiteFileType event') |
\ call <SID>SetCompilerMaps()
augroup END
--- 765,769 ----
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('compiler.vim: Catching LatexSuiteFileType event', 'comp') |
\ call <SID>SetCompilerMaps()
augroup END
|
|
From: <sri...@us...> - 2003-12-14 08:32:59
|
Update of /cvsroot/vim-latex/vimfiles/doc In directory sc8-pr-cvs1:/tmp/cvs-serv25202 Modified Files: latexhelp.txt Log Message: typo in latexhelp.txt caused some broken links (Alex Jakushev) Index: latexhelp.txt =================================================================== RCS file: /cvsroot/vim-latex/vimfiles/doc/latexhelp.txt,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** latexhelp.txt 30 Apr 2002 00:03:13 -0000 1.1.1.1 --- latexhelp.txt 14 Dec 2003 07:05:15 -0000 1.2 *************** *** 1300,1304 **** ============================================================================== ! 9. Lengths *latex-lenghts* A length is a measure of distance. Many LaTeX commands take a length as an --- 1300,1304 ---- ============================================================================== ! 9. Lengths *latex-lengths* A length is a measure of distance. Many LaTeX commands take a length as an |
|
From: <sri...@us...> - 2003-12-14 08:32:51
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8169
Modified Files:
envmacros.vim
Log Message:
Index: envmacros.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/envmacros.vim,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -d -r1.40 -r1.41
*** envmacros.vim 30 Nov 2003 09:51:24 -0000 1.40
--- envmacros.vim 14 Dec 2003 07:17:58 -0000 1.41
***************
*** 1106,1110 ****
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('envmacros.vim: Catching LatexSuiteFileType event') |
\ call s:SetEnvMacrosOptions()
augroup END
--- 1106,1110 ----
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('envmacros.vim: Catching LatexSuiteFileType event', 'env') |
\ call s:SetEnvMacrosOptions()
augroup END
|
|
From: <sri...@us...> - 2003-12-14 08:32:51
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8493
Modified Files:
folding.vim
Log Message:
New: The fold text is now also "indented". in other words, the fold text is
now prepended with the whitespace of the current line so that
nested-ness is more apparent.
Index: folding.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/folding.vim,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** folding.vim 4 Dec 2003 00:10:18 -0000 1.24
--- folding.vim 14 Dec 2003 07:20:26 -0000 1.25
***************
*** 342,345 ****
--- 342,346 ----
" TexFoldTextFunction: create fold text for folds {{{
function! TexFoldTextFunction()
+ let leadingSpace = matchstr(' ', ' \{,'.indent(v:foldstart).'}')
if getline(v:foldstart) =~ '^\s*\\begin{'
let header = matchstr(getline(v:foldstart),
***************
*** 368,380 ****
let retText = matchstr(ftxto, '^[^:]*').': '.header.
\ ' ('.label.') : '.caption
! return retText
elseif getline(v:foldstart) =~ '^%' && getline(v:foldstart) !~ '^%%fake'
let ftxto = foldtext()
! return substitute(ftxto, ':', ': % ', '')
elseif getline(v:foldstart) =~ '^\s*\\document\(class\|style\).*{'
! let ftxto = foldtext()
return substitute(ftxto, ':', ': Preamble: ', '')
else
! return foldtext()
end
endfunction
--- 369,382 ----
let retText = matchstr(ftxto, '^[^:]*').': '.header.
\ ' ('.label.') : '.caption
! return leadingSpace.retText
!
elseif getline(v:foldstart) =~ '^%' && getline(v:foldstart) !~ '^%%fake'
let ftxto = foldtext()
! return leadingSpace.substitute(ftxto, ':', ': % ', '')
elseif getline(v:foldstart) =~ '^\s*\\document\(class\|style\).*{'
! let ftxto = leadingSpace.foldtext()
return substitute(ftxto, ':', ': Preamble: ', '')
else
! return leadingSpace.foldtext()
end
endfunction
|
|
From: <sri...@us...> - 2003-12-14 08:32:50
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv8691
Modified Files:
packages.vim
Log Message:
A few small updates to account for the change in Tex_GetMainFileName()
Index: packages.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/packages.vim,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -d -r1.42 -r1.43
*** packages.vim 7 Nov 2003 02:11:50 -0000 1.42
--- packages.vim 14 Dec 2003 07:22:16 -0000 1.43
***************
*** 75,81 ****
--- 75,83 ----
endif
" Return full list of dictionaries (separated with ,) for package in &rtp
+ call Tex_Debug("searching for ".a:package." in dictionaries/ in &rtp", "pack")
let dictname = Tex_FindInRtp(a:package, 'dictionaries', ':p')
if dictname != ''
exe 'setlocal dict+=' . dictname
+ call Tex_Debug('setlocal dict+=' . dictname, 'pack')
if g:Tex_package_supported !~ a:package
let g:Tex_package_supported = g:Tex_package_supported.','.a:package
***************
*** 114,122 ****
" Find out which file we need to scan.
! if Tex_GetMainFileName() != ''
! let fname = Tex_GetMainFileName(':p:r')
! else
! let fname = expand('%:p')
! endif
" If this is the same as last time, don't repeat.
if !a:force && exists('s:lastScannedFile') &&
--- 116,121 ----
" Find out which file we need to scan.
! let fname = escape(Tex_GetMainFileName(':p'), ' ')
!
" If this is the same as last time, don't repeat.
if !a:force && exists('s:lastScannedFile') &&
***************
*** 144,151 ****
" Now for each package find out if this is a custom package and if so,
! " scan that as well. We will use the ':wincmd f' command in vim to let vim
! " search for the file paths for us. We open up a new file, write down the
! " name of each package and ask vim to open it for us using the 'gf'
! " command.
"
" NOTE: This while loop will also take into account packages included
--- 143,148 ----
" Now for each package find out if this is a custom package and if so,
! " scan that as well. We will use the ':find' command in vim to let vim
! " search through the file paths for us.
"
" NOTE: This while loop will also take into account packages included
***************
*** 179,182 ****
--- 176,182 ----
endif
+ " Split this window in two. The packages/files being found will open
+ " in this new window and we also need not bother with files being
+ " modified etc.
split
***************
*** 299,311 ****
" easy available through <F5> and <F7> shortcuts
function! Tex_ScanForPackages(fname, ...)
-
let pos = line('.').' | normal! '.virtcol('.').'|'
! let currfile = expand('%:p')
call Tex_Debug('currfile = '.currfile.', a:fname = '.a:fname, 'pack')
let toquit = 0
if a:fname != currfile
-
- call Tex_Debug('splitting file', 'pack')
exe 'split '.a:fname
let toquit = 1
--- 299,308 ----
" easy available through <F5> and <F7> shortcuts
function! Tex_ScanForPackages(fname, ...)
let pos = line('.').' | normal! '.virtcol('.').'|'
! let currfile = escape(expand('%:p'), ' ')
call Tex_Debug('currfile = '.currfile.', a:fname = '.a:fname, 'pack')
let toquit = 0
if a:fname != currfile
exe 'split '.a:fname
let toquit = 1
***************
*** 441,444 ****
--- 438,442 ----
if toquit
+ call Tex_Debug("quitting from ".bufname('%'), "pack")
q
endif
***************
*** 659,663 ****
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('packages.vim: Catching LatexSuiteFileType event') |
\ call Tex_pack_updateall(0)
augroup END
--- 657,661 ----
augroup LatexSuite
au LatexSuite User LatexSuiteFileType
! \ call Tex_Debug('packages.vim: Catching LatexSuiteFileType event', 'pack') |
\ call Tex_pack_updateall(0)
augroup END
|
|
From: <sri...@us...> - 2003-12-06 02:46:01
|
Update of /cvsroot/vim-latex/vimfiles/doc
In directory sc8-pr-cvs1:/tmp/cvs-serv24804
Modified Files:
latex-suite.xml
Log Message:
Bug: Tex_FoldedSections no longer contains slide (Zhang Linbo)
Index: latex-suite.xml
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/doc/latex-suite.xml,v
retrieving revision 1.30
retrieving revision 1.31
diff -C2 -d -r1.30 -r1.31
*** latex-suite.xml 2 Dec 2003 12:00:21 -0000 1.30
--- latex-suite.xml 6 Dec 2003 02:45:57 -0000 1.31
***************
*** 2192,2196 ****
setting is a comma seperated list of section names.
The default value is:
! <programlisting>slide,part,chapter,section,%%fakesection,
subsection,subsubsection,paragraph</programlisting>
Each of the entries in the list will fold up a section of the
--- 2192,2196 ----
setting is a comma seperated list of section names.
The default value is:
! <programlisting>part,chapter,section,%%fakesection,
subsection,subsubsection,paragraph</programlisting>
Each of the entries in the list will fold up a section of the
|
|
From: <sri...@us...> - 2003-12-04 00:10:22
|
Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1:/tmp/cvs-serv5083
Modified Files:
folding.vim
Log Message:
Fix: Patch to restrict runaway folding with commands... (Zhang Linbo)
Index: folding.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/folding.vim,v
retrieving revision 1.23
retrieving revision 1.24
diff -C2 -d -r1.23 -r1.24
*** folding.vim 2 Dec 2003 11:16:04 -0000 1.23
--- folding.vim 4 Dec 2003 00:10:18 -0000 1.24
***************
*** 283,287 ****
" will _not_ start a fold.
" In other words, the pattern is safe, but not exact.
! call AddSyntaxFoldItem('^\s*\\'.s.'{[^{}]*$','^\s*}',0,0)
else
call AddSyntaxFoldItem('^\s*\\begin{'.s,'^\s*\\end{'.s,0,0)
--- 283,287 ----
" will _not_ start a fold.
" In other words, the pattern is safe, but not exact.
! call AddSyntaxFoldItem('^\s*\\'.s.'{[^{}]*$','^[^}]*}',0,0)
else
call AddSyntaxFoldItem('^\s*\\begin{'.s,'^\s*\\end{'.s,0,0)
|