cap153_nvim/lua/lazy/plugins/topbar.lua
2025-10-12 15:15:27 +08:00

41 lines
916 B
Lua
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- ===
-- === 文件缓冲标签栏
-- ===
local map = require("core.keymap")
-- 在标签之间移动
map:cmd('tn', 'BufferLineCyclePrev')
map:cmd('ti', 'BufferLineCycleNext')
-- 移动标签的位置
map:cmd('tmn', 'BufferLineMovePrev')
map:cmd('tmi', 'BufferLineMoveNext')
-- 关闭标签貌似是neovim自带的完整命令bdelete
map:cmd('tq', 'bd')
return {
"akinsho/bufferline.nvim",
config = function()
require("bufferline").setup {
options = {
modified_icon = "",
buffer_close_icon = "×",
-- show_buffer_close_icons = false,
max_name_length = 14,
max_prefix_length = 13,
tab_size = 10,
indicator = {
style = "none",
},
},
}
end,
}
-- return {
-- 'akinsho/bufferline.nvim',
-- version = "*",-- 安装最新的稳定版
-- dependencies = 'kyazdani42/nvim-web-devicons',
-- config = function()
-- require("bufferline").setup {}
-- end
-- }