Using the ↑ and ↓ directional arrow keys to to scroll up and down the page in the GNU info pages causes the info page viewer to unexpectedly jump to another node, this is really disorienting.
How can I scroll down through the page and just have the info viewer/pager stop when it gets to the top or the bottom, and then require a separate command to jump to a different node?
- 12,270
2 Answers
Posting as an answer, as requested.
Just don't use info to browse info pages. There is a standalone info browser named pinfo, and Emacs has, of course, its own Info Mode.
If you're using Vim you can also install the ref and ref-info plugins. ref is essentially a generic hypertext browser. It comes with plugins for a number of sources, such as man pages, perldoc, pydoc, etc., but not for info. ref-info is a plugin for ref that adds capability to browse info pages.
The combination ref+ref-info makes a decent info browser, with the only drawback that it can only search through the page it currently displays. A partial workaround for this problem is to tell the info backend to produce larger chunks before feeding them to ref-info, by adding this line to your vimrc:
let g:ref_info_cmd = 'info --subnodes -o -'
You'd then browse info pages like this:
:Ref info <page>
Of course, you can also use ref with the other sources (:Ref man <page> etc.). Read the manual for more information.
- 13,368
- 2
- 31
- 50
-
thanks for the great explanation. I agree with the
let g:ref_info_cmd = 'info --subnodes -o -'idea of bunching everything into a single page. I always use thezshman pages this way too, i.e. thezshman pages are broken into about 12 separate man pages, but I always loadman zshallfor doing regex searches, then once I know where the thing I want is, then load the specific man page e.g.man zshbuiltins– the_velour_fog Jun 29 '16 at 10:21
You can use Control-V to scroll-forward-page-only, and the reverse Meta-V or Escape-V for scroll-backward-page-only. These are listed in the h help page, but they are hard to spot.
- 51,383
-
thanks, I could use a half page scroll, like
C-dinless, but scrolling an entire page at a time is a bit disorienting. – the_velour_fog Jun 29 '16 at 08:59
infofiles. If you're comfortable with Vim and Vim plugins you can also install ref and ref-info and actually have a saneinfobrowser. – Satō Katsura Jun 29 '16 at 08:46pinfoI like it but it doesn't work forpinfo infowhich is one of the main index pages which I would use to drill down into more specific pages.pinfo infojust loads loadsman info. Also I couldn't work out how to jump to the next search match inpinfo– the_velour_fog Jun 29 '16 at 08:49pinfo info-stndrather thanpinfo info. Other than that however, well, I'm just a fellowinfohater, so don't expect me to try too hard to defendpinfo. :) Theref-infothing is pretty decent though. – Satō Katsura Jun 29 '16 at 08:53infopages are really made by and intended for emacs users. it looks like the ref-info is vim syntax definitions forinfopages. So is the idea you open info pages in vim - andref-infoplugin gives you ability to navigate? – the_velour_fog Jun 29 '16 at 09:01ref, which is a hypertext browser framework.refcomes with browsers for various sources (manpages,perldoc,pydoc, etc.), but not forinfo.ref-infois a plugin forrefthat adds support forinfo. Then you addlet g:ref_info_cmd='info --subnodes -o -'to your vimrc, and browseinfopages with:Ref info <page>. You'll probably need to spend some time configuring it. It's a very useful plugin. – Satō Katsura Jun 29 '16 at 09:09refandref-infoplugins for vim and it can jump to nodes nicely!. Still has the same problem as pinfo, I can't load the maininfo infopage, but I will keep playing and see if I can get it working. – the_velour_fog Jun 29 '16 at 09:21:Ref info info-stndthanks – the_velour_fog Jun 29 '16 at 09:24vinfois not than great. At some point I patched a number of problems with it, and it was still less than great. No such problems withref-info. – Satō Katsura Jun 29 '16 at 09:44vim-ref-infoimmediately has solved every problem I had trying to useinfopages. Ironically it converts each node to one massive man page format - which is kind of against the whole point of the info pages, but it works , it can be navigated up and down the nodes, everything,. If you want to copy paste your install instructions (from your previous comment) as an answer, I will accept it - its a bit vim centric but it will probably help other people – the_velour_fog Jun 29 '16 at 09:48let g:ref_info_cmd='info --subnodes -o -'. Remove it if you prefer many small pages instead. The larger pages are a lot easier to search though. This is the main problem withref-info: search is not as useful as with the originalinfo. – Satō Katsura Jun 29 '16 at 09:52