Re: Multiple search highlights?

2007-06-04 Thread Andy Wokula
Ron Olson schrieb: Hi all- I just recently joined this list after using Vim for awhile, and vi since, gosh, 1990 on a Vax. I'm astounded how, over the years, vi (and now Vim) have served my needs pretty much perfectly; what other editor is available on everything, has every feature you could pos

Re: Open all folds in the current fold?

2007-06-04 Thread Andy Wokula
Tim Chase schrieb: I'm trying to find/create a command that acts somewhat like zO/zR for within an existing fold. If I use zR, it opens all the folds in the whole document. If I use zO, it opens all the folds under the cursor. The behavior I'm looking for is that if I'm within an existing fold

Re: copying text char-by-char from the line above line..

2007-05-31 Thread Andy Wokula
Ajay Gupta schrieb: Hi All, I saw one of my friends (once!) copying the text from the line right above. He was using some keycombo and it would appear like he was copying the characters one-by-one. So, if there are two lines like quick brown fox I see and on the 2nd line, after 'see', i wanted

Re: A performance question

2007-05-22 Thread Andy Wokula
A.J.Mechelynck schrieb: Robert M Robinson wrote: First, thanks very much for creating VIM! I have been using it on Linux systems for years, and now use it via cygwin at home as well. I vastly prefer VIM to EMACS, especially at home. I learned vi on a VAX/VMS system long ago (a friend of m

Re: Go to start of visual selection

2007-05-16 Thread Andy Wokula
Andy Wokula schrieb: Tim Chase schrieb: How can I move the cursor the start of the visual selection? With the "o" command, yes. But how can I make sure the cursor is at the start while visual mode is on? The "`<" motion followed by "gv" sets the cursor bac

Re: comments after brackets with vim?

2007-05-14 Thread Andy Wokula
searchpair() Hopefully, filetype "skill" is what you currently use for those kind of files. -- Regards, Andy EOM " Vim filetype plugin code snippet " Language: skill (cadence extension language) " File: skill_comment.vim " Date: 2007 Mai 14 " Author:

Re: vim 7.1 and cr/lf interpretation

2007-05-14 Thread Andy Wokula
Thomas Michael Engelke schrieb: :set fileformats? gives "fileformats=dos,unix", so both formats are available, yet the detection and switching does not seem to work. Are you sure _every_ line ends in "^M"? -- Regards, Andy EOM

Re: Vim and email quoting

2007-05-11 Thread Andy Wokula
Timothy Knox schrieb: I use vim to write my outgoing email, and for the most part, it rocks. Thanks to all the folks who have written modules and provided tips that make it the best thing for writing email since mailx . That said, there is one small annoyance I find: When replying to an email, I

Re: autocomplete on the command line from words in buffers

2007-05-07 Thread Andy Wokula
Larson, David schrieb: Hello Dan, I suggest wrapping these functions into vim commands and then leverage the command completion feature. See: :help :command-completion HTH, David -Original Message- From: Dan Fabrizio [mailto:[EMAIL PROTECTED] Sent: Monday, May 07, 2007 5:27 AM To: v

Re: Avoiding German Umlauts....

2007-04-27 Thread Andy Wokula
A.J.Mechelynck schrieb: Andy Wokula wrote: A.J.Mechelynck schrieb: [...] Note that the official transliteration of the eszett is not sz but ss: upcase("ß") is "SS" and, in de_CH locales, the eszett is not used (other than for "archaic" look, sometimes togethe

Re: Avoiding German Umlauts....

2007-04-27 Thread Andy Wokula
A.J.Mechelynck schrieb: [EMAIL PROTECTED] wrote: Hi, I want to write a macro, function or what else, which ensures, that no german umlauts (äöüÄÖÜ) or the "sz" (ß) will ever occure in any file written with vim. It does not matter, if these charactes will appear while typing but they should

Re: strange commenting behaviour (text gets deleted)

2007-04-18 Thread Andy Wokula
Andy Wokula schrieb: Daniel Nogradi schrieb: [...] This function is a modified version of something I found in one of the tips or scripts of the vim website. For C I use of course Komment2('/* ', ' */') and this works perfectly well, I can select a block of lines, call th

Re: strange commenting behaviour (text gets deleted)

2007-04-18 Thread Andy Wokula
Daniel Nogradi schrieb: > Hi vimmers, > > I have a very strange problem and couldn't figure out what's going on. > I use the following function for commenting out a line or a block of > lines: > > > function! Komment2(commentLeader, commentTrailer) >if match( getline("."), "^\ *$" ) < 0 >

Re: strange commenting behaviour (text gets deleted)

2007-04-17 Thread Andy Wokula
Daniel Nogradi schrieb: Hi vimmers, I have a very strange problem and couldn't figure out what's going on. I use the following function for commenting out a line or a block of lines: function! Komment2(commentLeader, commentTrailer) if match( getline("."), "^\ *$" ) < 0 let save_cpo

Re: how to avoid deleting the auto-indent in a new empty line when i press

2007-04-17 Thread Andy Wokula
Gary Johnson schrieb: On 2007-04-16, fREW <[EMAIL PROTECTED]> wrote: On 4/16/07, Tom Whittock <[EMAIL PROTECTED]> wrote: What I need is to always keep the auto-indented spaces. So next time I can start to insert from the spaced cursor. Alternatively use cc to edit the ostensibly blank line.

Re: Troubles configuring vim (multi-questions)

2007-04-14 Thread Andy Wokula
OnionKnight schrieb: I think I understand the difference now and my function is pretty neat now. function! HomeKey () let c = col(".") if c == 1 normal ^ else normal ^ if col(".") >= c normal 0

Re: case of very slow regex search

2007-04-03 Thread Andy Wokula
Yakov Lerner schrieb: I use sometimes the regex that finds paragraphs containing given words w1,w2,... in any order ( I define "paragraph" as separated by lines, \n\n). I use the pattern like this: (two-word example, w1 and w2, but easily expandable for N words): /\c\(.\|.\n\)*\\&\(.\|.\n

Re: Question about b:did_ftplugin

2007-04-02 Thread Andy Wokula
Thomas schrieb: Now, when I do set ft=X from the command line, it happens that the ftplugin X doesn't get loaded because it finishes when b:did_ftplugin is set. What I actually meant by this was: the ftplugin X doesn't get loaded when a filetype was already set before, i.e. when a filetype plu

Re: Question about b:did_ftplugin

2007-04-02 Thread Andy Wokula
Thomas schrieb: Hi, When I set a filetype for a buffer the variable b:did_ftplugin is set. The help says: If you are writing a filetype plugin to be used by many people, they need a chance to disable loading it. Put this at the top of the plugin: > " Only do this when not done yet for

Re: Vim Help for deleting alternate lines in text

2007-03-31 Thread Andy Wokula
Gary Johnson schrieb: Auro Ashish Saha wrote: Hello, Please help me to remove alternate lines from a text file. 00 0 123456 9 99 9 123445 9 I want to delete the line 1, 3, 5 and so on. What are the commands to be used. Thanks for help in advance. Method I: q

Re: two questions , map and scroll

2007-03-27 Thread Andy Wokula
shawn bright schrieb: lo there, i have two quick questions. first, is there a way i can scroll text under the cursor ( so that the cursor stays on the same place in the terminal, but the text scrolls anyway ) i just think that would be really cool. Without mappings: " keep cursor in same c

GVim Crash

2007-03-25 Thread Andy Wokula
GVim7 (Win32) crashes if I do the following: " clean startup :new :tabnew :call winnr("#") " happens with or without 219 patches included Andy -- EOM

Re: Selecting tag opens file in a new tab - how?

2007-03-23 Thread Andy Wokula
A.J.Mechelynck schrieb: Zarko Coklin wrote: I posted following question some time back: ~ Is it possible to have a setup in .vimrc so that every time I select tag either through "CTRL-]" or by holding CTRL and pressing left mouse click to open a new buffer in a new ta

Re: Count characters

2007-03-22 Thread Andy Wokula
Tim Chase schrieb: Is there some function or script to count characters (letters without whitespaces) in vim? For example Kile the Latex Editor has such a feature to control how long texts are. You can use :%s/\w/&/g which will report back "X substitutions on Y lines". "X" represents

Re: Vim Help for deleting text

2007-03-20 Thread Andy Wokula
Arnaud Bourree schrieb: Arnaud Bourree wrote on 20/03/2007 10:22: Tim Chase wrote on 19/03/2007 23:01: Or, if all your columns align, you can use visual-block mode with control+V to create a block across the characters in question, and then just hit "d" to delete. -tim Sorry, I'm begginer w

Re: Get date and filename as plain text

2007-03-15 Thread Andy Wokula
Wolfgang Schmidt schrieb: Hi, I don't know about the filename part, but you could insert a date with the following mapping: inoremap @date =strftime("%d.%m.%Y") Cheers, Wolfgang Eric Leenman wrote: Hi, Is it possible to make an inoremap that inserts the date as text and the filena

Re: clone a vim session into a new tab

2007-03-13 Thread Andy Wokula
Kamaraju S Kusumanchi schrieb: Andy Wokula wrote: Ok tabpages are included in the session per default. Try :set sessionoptions-=tabpages first. Awesome! Thanks a lot! :help 'sessionoptions' The help is a bit confusing. It says There is no option to include tab pages

Re: clone a vim session into a new tab

2007-03-13 Thread Andy Wokula
Kamaraju S Kusumanchi schrieb: Andy Wokula wrote: Simple way (recommended or not, at least quick) with sessions: :mks " use ! to overwrite existing Session.vim :tabnew :so Session.vim Just guessed it might work and it works. Now I think sessions don't include tabpages. This work

Re: clone a vim session into a new tab

2007-03-13 Thread Andy Wokula
Kamaraju S Kusumanchi schrieb: Let's say I opened a 6 files in a 3X2 grid inside vim. Now I want to clone this and have all the files at the same position, same window sizes etc., and put it into a new tab under the same vim session. Is there a command to do this? commands like tabe etc., open o

Re: visual problem

2007-03-12 Thread Andy Wokula
Simon Jackson schrieb: I have a problem when i am in visual mode and i have text highlighted. Instead of being able to run a command, it just overwrites my selected text instead. im sure its because of something in my vimrc but i just cant pinpoint it, can anyone help? P.S.: If anyone sees some

Re: How to paste without replace the content in buffer

2007-03-11 Thread Andy Wokula
Peng Yu schrieb: Hi, Suppose I want to replace "string1" with "string2" in a file from vim. 1. Highlight "string1" (in visual mode) and then type "y". 2. Highlight "string2" (in visual mode) and then type "p". However, the problem with the above procedure is that "string2", instead of "string1

Re: Insert new blank line in normal mode

2007-02-23 Thread Andy Wokula
A.J.Mechelynck schrieb: Alexey Vakhov wrote: Hi Dear community, Command o and O create new line and switch to insert mode. I want only insert blank line and stay in normal mode. I know this problem can be solved using simple mappting, but maybe in vim there are original commands for this tip? T

Re: Marking an undo-block before ^U in insert-mode

2007-02-23 Thread Andy Wokula
A.J.Mechelynck schrieb: Andy Wokula wrote: There is another strange detail about u In my vimrc I have (for gVim 6.4, gVim 7.0) :imap u Each "u" goes back one line of text in the undo history. Note the "imap" instead of "inoremap". This way abbreviations st

Re: Marking an undo-block before ^U in insert-mode

2007-02-23 Thread Andy Wokula
Yakov Lerner schrieb: On 2/20/07, Tim Chase <[EMAIL PROTECTED]> wrote: I'm trying to find a good way to remap control+U in insert-mode so that it begins an undo-block. There are times when type control+U in insert-mode and it doesn't do what I intend, or I want to undo it, only to find that an

Re: Go to start of visual selection

2007-02-07 Thread Andy Wokula
Tim Chase schrieb: >> vnoremap gt `>:exec 'norm '.visualmode().'`' >> vnoremap gb `:exec 'norm '.visualmode().'`>' > > I don't understand why this works. > > There must be a difference between > `>v`< > and > :normal `>v`< > > "v" defines a new visual area and overwrites the `<

Re: break option lines

2007-02-06 Thread Andy Wokula
[EMAIL PROTECTED] schrieb: Hello, is it possible in a vimrc for comma separated option strings like this one below to break: set dictionary=$VIM\SQLDict\BPMS_Stamm.txt,$VIM\SQLDict\BPMS_Mandant.txt,$VIM\SQL Dict\CBS_2005.txt,$VIM\SQLDict\ICCS_Net_Strommixer.txt,$VIM\SQLDict\DBS.txt,$ VIM\SQLDic

Re: Tips which are spam

2007-02-05 Thread Andy Wokula
John Beckett schrieb: Andy Wokula wrote: Currently there is much spam in recent comments: http://vim.sourceforge.net/tips/recent_notes.php Last time this was discussed I got the impression that there is a feeling that if no one reads the spam, then it is not a problem. But I think the

Re: Tips which are spam

2007-02-05 Thread Andy Wokula
Currently there is much spam in recent comments: http://vim.sourceforge.net/tips/recent_notes.php Andy -- EOF ___ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de

Re: Go to start of visual selection

2007-02-04 Thread Andy Wokula
Tim Chase schrieb: How can I move the cursor the start of the visual selection? With the "o" command, yes. But how can I make sure the cursor is at the start while visual mode is on? The "`<" motion followed by "gv" sets the cursor back to the end if it was there. I think it sounds like you w

Re: Go to start of visual selection

2007-02-04 Thread Andy Wokula
Tim Chase schrieb: How can I move the cursor the start of the visual selection? With the "o" command, yes. But how can I make sure the cursor is at the start while visual mode is on? The "`<" motion followed by "gv" sets the cursor back to the end if it was there. I think it sounds like you w

Go to start of visual selection

2007-02-01 Thread Andy Wokula
How can I move the cursor the start of the visual selection? With the "o" command, yes. But how can I make sure the cursor is at the start while visual mode is on? The "`<" motion followed by "gv" sets the cursor back to the end if it was there. Thx, Andy -- EOF

Re: A doubt with "syntax region"

2007-01-25 Thread Andy Wokula
DervishD schrieb: Hi all :)) I'm trying to fully understand the syntax commands, and when doing tests a question popped up in my mind: let's say I have a region which starts with something like "\I\i*{" and ends with "}". For example, the example below will match: strange{contents}

Re: change filenames before vim reads buffer

2007-01-25 Thread Andy Wokula
Tom Whittock schrieb: Hi. I'm running the vim under cygwin, and have set up my build process to execute via :make. This is great, but the build process reports filenames in DOS format, not the cygwin /cygdrive/* way. This means that when a quickfix command runs, vim will be asked to open "C:\dev

Re: how to NOT save history

2007-01-16 Thread Andy Wokula
Luis A. Florit schrieb: Pals, How I avoid certain commands and/or substitutions NOT to be saved into the history list? For example, I have a sequence of VIM commands that executes on every email quote to properly format it, and I don't want these to appear in the registries and history.

Re: how to NOT save history

2007-01-16 Thread Andy Wokula
Luis A. Florit schrieb: Pals, How I avoid certain commands and/or substitutions NOT to be saved into the history list? For example, I have a sequence of VIM commands that executes on every email quote to properly format it, and I don't want these to appear in the registries and history.

Re: enclosing a visual block with quotes

2007-01-14 Thread Andy Wokula
Bram Kuijper schrieb: Hi, I tried to use the following tip on enclosing a visual block with quotes in vim: http://schlitt.info/applications/blog/index.php?/archives/331-Comfortable-PHP-editing-with-VIM-3.html "Sometimes you want to include text you already typed text into braces or (more l

Re: C++ Syntax highlighting for Identifier, Statement

2007-01-14 Thread Andy Wokula
Matt England schrieb: I'm trying to get function names, class names, objects, variables and similar things to appear as non-white text with 'syntax on'. Had the same question after editing with Visual Studio. This is difficult, I haven't seen that before in any syntax file. I think there are no

Re: syntax for vcard/vcf files

2007-01-10 Thread Andy Wokula
Friedrich Strohmaier schrieb: Hello everybody, A happy new year to all vimmers. :o) I am looking for a syntax highlighting file for vcard/vcf files. Nor $searchengine nor vim.org could give me advice. Does somebody know about syntax highlighting for vcard/vcf files? Friedrich But there is a

Undo bug

2007-01-06 Thread Andy Wokula
Think I found a bug in the undo-branches behaviour, which cuts undo-states. Try this out: In a new buffer, insert `one' (or some other text), then in normal mode type `g-g-u', now insert `two' and type `g-g-u' again (ignore quotes `'). From now on it is not possible to get back the text states

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: combining two mapping into one

2006-10-08 Thread Andy Wokula
A.J.Mechelynck schrieb: > Kamaraju Kusumanchi wrote: >> On Friday 06 October 2006 08:24, Andy Wokula wrote: >>> Kamaraju Kusumanchi schrieb: >>>> I use two mappings for my Fortran (.f90) files >>>> >>>> map v%zf >>>> map zDv%zf

Re: combining two mapping into one

2006-10-06 Thread Andy Wokula
Kamaraju Kusumanchi schrieb: > I use two mappings for my Fortran (.f90) files > > map v%zf > map zDv%zf > > The idea is to create folds for code blocks which are of the form > > subroutine some_name_here >statements_here > end subroutine some_name_here > > Here F5 folds the subroutine blo

Re: Mapping of keysequences...

2006-10-02 Thread Andy Wokula
Meino Christian Cramer schrieb: > Thanks for all, Tony!!! :O) > > I think Bram should add > > :he Tony > > -support in vim which prints your email address... > or may be it is not what you really want, isn't ir ;O) > > (just kidding) > > Keep hacking! > mcc Add it yourself :e ~/.vim/d

Re: glued Cursor trick anyone ?

2006-09-21 Thread Andy Wokula
Tim Chase schrieb: > Generally, folks would get fired for writing stunts like the following, > so read with caution... > > Archived here: > http://permalink.gmane.org/gmane.editors.vim/38930 > > you'll find these two lines from my post: > > nnoremap / :exec('cnoremap <'.'cr> <'.'cr>:exec("cunmap

Re: Two """problems"""

2006-09-14 Thread Andy Wokula
Pete Johns schrieb: > " For all lines longer than 72 characters, reformat the > " paragraph from that line.. > 1,$g/.\{73,}/normal v}gq or just :set tw=72 " if set otherwise :g/./normal gqq Andy ___

Re: Deleting question

2006-09-13 Thread Andy Wokula
> why not > > :1;/Citations: /-1d > > of course, this is linewise, what's before "Citations: " in the same > line is not deleted. > > Andy oops, just overlooked Yakov's answer, sorry. Andy ___ Telefonate ohne weitere Ko

Re: Deleting question

2006-09-13 Thread Andy Wokula
Nikolaos A. Patsopoulos schrieb: > Hi, > > I'm trying to delete several lines from the beginning of file till the > appearance of a specific pattern, without deleting the pattern. I have > used the following command: > > :1,/Citations: /d/e-10 > > but the offset doesn't work. > > Thanks in adva

Re: Smarter Indent (an odd problem)

2006-09-06 Thread Andy Wokula
> Let me take this opportunity to try once again to drum up support > for an idea that I have proposed before. IMO it is too restrictive to > make options (such as syntax highlighting, 'textwidth', and > indent-related options) apply to a whole file. There should be a > convenient, consisten

Re: Contextual highlighting problem

2006-08-28 Thread Andy Wokula
Yongwei Wu schrieb: > I am trying to implement the COMMENT directive in the MASM syntax file: > > Treats all text between or on the same line as the delimiters as a comment. > > COMMENT delimiter [[text]] > [[text]] > [[text]] delimiter [[text]] > > The current way I deal with it is: > > syn ma

Re: language menu

2006-07-12 Thread Andy Wokula
Cesar Romani schrieb: > Normally the language of my vim's menu is Italian. > How can I change it to English? > Many thanks in advance, > > Cesar :set langmenu=none works for me. Put it early in your .vimrc, :help 'langmenu' says: "This option must be set before loading menus, switching on fil

Re: Remapping - how to get the count

2006-07-12 Thread Andy Wokula
Yakov Lerner schrieb: > On 7/8/06, Andy Wokula <[EMAIL PROTECTED]> wrote: >> I want to remap Ctrl-A (normal mode) to do something similar with other >> data, e.g. >> >> :nmap ciw=IncRoman(@-) >> >> Now if a count is provided this will mess up the t

Remapping - how to get the count

2006-07-08 Thread Andy Wokula
I want to remap Ctrl-A (normal mode) to do something similar with other data, e.g. :nmap ciw=IncRoman(@-) Now if a count is provided this will mess up the text, e.g. 10 does 10ciw... What is a good way to catch the count and make it available to the function call? TIA Andy