The main thing I displike about Vim emulation in editors like Atom or Sublime is that they don't group window splits inside tabs.
Atom, for example, groups tabs inside of splits, which is completely a bad workflow that I like to avoid by using Vim. See this issue: https://github.com/atom/atom/issues/672
But, I noticed that in Oni vim, when I try to make a :tabnew, it doesn't show it in the tabs. 馃槩
And, if I try splitting windows, then click on Oni's tabs, it will change the buffer of the active split. 馃槩
This is moving away from Vim-style tabs and going towards Atom-style or Sublime-style tabs, which is 馃槩 .
It would be great for tabs to represent actual Vim/Neovim tabs.
Is there a setting for this?
I really admire the project, but I can't live without the splits-inside-tabs workflow.
Hi, if you set "tabs.mode": "tabs", in your config.js you'll get back Vim style tabs.
If they aren't good enough, there is also "tabs.mode": "native",, which is vim tabs as is, with no externalisation.
But as far as I know, setting "tabs" should be the same, just with Oni's prettier tab bar.
(ps to edit the config.js its in the <Meta+Shift+P> window under User Config)
@trusktr Please see this page to make Oni behave more like Vim: https://github.com/onivim/oni/wiki/How-To:-Make-Oni-closer-to-bare-Vim-experience
"tabs.mode": "tabs"
Cool, that's much better!
Seems like this should be the default, if Oni's goal is to make the transition from (neo)vim seamless. Would be great if :tabnew just worked as expected out of the box (and the docs explain the tab options well to make it flexible).
there is also
"tabs.mode": "native",
I tried this one too, but even if I set showtabline=2, the native tabline never shows up. Do I have to do something else? (I love the awesome GUI tabs, but was just curious that the native tabs weren't showing up.)
Seems like this should be the default, if Oni's goal is to make the transition from (neo)vim seamless. Would be great if :tabnew just worked as expected out of the box (and the docs explain the tab options well to make it flexible).
Thats where it gets a bit awkward, since Oni wants to get new people into Vim as well as giving a UI for those that want a vim experience without the limits of a terminal UI.
There is a bit of a discussion around this over in #992, but it basically comes down to balancing it towards new users. That said we should also add some easier ways of swapping back, ie there is a ticket about checking for an init.vim and offering to load it if found, we could do some similar startup procedure to ask if the user wants to user vim tabs.
I tried this one too, but even if I set showtabline=2, the native tabline never shows up. Do I have to do something else? (I love the awesome GUI tabs, but was just curious that the native tabs weren't showing up.)
Hmmm, that may be a bug then. What I'd expect to see is something like below

You'll need to reload Oni between changing those settings, since we need to restart the neovim instance to get it to stop externalising the tabline, but apart from that it should work.
The default for Oni tabs now has swapped to be in-line with Vim tabs, so the first part of this issue is now fixed at least!
Are you still having issues with the non-externalised tabline?
Minor note, I was using tabs.mode=tab (instead of tabs) and didn't realize this is an invalid value, so it silently defaulted to the buffer-per-tab mode.
Thats where it gets a bit awkward, since Oni wants to get new people into Vim as well as giving a UI for those that want a vim experience without the limits of a terminal UI.
Vim has made various attempts over the years to make things "like normal users want them":
evim),gdefault, andIt becomes an uncanny valley.
If something is truly broken, it should be removed. Otherwise: the user's goal was to learn (the good parts of) vim, right?
Anyways, I'm glad tabs.mode=tabs is the default now :)
Minor note, I was using tabs.mode=tab (instead of tabs) and didn't realize this is an invalid value, so it silently defaulted to the buffer-per-tab mode.
Ah ya, good point, we need to be better about catching those silent errors. We might want to add a set of allowable values to our configuration metadata.
Vim has made various attempts over the years to make things "like normal users want them":
"easy mode" (evim),
gdefault, and
netrw's clumsy attempts to feel like Windows (throwing out vim conventions).
It becomes an uncanny valley.
For sure! I think one of the biggest challenges of this project is balancing users expectations on both sides (coming from Atom/VSCode vs coming from terminal vim). There are some sort of zero-cost things we can add, like mouse support, but some other decisions lean more one way vs the other.
I think for tabs, initially I thought it had to inherently be a trade-off too - but with the defaults we have now, I feel it strikes a decent balance for both cases. For a veteran vim user, they see the tablines and expect it to behave as vim tabs, which it does. For a user coming from VSCode/Atom/etc, when they open files from the fuzzy finder, by default, it opens in a new vim tabpage, which is their expectation coming from UI - they might not even realize it's a 'vim tab' under the hood.
I'm always concerned about the _uncanny valley_ - that's the worst place we could end up, where neither veteran vim users or users new to vim are happy 馃槃 But I'm glad you're happy with this change @justinmk !
Since the default mode is tabs now, seems like the issue is fixed.
Most helpful comment
Hi, if you set
"tabs.mode": "tabs",in yourconfig.jsyou'll get back Vim style tabs.If they aren't good enough, there is also
"tabs.mode": "native",, which is vim tabs as is, with no externalisation.But as far as I know, setting
"tabs"should be the same, just with Oni's prettier tab bar.(ps to edit the
config.jsits in the<Meta+Shift+P>window underUser Config)