From 85d95dfdddba7077257a5fa3eb6dd57caf12579f Mon Sep 17 00:00:00 2001 From: Michael Maves <100046241+codemicmaves@users.noreply.github.com> Date: Wed, 4 May 2022 16:13:40 -0400 Subject: fix(builtin.tags): custom filename width (#1842) --- lua/telescope/make_entry.lua | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'lua/telescope/make_entry.lua') diff --git a/lua/telescope/make_entry.lua b/lua/telescope/make_entry.lua index 8a83b6f..627d669 100644 --- a/lua/telescope/make_entry.lua +++ b/lua/telescope/make_entry.lua @@ -920,13 +920,16 @@ function make_entry.gen_from_ctags(opts) local display_items = { { remaining = true }, } + + local idx = 1 local hidden = utils.is_path_hidden(opts) if not hidden then - table.insert(display_items, 1, { width = 30 }) + table.insert(display_items, idx, { width = vim.F.if_nil(opts.fname_width, 30) }) + idx = idx + 1 end if opts.show_line then - table.insert(display_items, 1, { width = 30 }) + table.insert(display_items, idx, { width = 30 }) end local displayer = entry_display.create { -- cgit v1.2.3