Skip to content

Latest commit

 

History

History
89 lines (80 loc) · 2.26 KB

README.md

File metadata and controls

89 lines (80 loc) · 2.26 KB

A tabline plugin as a replacement to inbuilt one with icon and mouse support

Demo Gi

My other plugins


Installation

vim-plug

Plug 'mnjm/topline.nvim'
" Optional dependency for icons
Plug 'nvim-tree/nvim-web-devicons'

packer.nvim

use {
    'mnjm/topline.nvim',
    -- optional dependency for icons 
    requires = { 'nvim-tree/nvim-web-devicons', opt = true }
}

lazy.nvim

{
    'mnjm/topline.nvim'
    dependencies = { 'nvim-tree/nvim-web-devicons' }
}

Setup

To start topline, add below line in your neovim config

require("topline").setup()

Customization

You can pass custom config to override default configs to setup call, for ex

require('topline').setup({
  enable = true,
  -- seperator = { pre = '', post = '' },
  -- seperator = { pre = '', post = '' },
  seperator = { pre = '',  post = '' },
  close_icon = " 󰅘 ",
  highlights = {
    TopLineClose = { fg = "#d70000", bg = "#000000" },
  },
})

Available default configuration options

require('topline').setup({
  enable = true,
  seperator = { pre = '', post = '' },
  enable_icons = true,
  max_fname_len = 25,     -- max file name len
  close_icon = "[x]",
  highlights = {          -- highlights
    TopLine         = { link = 'TabLine' },               -- tab title
    TopLineSel      = { link = 'TabLineSel' },            -- tab title [Focused]
    TopLineFill     = { link = 'TabLineFill' },           -- filler
    TopLineClose    = { link = 'TabLineSel' },            -- close button
  },
})

You can force nvim to show tabline always by

In lua

vim.o.showtabline = 2

In vim

set showtabline=2

Demo Gi Demo SS Demo SS


License MIT