Update of /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12876
Modified Files:
envmacros.vim version.vim
Log Message:
Bug: Selecting a word visually and pressing <F7> does not enclose the word
in the selected command (Javier Rojas)
Why: Tex_DoCommand() never set s:isvisual.
Fix: Never really like s:isvisual anyway. Now, Tex_DoCommand() just conveys
whether its visual or not via another argument to Tex_PutCommand().
Bug: Pressing <F7> after foo* does not create \foo*{} (Javier Rojas)
Why: We restrict the previous string of letters to end in a 'iskeyword'
character.
Fix: Instead of requiring that users extend the 'iskeyword' setting to
include *, just allow for words like foo* because this is a very
common thing in LaTeX
Index: envmacros.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/envmacros.vim,v
retrieving revision 1.50
retrieving revision 1.51
diff -C2 -d -r1.50 -r1.51
*** envmacros.vim 1 Jan 2006 07:53:01 -0000 1.50
--- envmacros.vim 25 Jan 2006 04:16:28 -0000 1.51
***************
*** 989,993 ****
let com = PromptForCommand('Choose a command to insert: ')
if com != ''
! return Tex_PutCommand(com)
else
return ''
--- 989,993 ----
let com = PromptForCommand('Choose a command to insert: ')
if com != ''
! return Tex_PutCommand(com, a:isvisual)
else
return ''
***************
*** 999,1004 ****
let c = col('.')
! let wordbef = matchstr(strpart(presline, 0, c-1), '\k\+$')
! let wordaft = matchstr(strpart(presline, c-1), '^\k\+')
let word = wordbef . wordaft
--- 999,1004 ----
let c = col('.')
! let wordbef = matchstr(strpart(presline, 0, c-1), '\k\+\*\?$')
! let wordaft = matchstr(strpart(presline, c-1), '^\k\+\*\?')
let word = wordbef . wordaft
***************
*** 1010,1018 ****
return substitute(wordbef, '.', "\<Left>", 'g')
\ . substitute(word, '.', "\<Del>", 'g')
! \ . Tex_PutCommand(word)
else
let cmd = PromptForCommand('Choose a command to insert: ')
if cmd != ''
! return Tex_PutCommand(cmd)
else
return ''
--- 1010,1018 ----
return substitute(wordbef, '.', "\<Left>", 'g')
\ . substitute(word, '.', "\<Del>", 'g')
! \ . Tex_PutCommand(word, a:isvisual)
else
let cmd = PromptForCommand('Choose a command to insert: ')
if cmd != ''
! return Tex_PutCommand(cmd, a:isvisual)
else
return ''
***************
*** 1024,1031 ****
" Description:
" Based on input argument, it calls various specialized functions.
! function! Tex_PutCommand(com)
! if exists("s:isvisual") && s:isvisual == "yes"
! let s:isvisual = 'no'
!
if a:com == '$'
return VEnclose('$', '$', '$', '$')
--- 1024,1029 ----
" Description:
" Based on input argument, it calls various specialized functions.
! function! Tex_PutCommand(com, isvisual)
! if a:isvisual == "yes"
if a:com == '$'
return VEnclose('$', '$', '$', '$')
Index: version.vim
===================================================================
RCS file: /cvsroot/vim-latex/vimfiles/ftplugin/latex-suite/version.vim,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** version.vim 20 Jan 2006 16:35:20 -0000 1.1
--- version.vim 25 Jan 2006 04:16:28 -0000 1.2
***************
*** 25,29 ****
" keep that as a stable point.
function! Tex_Version()
! return "Latex-Suite: version 1.8.06"
endfunction
--- 25,29 ----
" keep that as a stable point.
function! Tex_Version()
! return "Latex-Suite: version 1.8.07"
endfunction
|