Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!dimacs.rutgers.edu!mips!spool.mu.edu!uunet!cacilj!jurgen From: jurgen@cacilj.UUCP (Jurgen Heymann) Newsgroups: comp.editors Subject: VI: Positioning the cursor ("|") from within a macro doesn't work. Keywords: vi cursor Message-ID: <1501@cacilj.UUCP> Date: 12 Jun 91 16:12:44 GMT Distribution: usa Organization: CACI Products Company, La Jolla, CA Lines: 28 I am trying to position the cursor on a specific column using a :map macro. When I enter the command string interactively everything works fine. When I define it as a :map macro however, the position command is not executed and the macro execution stops there at the "|". I also tried "\|" but that didn't help either. What can I do? I know I could just say "077l" to go to column 77 but that only works when there are no tabs in that line. What I really want application-wise is this: Since I have to write documentation in vi, and I edit passages sometimes, I want to have a command string that gives me 'full lines' again in a paragraph. Thus I need a command string that appends the next line to the current ("J") then goes to the right margin, goes to the beginning of the word there and splits the line at that point. When you have :map ^W J77|bi^M^[ ^W would fill up the current line and go to the next. Any ideas? Thanks -- Jurgen -- ---------------------------------------------------------------- Jurgen Heymann CACI Products jurgen@cacilj.cts.com 3344 N. Torrey Pines Ct La Jolla, CA 92037