* Ryan Ye <[email protected]> [091023 22:53]:
> > When the output of a shell command exceeds one page, the text
> > scrolls all the way to the end. Is there a way to have Vim only
> > display the first page and allow one to advance through the text a
> > page at a time like the More and Less pagers (without piping the
> > command through one of these pagers)?
>
> Try this
> your-text-output | vim -
I'm realizing I didn't describe my problem very clearly.
This is for the shell output within Vim. In my vimrc there is
map <leader> c be:!sdcv -n <cWORD><CR>
With a file open in Vim, placing the cursor over a given word and
hitting this mapping will cause its definition to be piped out into
Vim's command line area, causing it to expand up, pushing the text
file out of the way. A short definition with just a few lines will
push the text up a bit, say, 14 lines. If the definition is very
verbose, several pages can go by, pushing the textfile completely
out of the way and scrolling to the end of the definitions. This is
console Vim running in GNU Screen, so I end up having to use Screen's
scrollback to view all the definitions that flew by.
What I'm looking for is a way to have the output of this sort of
command push the text of the file being viewed up just 14 lines or so,
with the ability to then page through the definitions -- one 14-line
"page" at a time. Is this possible in Vim?
BTW, sdcv is the console version of the StarDict program:
http://sdcv.sourceforge.net/
TIA for any suggestions,
John
--
John Magolske
http://B79.net/contact
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---