Re: Anybody can tell me how to use "auto add "

2006-10-19 Thread panshizhu
"李 俊燕" <[EMAIL PROTECTED]> 写于 2006-10-20 14:17:55: > hi,all > > I don't know how to say that. > I just remember that I can type [ control - a ] before a number > to let it add 1, for example let 1 change to 2. > But it doesn't work in gvim 7.0 for windows. > Is there any other method to do that? >

getchar() trick with recursive map

2006-10-19 Thread Hari Krishna Dara
I remember someone posting a patch to add a new event called GetChar to receive an event for every keypress. This trick is not as powerful and flexible as that, but it can be very useful for a plugin, and is supported in Vim7.0 with no patches. Often there are questions on this list on how to cap

Anybody can tell me how to use "auto add "

2006-10-19 Thread 李 俊燕
hi,all I don't know how to say that. I just remember that I can type [ control - a ] before a number to let it add 1, for example let 1 change to 2. But it doesn't work in gvim 7.0 for windows. Is there any other method to do that? thank you very much. Li

Re: ruby indentation

2006-10-19 Thread Akbar
On 10/20/06, A.J.Mechelynck <[EMAIL PROTECTED]> wrote: Akbar wrote: > Hi, I use vim7 ( compiled from source ) > > This is my situation: > open bla.rb > > def bla ( type def bla, enter ) > print "bla"( type two spaces and print "bla", enter ) > print "bli" ( no need

Re: "change counter" ? -- test that buffer did not change between two calls

2006-10-19 Thread Hari Krishna Dara
On Thu, 19 Oct 2006 at 3:15pm, Yegappan Lakshmanan wrote: > Hi Yakov, > > On 10/19/06, Yakov Lerner <[EMAIL PROTECTED]> wrote: > > I'd like to cache some information about file, into > > b:variables, and be able to check in my function, > > whether buffer changed in any way between 2 calls > > to

Re: filename completion not recognising pdf's

2006-10-19 Thread Benji Fisher
On Thu, Oct 19, 2006 at 11:57:22PM +0200, Eric Smith wrote: > Vim does not complete pdf files with C-X C-F. > > Is there a place where I can alter this (mis)behavior? > > -- > Eric Smith It does for me. Two options that may affect this are 'suffixes' and 'wildignore'. The first just give

Re: checking for &cp in plugins

2006-10-19 Thread Benji Fisher
On Thu, Oct 19, 2006 at 11:43:22PM +0200, Yakov Lerner wrote: > I am making a plugin which naturally requires &nocp > because it uses in lhs and rhs of mappings it defines. > What if that plugin sees &cp, what it shall do ? Shall I > save old value of &cp, then temporarily 'set nocp', define > map

Re: path is changing mysteriously...

2006-10-19 Thread Benji Fisher
On Thu, Oct 19, 2006 at 07:46:04PM +0200, Yakov Lerner wrote: > On 10/19/06, Lev Lvovsky <[EMAIL PROTECTED]> wrote: > >For some reason, with the many buffers that I have open, the path > >that a particular file takes, is instead of the initial directory > >where I started from (which is what I want

Re: ruby indentation

2006-10-19 Thread A.J.Mechelynck
Akbar wrote: Hi, I use vim7 ( compiled from source ) This is my situation: open bla.rb def bla ( type def bla, enter ) print "bla"( type two spaces and print "bla", enter ) print "bli" ( no need to type two spaces, sweet, type print "bli", enter ) end

Re: Fighting with comments

2006-10-19 Thread A.J.Mechelynck
Meghdad Azriel wrote: I was just kidding ;) I know that they are not secret but, they´re not that intuitive... and i´m still learning how to use that help effectivelly... maybe I neet to read those basic files with care... [...] To use the help effectively, one should learn to use the tools

Re: Can the mailing list owner set "Reply-to" field be [EMAIL PROTECTED]

2006-10-19 Thread A.J.Mechelynck
Kamaraju Kusumanchi wrote: On Thursday 19 October 2006 15:00, Paul Irofti wrote: Of course if you're stuck with Windows then I'd suggest Thunderbird Thunderbird does not have a reply-to-list facility and is one of the long standing bugs (6 years and still going). More details at https://bugz

Re: BUG: formatoptions+=t makes comments wrap (incorrectly) when they shouldn't

2006-10-19 Thread Peter Hodge
--- Bram Moolenaar <[EMAIL PROTECTED]> wrote: > > Peter Hodge wrote: > > > When I have formatoptions=t, it makes comment lines wrap when they > > shouldn't, and it also ignores whatever comment leader is defined in > > 'comments'. To reproduce: > > > > > > :set formatoptions=roc > > :set

Re: Can the mailing list owner set "Reply-to" field be [EMAIL PROTECTED]

2006-10-19 Thread Kamaraju Kusumanchi
On Thursday 19 October 2006 15:00, Paul Irofti wrote: > Of course if you're > stuck with Windows then I'd suggest Thunderbird Thunderbird does not have a reply-to-list facility and is one of the long standing bugs (6 years and still going). More details at https://bugzilla.mozilla.org/show_bug.c

Re: "change counter" ? -- test that buffer did not change between two calls

2006-10-19 Thread Yegappan Lakshmanan
Hi Yakov, On 10/19/06, Yakov Lerner <[EMAIL PROTECTED]> wrote: I'd like to cache some information about file, into b:variables, and be able to check in my function, whether buffer changed in any way between 2 calls to the function. Is there any "change counter" that I can store and compare later

filename completion not recognising pdf's

2006-10-19 Thread Eric Smith
Vim does not complete pdf files with C-X C-F. Is there a place where I can alter this (mis)behavior? -- Eric Smith

Re: "change counter" ? -- test that buffer did not change between two calls

2006-10-19 Thread Hari Krishna Dara
On Thu, 19 Oct 2006 at 11:25pm, Yakov Lerner wrote: > I'd like to cache some information about file, into > b:variables, and be able to check in my function, > whether buffer changed in any way between 2 calls > to the function. Is there any "change counter" that I can > store and compare later t

checking for &cp in plugins

2006-10-19 Thread Yakov Lerner
I am making a plugin which naturally requires &nocp because it uses in lhs and rhs of mappings it defines. What if that plugin sees &cp, what it shall do ? Shall I save old value of &cp, then temporarily 'set nocp', define mappings, then restore &cp ? Is this OK ? Or it shall check &cp and silen

Re: vim temp files on windows

2006-10-19 Thread Meghdad Azriel
Didn´t work for me... It gave me an error saying that it could not make the backup file... Mathias Michaelis wrote: > > Hello Kev > >> Whenever I edit a file in gvim on Windows, a temporary >> file of the same name but with a tilde (~) on the end >> is created. >> > This are backup files an

"change counter" ? -- test that buffer did not change between two calls

2006-10-19 Thread Yakov Lerner
I'd like to cache some information about file, into b:variables, and be able to check in my function, whether buffer changed in any way between 2 calls to the function. Is there any "change counter" that I can store and compare later to detect the buffer change (any change like any insertion, dele

Re: Fighting with comments

2006-10-19 Thread Meghdad Azriel
I was just kidding ;) I know that they are not secret but, they´re not that intuitive... and i´m still learning how to use that help effectivelly... maybe I neet to read those basic files with care... Gary Johnson wrote: > > On 2006-10-19, eric1235711 <[EMAIL PROTECTED]> wrote: >> this wor

Re: BUG: formatoptions+=t makes comments wrap (incorrectly) when they shouldn't

2006-10-19 Thread Bram Moolenaar
Peter Hodge wrote: > When I have formatoptions=t, it makes comment lines wrap when they > shouldn't, and it also ignores whatever comment leader is defined in > 'comments'. To reproduce: > > > :set formatoptions=roc > :set comments=b:% > :set textwidth=30 > > % type these lines of tex

Re: locked window

2006-10-19 Thread Kim Schulz
On Thu, 19 Oct 2006 12:15:17 -0700 "Yegappan Lakshmanan" <[EMAIL PROTECTED]> wrote: > You can use the detailed example code under ":help > CursorHold-example". It uses the ":ptag" command and the cursorhold > autocmd to jump to the tag under the cursor in the preview window and > highlight the li

Re: Fighting with comments

2006-10-19 Thread Gary Johnson
On 2006-10-19, eric1235711 <[EMAIL PROTECTED]> wrote: > this worked too > > I think this is better, help tells that this formatoptions is specific to > coments and things... > > But I´m getting disgusted of these "secret and magic commands"... Secret? You might find it helpful to look at :

Re: Fighting with comments

2006-10-19 Thread Gary Johnson
On 2006-10-19, eric1235711 <[EMAIL PROTECTED]> wrote: > here it's in this way: > C:/Program Files/Vim > and it contains vim70/ and vimfiles/ > > Oh, thanks, Gary! it worked!!! > > But I didn´t like it!!! > > when I changed C:/Program Files/Vim/vimfiles/ftplugin/php.vim it stoped > 'autowriting'

Re: www.vim.org

2006-10-19 Thread Preben Randhol
On Thu, 19 Oct 2006 18:29:19 +0200 Preben Randhol <[EMAIL PROTECTED]> wrote: > Still doesn't work from my ISP, but works from other ISPs, so I guess > it will take a bit time before it trinkles down to all dns servers... Works now.

Re: locked window

2006-10-19 Thread Yegappan Lakshmanan
Hi, On 10/19/06, Kim Schulz <[EMAIL PROTECTED]> wrote: On Thu, 19 Oct 2006 15:18:12 +0200 "A.J.Mechelynck" <[EMAIL PROTECTED]> wrote: [snip] > > Instead of calling the program "vim", call it "rview". Then you won't > be able to write anything, nor to use a shell command. Is that safe > enough?

Re: www.vim.org

2006-10-19 Thread Paul Irofti
Works just fine for me. Here's a traceroute for those in doubt: $ traceroute www.vim.org traceroute to vhost.sourceforge.net (66.35.250.210), 64 hops max, 40 byte packets  1  nautilus (192.168.1.1)  0.173 ms  0.183 ms  0.145 ms  2  86.106.2.2 (86.106.2.2)  0.456 ms  0.707 ms  0.430 ms  3  192.168

Re: Match something that not in the pattern

2006-10-19 Thread Bill McCarthy
On Thu 19-Oct-06 9:26am -0600, Charles E Campbell Jr wrote: > So, to do what you ask with LogiPat's result: > > :g/^\%(\%(}}$\)[EMAIL PROTECTED])*$/j Please see my response to Tony Mechelynck. Your solution changes the text of Peng Yu's example to 5 lines. As I understand his goal, the correct

Re: Can the mailing list owner set "Reply-to" field be [EMAIL PROTECTED]

2006-10-19 Thread Paul Irofti
On Thursday 19 October 2006 07:22, Kamaraju Kusumanchi wrote: > On Wednesday 18 October 2006 22:22, Peng Yu wrote: > > Hi, > > > > Can the mailing list owner set "Reply-to" field in every mail > > forward from this mailing list be "vim@vim.org"? > > > > I replied some mails to the original poster.

Re: ruby indentation

2006-10-19 Thread Paul Irofti
On Thursday 19 October 2006 18:26, Akbar wrote: > Hi, I use vim7 ( compiled from source ) > > This is my situation: > open bla.rb > > def bla ( type def bla, enter ) > print "bla"( type two spaces and print "bla", enter ) > print "bli" ( no need to type two spaces,

Re: Question about listchars

2006-10-19 Thread Jean-Rene David
* Jeff Lanzarotta [2006.10.19 13:13]: > If there a way to check and see if the listchar > is actually set or not? For options I change often, I use the following to display its value in the statusline. function! OptSet(opt, string) if(exists("a:opt") && expand(a:opt)) return a:string

Re: Question about listchars

2006-10-19 Thread Steve Hall
On Thu, 2006-10-19 at 08:59 -0700, Jeff Lanzarotta wrote: > > I have the following in my vimrc, > > > " This shows spaces and tabs characters. Visual Whitespace. > set listchars=tab:»·,trail:· > set list > > > That all work well and good, but I would like to disable this > disp

Re: path is changing mysteriously...

2006-10-19 Thread Yakov Lerner
On 10/19/06, Lev Lvovsky <[EMAIL PROTECTED]> wrote: For some reason, with the many buffers that I have open, the path that a particular file takes, is instead of the initial directory where I started from (which is what I want), the directory that the file resides in. Trying ":cd", or ":lcd" onl

path is changing mysteriously...

2006-10-19 Thread Lev Lvovsky
For some reason, with the many buffers that I have open, the path that a particular file takes, is instead of the initial directory where I started from (which is what I want), the directory that the file resides in. Trying ":cd", or ":lcd" only temporarily changes it, and in a few seconds

Re: Question about listchars

2006-10-19 Thread Jeff Lanzarotta
Awesome. Thanks... --- Tim Chase <[EMAIL PROTECTED]> wrote: > > Thanks for all the suggestions. They helped out... If there a way > to > > check and see if the listchar is actually set or not? > > > > In my script, I now turn off the display with 'set invlist list?', > but > > I do not want to t

Re: Question about listchars

2006-10-19 Thread Tim Chase
Thanks for all the suggestions. They helped out... If there a way to check and see if the listchar is actually set or not? In my script, I now turn off the display with 'set invlist list?', but I do not want to turn it back on if it was not previously set... Well, you can use the common idiom

Re: Question about listchars

2006-10-19 Thread Jeff Lanzarotta
Thanks for all the suggestions. They helped out... If there a way to check and see if the listchar is actually set or not? In my script, I now turn off the display with 'set invlist list?', but I do not want to turn it back on if it was not previously set... --- Bill McCarthy <[EMAIL PROTECTED]>

Re: Question about listchars

2006-10-19 Thread Karl Guertin
On 10/19/06, Jeff Lanzarotta <[EMAIL PROTECTED]> wrote: That all work well and good, but I would like to disable this display of visual white space temporarily, do something, and then reset it back to what I had. Is there a way to do this? :map l :set invlist Then type \l when you want to tog

Re: Question about listchars

2006-10-19 Thread Bill McCarthy
On Thu 19-Oct-06 10:59am -0600, Jeff Lanzarotta wrote: > I have the following in my vimrc, > > > " This shows spaces and tabs characters. Visual Whitespace. > set listchars=tab:»·,trail:· > set list > > > That all work well and good, but I would like to disable this display > of

Re: Question about listchars

2006-10-19 Thread Marius Roets
On 10/19/06, Jeff Lanzarotta <[EMAIL PROTECTED]> wrote: Hello, I have the following in my vimrc, " This shows spaces and tabs characters. Visual Whitespace. set listchars=tab:»·,trail:· set list That all work well and good, but I would like to disable this display of visual w

Re: www.vim.org

2006-10-19 Thread Preben Randhol
On Wed, 18 Oct 2006 23:30:15 +0200 Bram Moolenaar <[EMAIL PROTECTED]> wrote: > SourceForge has fixed the VHOST service, www.vim.org is back! Still doesn't work from my ISP, but works from other ISPs, so I guess it will take a bit time before it trinkles down to all dns servers... Preben

Re: Question about listchars

2006-10-19 Thread Tim Chase
" This shows spaces and tabs characters. Visual Whitespace. set listchars=tab:»·,trail:· set list That all work well and good, but I would like to disable this display of visual white space temporarily, do something, and then reset it back to what I had. Is there a way to do this? Well

Re: locked window

2006-10-19 Thread Kim Schulz
On Thu, 19 Oct 2006 15:18:12 +0200 "A.J.Mechelynck" <[EMAIL PROTECTED]> wrote: [snip] > > Instead of calling the program "vim", call it "rview". Then you won't > be able to write anything, nor to use a shell command. Is that safe > enough? Maybe ":help starting.txt" will give you other ideas.

Question about listchars

2006-10-19 Thread Jeff Lanzarotta
Hello, I have the following in my vimrc, " This shows spaces and tabs characters. Visual Whitespace. set listchars=tab:»·,trail:· set list That all work well and good, but I would like to disable this display of visual white space temporarily, do something, and then reset it ba

ruby indentation

2006-10-19 Thread Akbar
Hi, I use vim7 ( compiled from source ) This is my situation: open bla.rb def bla ( type def bla, enter ) print "bla"( type two spaces and print "bla", enter ) print "bli" ( no need to type two spaces, sweet, type print "bli", enter ) end ( type en

Re: Quickfix behaviour

2006-10-19 Thread Yegappan Lakshmanan
Hi, On 10/19/06, Marius Roets <[EMAIL PROTECTED]> wrote: On 10/19/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > 1) I would like to open a new window/tab, rather than use the one > > above the quickfix window. > > :h 'switchbuf' -> split > > > 2) If the buffer is already open in another

Re: Match something that not in the pattern

2006-10-19 Thread Charles E Campbell Jr
Peng Yu wrote: Hi, I have the following file segments. I want to concatenate all the lines with their next lines, except that it ends with "}}". I want to use the pattern "\(}}\)[EMAIL PROTECTED]". It seems not working. Would you please help me to figure out how to match the lineend without "

Re: redefining * and #

2006-10-19 Thread Tim Chase
I want to redefine * such that if next match is not found, it does # instead (goes to previous match). Also, I want to redefine # so that is previoue match is not found, it does * instead. How to do do it ? I want it to be independent of 'wrapscan' option (I have 'nowrapscan' always, anyway).

Re: locked window

2006-10-19 Thread Andy Wokula
Brecht Machiels schrieb: Hi, You can clear the 'modifiable' option to disable unintended modifications to a buffer. setlocal nomodifiable Is is possible to prevent, for example, the project plugin from opening another file (other than the current) in a window? The nomodifiable option only

Re: locked window

2006-10-19 Thread A.J.Mechelynck
Brecht Machiels wrote: Hi, You can clear the 'modifiable' option to disable unintended modifications to a buffer. setlocal nomodifiable Is is possible to prevent, for example, the project plugin from opening another file (other than the current) in a window? The nomodifiable option only a

Re: redefining * and #

2006-10-19 Thread Yakov Lerner
On 10/19/06, Yakov Lerner <[EMAIL PROTECTED]> wrote: I want to redefine * such that if next match is not found, it does # instead (goes to previous match). Also, I want to redefine # so that is previoue match is not found, it does * instead. How to do do it ? I want it to be independent of 'wra

Re: Fighting with comments

2006-10-19 Thread eric1235711
this worked too I think this is better, help tells that this formatoptions is specific to coments and things... But I´m getting disgusted of these "secret and magic commands"... thaks Peter Hodge-2 wrote: > > > --- Gary Johnson <[EMAIL PROTECTED]> wrote: > >> On 2006-10-18, eric1235711 <[E

Re: Fighting with comments

2006-10-19 Thread eric1235711
here it's in this way: C:/Program Files/Vim and it contains vim70/ and vimfiles/ Oh, thanks, Gary! it worked!!! But I didn´t like it!!! when I changed C:/Program Files/Vim/vimfiles/ftplugin/php.vim it stoped 'autowriting' comments in new lines... but when I changed C:/Program Files/Vim/vimfiles

Re: Fighting with comments

2006-10-19 Thread eric1235711
My gvim version is 7.0 eric1235711 wrote: > > Hello > > I´m PHP programmer and I started programming in gVim last weak, and I´m > liking it very much > > But I got a trouble... > > When I´m commenting (// or /* or #) and I type it breaks the line > automatically. Always I start a comment, i

Re: Quickfix behaviour

2006-10-19 Thread Marius Roets
On 10/19/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > 1) I would like to open a new window/tab, rather than use the one > above the quickfix window. :h 'switchbuf' -> split > 2) If the buffer is already open in another tab page, I'd like to jump > there, instead of opening it in this ta

redefining * and #

2006-10-19 Thread Yakov Lerner
I want to redefine * such that if next match is not found, it does # instead (goes to previous match). Also, I want to redefine # so that is previoue match is not found, it does * instead. How to do do it ? I want it to be independent of 'wrapscan' option (I have 'nowrapscan' always, anyway). Y

Re: Can the mailing list owner set "Reply-to" field be [EMAIL PROTECTED]

2006-10-19 Thread Christian J. Robinson
On Wed, 18 Oct 2006, Peng Yu wrote: > Can the mailing list owner set "Reply-to" field in every mail > forward from this mailing list be "vim@vim.org"? > > I replied some mails to the original poster. But sometime I forget > to reply the mails to the mailing list. This request comes up from time

Re: Quickfix behaviour

2006-10-19 Thread hermitte
Hello, Marius Roets <[EMAIL PROTECTED]> wrote: > In a quickfix window, selecting an error (pressing enter) takes you to > that error. The way it does this is by opening the file in the window > above the quickfix window (if it is not open already, in which case it > jumps to the open buffer, assu

Quickfix behaviour

2006-10-19 Thread Marius Roets
Hi everybody, In a quickfix window, selecting an error (pressing enter) takes you to that error. The way it does this is by opening the file in the window above the quickfix window (if it is not open already, in which case it jumps to the open buffer, assuming the buffer is in the same tabpage). T

Re: Match something that not in the pattern

2006-10-19 Thread Bill McCarthy
On Thu 19-Oct-06 2:28am -0600, you wrote: > Bill McCarthy wrote: >> On Wed 18-Oct-06 10:24pm -0600, A.J.Mechelynck wrote: >> >>> Peng Yu wrote: Hi, I have the following file segments. I want to concatenate all the lines with their next lines, except that it ends with "}}". I w

Re: Match something that not in the pattern

2006-10-19 Thread A.J.Mechelynck
Bill McCarthy wrote: On Thu 19-Oct-06 2:28am -0600, you wrote: Bill McCarthy wrote: On Wed 18-Oct-06 10:24pm -0600, A.J.Mechelynck wrote: Peng Yu wrote: Hi, I have the following file segments. I want to concatenate all the lines with their next lines, except that it ends with "}}". I want

Re: Match something that not in the pattern

2006-10-19 Thread Bill McCarthy
On Thu 19-Oct-06 3:08am -0600, you wrote: > Hadn't thought of that. So IIUC our final try is > 1,$-1v/}}$/ > \ while getline(".") !~ '}}$' > \ && line(".") != line ("$") > \ | join > \ | endwhile

Re: locked window

2006-10-19 Thread Brecht Machiels
Hi, You can clear the 'modifiable' option to disable unintended modifications to a buffer. setlocal nomodifiable Is is possible to prevent, for example, the project plugin from opening another file (other than the current) in a window? The nomodifiable option only applies to the buffer. Th

Re: Match something that not in the pattern

2006-10-19 Thread A.J.Mechelynck
Bill McCarthy wrote: On Wed 18-Oct-06 10:24pm -0600, A.J.Mechelynck wrote: Peng Yu wrote: Hi, I have the following file segments. I want to concatenate all the lines with their next lines, except that it ends with "}}". I want to use the pattern "\(}}\)[EMAIL PROTECTED]". It seems not working

Re: Match something that not in the pattern

2006-10-19 Thread Bill McCarthy
On Wed 18-Oct-06 10:24pm -0600, A.J.Mechelynck wrote: > Peng Yu wrote: >> Hi, >> >> I have the following file segments. I want to concatenate all the >> lines with their next lines, except that it ends with "}}". I want to >> use the pattern "\(}}\)[EMAIL PROTECTED]". It seems not working. >> >>