Oni: Tabs: Implement scrollbar when there is overflow

Created on 4 Aug 2017  路  8Comments  路  Source: onivim/oni

The case when there is an 'overflow' (too many tabs) isn't handled today.

There should be the following:

  • A minimal scrollbar to allow easy navigating via the mouse, if desired
  • Focusing the proper tab - so even if you navigate via keyboard, that would get scrolled into view.
bug

All 8 comments

Instead of a scrollbar, is it possible to make the tabs container wrapping in to more lines than one? Like flexbox + flex-wrap. I know that behavior of IntelliJ and really liked it. With a scrollbar you not see all your opened tabs. Probably it is a problem that the editor space gets smaller so a render cycle in NVim must be triggered?

@hoschi - interesting idea! I didn't think about this. Yes, it would definitely be doable, we'd just have it overflow to the next row.

Perhaps we could make it an option - I think I would prefer the look of a single-line of tabs, but I could see where some would prefer this. Thanks for the suggestion!

@extr0py great :+1:
Yeah, I think some people want to stick to the default vim behavior. An option would be good.

You can also make the tabs shrink Chrome-style with Flexbox as a first measure before scrolling kicks in. I'd be glad to submit a PR if you're happy with the idea.

That sounds great @Shou, a PR would be awesome if you're up for it!

Can we make this configurable? My point of wrapping tabs was to show always the full name.

@Shou when you use flexbox for shrinking can you add wrapping with flex-wrap in one go?

Looks like the work this issue was tracking is complete - having both scrollbar + wrapping behavior. I'll cose this, but we can use a new issue to track the tab-shrinking option, if desired.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tcoopman picture tcoopman  路  3Comments

grz8 picture grz8  路  3Comments

badosu picture badosu  路  3Comments

bryphe picture bryphe  路  3Comments

Siilwyn picture Siilwyn  路  3Comments