Loading ...
Sorry, an error occurred while loading the content.

137349Re: How can I open help in the current window?

Expand Messages
  • Thiago de Arruda
    Apr 23, 2013
    • 0 Attachment
      OK I finally managed to get fully working and will post here in case anyone is
      interested, just put the code in vimrc and you can quickly invoke help in the
      current window by pressing <leader>h:

      function! OpenHelpInCurrentWindow(topic)
      view $VIMRUNTIME/doc/help.txt
      setl filetype=help
      setl buftype=help
      setl nomodifiable
      exe 'keepjumps help ' . a:topic

      command! -nargs=? -complete=help Help call OpenHelpInCurrentWindow(<q-args>)

      nnoremap <silent> <leader>h :view +1 $VIMRUNTIME/doc/help.txt

      Thanks for everyone's tips

      You received this message from the "vim_use" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      You received this message because you are subscribed to the Google Groups "vim_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Show all 13 messages in this topic