Tabs in GVim 8.2

157 views
Skip to first unread message

Salman Halim

unread,
Dec 20, 2019, 3:15:02 PM12/20/19
to v...@vim.org
Hello,

I switched to GVim 8.2 (Windows 10) and no longer see the tab list at the top. I tried both my self-compiled version and the version with patch 24 off GitHub. I also tried two different computers, both with Windows 10. 

I've gone back to 8.1 because I rely upon multiple tabs in my daily workflow, but figured it would be worth finding out whether it was just something with my configuration. 

Thank you,

--

Salman

Tony Mechelynck

unread,
Dec 20, 2019, 4:26:40 PM12/20/19
to vim_use, v...@vim.org
I see tabs at the top even in gvim 8.2, but I'm using text-style tabs
in both vim and gvim, thanks to the following code in my vimrc (the
"if" wrapping avoids problems with versions earlier than Vim 7 but
also with limited featuresets of any version):

if has('windows') && exists('+tabline')
function MyTabLine()
let rv = ''
let i = 1
while i <= tabpagenr('$')
let rv .= '%#Normal#'
let icur = tabpagewinnr(i)
let imax = tabpagewinnr(i, '$')
let rv .= '%' . i . 'T'
let rv .= i . '|' . icur . ':' . imax . ' '
if i == tabpagenr()
let rv .= '%#NonText#'
else
let rv .= '%#SpecialKey#'
endif
let buf = fnamemodify(bufname(tabpagebuflist(i)[icur-1]),':t')
if buf == ""
let buf = '[NoName]'
endif
let rv .= buf . ' '
let i += 1
endwhile
let rv .= '%T%=%999X%#Error#X%#Normal#%X'
return rv
endfunction
set guioptions-=e
set tabline=%!MyTabLine()
set showtabline=2
endif


Best regards,
Tony.

Salman Halim

unread,
Dec 20, 2019, 4:39:42 PM12/20/19
to Vim Users


--

Salman

On Fri, Dec 20, 2019, 16:26 Tony Mechelynck <antoine.m...@gmail.com> wrote:
On Fri, Dec 20, 2019 at 9:15 PM Salman Halim <salma...@gmail.com> wrote:
>
> Hello,
>
> I switched to GVim 8.2 (Windows 10) and no longer see the tab list at the top. I tried both my self-compiled version and the version with patch 24 off GitHub. I also tried two different computers, both with Windows 10.
>
> I've gone back to 8.1 because I rely upon multiple tabs in my daily workflow, but figured it would be worth finding out whether it was just something with my configuration.
>
> Thank you,

I see tabs at the top even in gvim 8.2, but I'm using text-style tabs
in both vim and gvim, thanks to the following code in my vimrc (the
"if" wrapping avoids problems with versions earlier than Vim 7 but
also with limited featuresets of any version):

...

Best regards,
Tony.

Switching to non-gui tabs via removing e from &guioptions shows the non-gui tabs just fine. Interestingly, then adding e BACK shows the gui tabs. I just get an empty space otherwise. 

Would you mind trying the GUI tabs, please? You'd have to enable them in your vimrc because doing it after works for me, also, and wouldn't be representative of my experience. Should be as simple as not taking e out, I'm thinking. 

Thanks, Tony. 

Salam

Tony Mechelynck

unread,
Dec 20, 2019, 5:38:23 PM12/20/19
to vim_use
Adding back e in my vimrc on the line where it sets 'guioptions' (by
value rather than by increment) shows me GTK-style tabs in my gvim Big
build with GTK2 GUI. Since 'guitablabel' is (by default) empty, I see
Vim's default tab label on them. Then ":set go-=e" manually shows my
preferred text-style tabs, of narrower height, with the label defined
by the 'tabline' setting in my vimrc, as previously shown.

FWIW, this is the relevant section of my modified vimrc (where ¬ in
the comments means "not"); as a second test I completely commented
away the ":set guioptions=" line (resulting in the default aegimrLtT
value), and GTK-style tabs were still present.

" 'guioptions': GUI options
" !: run external commands (or the shell) in a terminal window
" ¬a: no autoselect for "+
" ¬P: ditto for "*
" ¬A: ditto for modeless selection
" c: use console dialogs (not popup dialogs) for simple choices
" ¬e: use text-style, tabs even in the GUI
" ¬f: use fork() to start the GUI
" i: use a GUI icon if possible
" m: menu bar is present
" ¬M: source $VIMRUNTIME/menu.vim
" g: inactive menuitems are shown (greyed-off)
" t: include tearoff menuitems
" T: include toolbar
" r: right-hand scrollbar is always present
" ¬R: not only when vertically split
" ¬l: left-hand scrollbar is not always present
" L: only when vertically split
" ¬b: no bottom scrollbar
" ¬h: bottom scrollbar is not limited to size of cursor line
" ¬v: do not force vertical button layout in dialogs
" p: do not include X11 pointer callbacks (required by some WMs)
" ¬F: don't add a Footer (Motif-only)
" set guioptions=!cgimrLtTp
set guioptions=!cegimrLtTp

Since I have no Windows system, I cannot compare this with what would
happen under Windows with the same vimrc.

Best regards,
Tony.

Tony Mechelynck

unread,
Dec 20, 2019, 5:47:57 PM12/20/19
to vim_use
P.S. Tested in 8.2.24 (Big) with GTK2 GUI on openSUSE Linux Leap 15.1
with GTK2 2.4.32 and XOrg 1.20.3

Salman Halim

unread,
Dec 20, 2019, 7:57:36 PM12/20/19
to Vim Users


On Fri, Dec 20, 2019, 17:47 Tony Mechelynck <antoine.m...@gmail.com> wrote:
P.S. Tested in 8.2.24 (Big) with GTK2 GUI on openSUSE Linux Leap 15.1
with GTK2 2.4.32 and XOrg 1.20.3

Might be a Windows only thing. I really appreciate your testing it. Thank you.

Salman

Salman Halim

unread,
Dec 22, 2019, 6:35:47 PM12/22/19
to Vim Users
Did anybody else notice this in Windows?

--

Salman

Ni Va

unread,
Dec 23, 2019, 8:32:45 AM12/23/19
to vim_use
Hi Salman,

Do you talk about the tab feature like in this screenshot ?
On Windows 10, compiled today in 32bit version 8.2 patch 33
Capture.PNG

Salman Halim

unread,
Dec 23, 2019, 9:18:10 AM12/23/19
to Vim Users
Yes, except that this is how it looks when I start up:

image.png

Note the blank line below the toolbar; on 8.1, this is how it looks:

image.png

I can get it to work by manually executing :set guioptions-=e guioptions+=e (not in the vimrc; has to be done after startup), but I don't know of another way to fix it. Simply adding new tabs doesn't do it.

Nothing changed in my configuration other than the switch to 8.2.

Thank you,

Salman

--
--
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+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/d7c223d0-dc82-4d6d-a05c-432880ea0507%40googlegroups.com.


--
 
Salman

I, too, shall something make and glory in the making.

Tekki

unread,
Dec 24, 2019, 4:48:32 AM12/24/19
to vim_use
If I open a single file the name of the file is in the header of the window and there is no empty line at the top. If I open a second tab the tabbar appears.
GVIM 8.2.12 on Windows 10 Pro 19041.1.

Tony Mechelynck

unread,
Dec 24, 2019, 5:25:43 AM12/24/19
to vim_use
On Tue, Dec 24, 2019 at 10:48 AM Tekki <te...@tekki.ch> wrote:
>
> If I open a single file the name of the file is in the header of the window and there is no empty line at the top. If I open a second tab the tabbar appears.
> GVIM 8.2.12 on Windows 10 Pro 19041.1.

To display the tab bar even if there is only one tab, :set showtabline=2
>
> Am Montag, 23. Dezember 2019 00:35:47 UTC+1 schrieb Salman Halim:
>>
>> Did anybody else notice this in Windows?

Best regards,
Tony.

Salman Halim

unread,
Dec 24, 2019, 6:21:25 PM12/24/19
to Vim Users
Hello,

Quick update: I just updated to 8.2.0037 and the problem has gone away. I looked through the list of patches, but couldn't figure out what was changed. However, I'm pleased it's gone.

Thanks to everybody who looked into it for me!

Best regards,

Salman

--
--
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+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages