Like adding a -a flag to split-window/join-pane that says how many ancestor
cells above the current pane it should split at.  So 0 is the current pane,
1 would be one cell up, etc.  Maybe some sort of syntax for the root cell,
(or just a specify a very large number).  Would that be reasonable?

-FR.

On Thu, Nov 13, 2014 at 10:23 AM, Felix Rosencrantz <f.rosencra...@gmail.com
> wrote:

> That's great.
>
> I noticed this when I was trying to figure out if I could do a drop-down
> terminal like guake/tilda/etc.  This patch was a simple way to do it if
> there is only a single pane across the top, but not if the top is split
> with several panes.
>
> The TODO says it would be more correct to rename the split-window command
> to split-pane.  It would be useful to really have a command that actually
> did split/join at the window level, so there is an easy way to put a pane
> on the edge of a window with an arbitrarily complex layout.  To be more
> general, if it could be done at any level of the layout structure.
>
> Do you think either of those would be useful to add to tmux?  An actual
> split/join-window command or option to the existing commands. I know I
> would find that useful and have wanted that feature.
>
> -FR.
>
> On Wed, Nov 12, 2014 at 2:57 PM, Nicholas Marriott <
> nicholas.marri...@gmail.com> wrote:
>
>> Like it. Applied - thanks
>>
>> On Wed, Nov 12, 2014 at 09:40:03AM -0800, Felix Rosencrantz wrote:
>> >    This patch adds the -b flag to split-window, which is consistent
>> with the
>> >    -b flag of the join-window command.** I like this when I want to
>> create a
>> >    pane above the current pane.
>> >    -FR.
>>
>> > diff --git a/cmd-split-window.c b/cmd-split-window.c
>> > index f88b2f6..e09b5a3 100644
>> > --- a/cmd-split-window.c
>> > +++ b/cmd-split-window.c
>> > @@ -36,8 +36,8 @@ enum cmd_retval      cmd_split_window_exec(struct cmd
>> *, struct cmd_q *);
>> >
>> >  const struct cmd_entry cmd_split_window_entry = {
>> >       "split-window", "splitw",
>> > -     "c:dF:l:hp:Pt:v", 0, -1,
>> > -     "[-dhvP] [-c start-directory] [-F format] [-p percentage|-l size]
>> "
>> > +     "bc:dF:l:hp:Pt:v", 0, -1,
>> > +     "[-bdhvP] [-c start-directory] [-F format] [-p percentage|-l
>> size] "
>> >       CMD_TARGET_PANE_USAGE " [command]",
>> >       0,
>> >       cmd_split_window_exec
>> > @@ -144,7 +144,7 @@ cmd_split_window_exec(struct cmd *self, struct
>> cmd_q *cmdq)
>> >       if (*shell == '\0' || areshell(shell))
>> >               shell = _PATH_BSHELL;
>> >
>> > -     if ((lc = layout_split_pane(wp, type, size, 0)) == NULL) {
>> > +     if ((lc = layout_split_pane(wp, type, size, args_has(args, 'b')))
>> == NULL) {
>> >               cause = xstrdup("pane too small");
>> >               goto error;
>> >       }
>> > diff --git a/tmux.1 b/tmux.1
>> > index 032e5be..ddeac74 100644
>> > --- a/tmux.1
>> > +++ b/tmux.1
>> > @@ -1760,7 +1760,7 @@ is given and the selected window is already the
>> current window,
>> >  the command behaves like
>> >  .Ic last-window .
>> >  .It Xo Ic split-window
>> > -.Op Fl dhvP
>> > +.Op Fl bdhvP
>> >  .Op Fl c Ar start-directory
>> >  .Oo Fl l
>> >  .Ar size |
>> > @@ -1784,6 +1784,10 @@ and
>> >  .Fl p
>> >  options specify the size of the new pane in lines (for vertical split)
>> or in
>> >  cells (for horizontal split), or as a percentage, respectively.
>> > +The
>> > +.Fl b
>> > +option causes the new pane to be created to the left of or above
>> > +.Ar target-pane .
>> >  All other options have the same meaning as for the
>> >  .Ic new-window
>> >  command.
>>
>> >
>> ------------------------------------------------------------------------------
>> > Comprehensive Server Monitoring with Site24x7.
>> > Monitor 10 servers for $9/Month.
>> > Get alerted through email, SMS, voice calls or mobile push
>> notifications.
>> > Take corrective actions from your mobile device.
>> >
>> http://pubads.g.doubleclick.net/gampad/clk?id=154624111&iu=/4140/ostg.clktrk
>>
>> > _______________________________________________
>> > tmux-users mailing list
>> > tmux-users@lists.sourceforge.net
>> > https://lists.sourceforge.net/lists/listinfo/tmux-users
>>
>>
>
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
_______________________________________________
tmux-users mailing list
tmux-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tmux-users

Reply via email to