This is controlled via MANPAGER.
Manual pages defaults to the pager of less -is.
You can just highlight the current selection:
man -P "less -isg" <command>
Or set the MANPAGER variable:
export MANPAGER="less -isg"
You could also use vim where the cursor is highlighted so the current selection will appear differently.:
man -P "sh -c \"col -b | vim -c 'set ft=man ts=8 nomod nolist nonu' \
-c 'nnoremap i <nop>' \
-c 'nnoremap <Space> <C-f>' \
-c 'noremap q :quit<CR>' -\"" <command>
Taken from Zameer Manji:
- ft=man enables the coloring of the man page.
- ts=8 ensures the width of tab characters matches less.
- nomod removes the modification warning when trying to quit.
- nonu removes line numbers.
- nolist disables listchars so trailing whitespace and extra tabs are not highlighted.
- nnoremap i ensures that we do not accidentally enter insert mode when viewing the man page.
Plus my own option to use space to paginate and quit with q:
-c 'nnoremap <Space> <C-f>'
-c 'noremap q :quit<CR>'
Set it as your default pager by adding it to your default profile:
export MANPAGER="sh -c \"col -b | vim -c 'set ft=man ts=8 nomod nolist nonu' \
-c 'nnoremap i <nop>' \
-c 'nnoremap <Space> <C-f>' \
-c 'noremap q :quit<CR>' -\""