aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc/tabpage.txt
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc/tabpage.txt')
-rw-r--r--runtime/doc/tabpage.txt35
1 files changed, 21 insertions, 14 deletions
diff --git a/runtime/doc/tabpage.txt b/runtime/doc/tabpage.txt
index 7f91fda9f4..f06a6bcc34 100644
--- a/runtime/doc/tabpage.txt
+++ b/runtime/doc/tabpage.txt
@@ -133,7 +133,10 @@ something else.
:tabclose + " close the next tab page
:tabclose 3 " close the third tab page
:tabclose $ " close the last tab page
-<
+ :tabclose # " close the last accessed tab page
+
+When a tab is closed the next tab page will become the current one.
+
*:tabo* *:tabonly*
:tabo[nly][!] Close all other tab pages.
When the 'hidden' option is set, all buffers in closed windows
@@ -159,6 +162,8 @@ something else.
" one
:tabonly 1 " close all tab pages except the first one
:tabonly $ " close all tab pages except the last one
+ :tabonly # " close all tab pages except the last
+ " accessed one
SWITCHING TO ANOTHER TAB PAGE:
@@ -181,6 +186,7 @@ gt *i_CTRL-<PageDown>* *i_<C-PageDown>*
:+2tabnext " go to the two next tab page
:1tabnext " go to the first tab page
:$tabnext " go to the last tab page
+ :tabnext # " go to the last accessed tab page
:tabnext $ " as above
:tabnext - " go to the previous tab page
:tabnext -1 " as above
@@ -190,10 +196,6 @@ gt *i_CTRL-<PageDown>* *i_<C-PageDown>*
{count}<C-PageDown>
{count}gt Go to tab page {count}. The first tab page has number one.
-CTRL-<Tab> *CTRL-<Tab>*
-CTRL-W g<Tab> *g<Tab>* *CTRL-W_g<Tab>*
-g<Tab> Go to previous (last accessed) tab page.
-
:tabp[revious] *:tabp* *:tabprevious* *gT* *:tabN*
:tabN[ext] *:tabNext* *CTRL-<PageUp>*
<C-PageUp> *<C-PageUp>* *i_CTRL-<PageUp>* *i_<C-PageUp>*
@@ -213,6 +215,9 @@ gT Go to the previous tab page. Wraps around from the first one
*:tabl* *:tablast*
:tabl[ast] Go to the last tab page.
+<C-Tab> *CTRL-<Tab>* *<C-Tab>*
+CTRL-W g<Tab> *g<Tab>* *CTRL-W_g<Tab>*
+g<Tab> Go to the last accessed tab page.
Other commands:
*:tabs*
@@ -245,6 +250,8 @@ REORDERING TAB PAGES:
:tabmove " move the tab page to the last
:$tabmove " as above
:tabmove $ " as above
+ :tabmove # " move the tab page after the last accessed
+ " tab page
:tabm[ove] +[N]
:tabm[ove] -[N]
@@ -366,24 +373,24 @@ pages and define labels for them. Then get the label for each tab page. >
for i in range(tabpagenr('$'))
" select the highlighting
if i + 1 == tabpagenr()
- let s .= '%#TabLineSel#'
+ let s ..= '%#TabLineSel#'
else
- let s .= '%#TabLine#'
+ let s ..= '%#TabLine#'
endif
" set the tab page number (for mouse clicks)
- let s .= '%' . (i + 1) . 'T'
+ let s ..= '%' .. (i + 1) .. 'T'
" the label is made by MyTabLabel()
- let s .= ' %{MyTabLabel(' . (i + 1) . ')} '
+ let s ..= ' %{MyTabLabel(' .. (i + 1) .. ')} '
endfor
" after the last tab fill with TabLineFill and reset tab page nr
- let s .= '%#TabLineFill#%T'
+ let s ..= '%#TabLineFill#%T'
" right-align the label to close the current tab page
if tabpagenr('$') > 1
- let s .= '%=%#TabLine#%999Xclose'
+ let s ..= '%=%#TabLine#%999Xclose'
endif
return s
@@ -446,14 +453,14 @@ windows in the tab page and a '+' if there is a modified buffer: >
" Append the number of windows in the tab page if more than one
let wincount = tabpagewinnr(v:lnum, '$')
if wincount > 1
- let label .= wincount
+ let label ..= wincount
endif
if label != ''
- let label .= ' '
+ let label ..= ' '
endif
" Append the buffer name
- return label . bufname(bufnrlist[tabpagewinnr(v:lnum) - 1])
+ return label .. bufname(bufnrlist[tabpagewinnr(v:lnum) - 1])
endfunction
set guitablabel=%{GuiTabLabel()}