Monday, February 28, 2011

Re: using the help system in split screen mode

On Sun, Feb 27, 2011 at 06:01:23PM EST, Ben Schmidt wrote:

>> When I am editing a file rather than displaying a help subject, I issue
>> a ':vhl topic' command (with vhl mapped to ':vertical help', and Vim
>> vertically splits the screen and displays the topic's help file in
>> a separate window, so that the buffer I am editing remains visible.
>>
>> Unfortunately, when I already have a help window open in the current
>> tab, this does not work.
>
> This is a little more complicated, but I'm sure you can :map or :command
> or :cabbrev it:
>
> :vnew | set bt=help | help subject

Thanks, Ben.. The bt=help is probably what I was looking for.

I'll set this up via a custom :Help command that will additionally take
care of removing the scratch buffers. And possibly add some logic that
counts the number of help windows in the current tab.. if zero: create
a new tab, if one: do a vertical split on the current tab.. and if two
or more... do horizontal splits.

Not very flexible but it should cover my limited needs.

How could I figure out the number of help windows in the current tab?

Thanks,

cj

--
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

No comments:

Post a Comment