On Sat, Jun 15, 2002 at 09:46:38AM -0700, Keith Morse wrote: > For a line by line case, the only solution I've come up > with is to copy the string :s/HTML/CSS/ with the mouse and paste it > (middle button) each time I need it.
Oh, no, there are several approaches. The simplest would be to do a search for HTML: :/HTML<enter> (<enter> is, of course, the enter key); then issue the command: 4sCSS<enter> Thereafter simply strike / to find the string again, and . to repeat the substitution. (Note that I did '4s' instead of 'cw', since I presume you'd want to catch the string even if it's not surrounded by whitespace.) You could also write a macro on-the-fly to change and find the next in one swell foop: :map V 4sCSS^M/^M (Note that you enter the ^M by striking CTRL-V, then the enter key.) After this, during that editing session, while in edit mode if you strike V, it'll change the current string and find the next one without changing it. Another V will repeat the cycle, and so on. (Why V? Why not?) Cheers, -- Dave Ihnat [EMAIL PROTECTED] _______________________________________________ Redhat-list mailing list [EMAIL PROTECTED] https://listman.redhat.com/mailman/listinfo/redhat-list