152152 local cwd = utils .path_expand (opts .cwd or vim .loop .cwd ())
153153
154154 local disable_devicons = opts .disable_devicons
155+ local icon_separator = opts .icon_separator
155156
156157 local mt_file_entry = {}
157158
160161 local hl_group , icon
161162 local display , path_style = utils .transform_path (opts , entry .value )
162163
163- display , hl_group , icon = utils .transform_devicons (entry .value , display , disable_devicons )
164+ display , hl_group , icon = utils .transform_devicons (entry .value , display , disable_devicons , icon_separator )
164165
165166 if hl_group then
166167 local style = { { { 0 , # icon + 1 }, hl_group } }
273274 end
274275
275276 local disable_devicons = opts .disable_devicons
277+ local icon_separator = opts .icon_separator
276278 local disable_coordinates = opts .disable_coordinates
277279 local only_sort_text = opts .only_sort_text
278280
331333 local display , hl_group , icon = utils .transform_devicons (
332334 entry .filename ,
333335 string.format (display_string , display_filename , coordinates , entry .text ),
334- disable_devicons
336+ disable_devicons ,
337+ icon_separator
335338 )
336339
337340 if hl_group then
@@ -585,6 +588,7 @@ function make_entry.gen_from_buffer(opts)
585588 opts = opts or {}
586589
587590 local disable_devicons = opts .disable_devicons
591+ local icon_separator = opts .icon_separator or " "
588592
589593 local icon_width = 0
590594 if not disable_devicons then
@@ -598,6 +602,7 @@ function make_entry.gen_from_buffer(opts)
598602 { width = opts .bufnr_width },
599603 { width = 4 },
600604 { width = icon_width },
605+ { width = # icon_separator },
601606 { remaining = true },
602607 },
603608 }
@@ -614,6 +619,7 @@ function make_entry.gen_from_buffer(opts)
614619 { entry .bufnr , " TelescopeResultsNumber" },
615620 { entry .indicator , " TelescopeResultsComment" },
616621 { icon , hl_group },
622+ { icon_separator },
617623 {
618624 display_bufname .. " :" .. entry .lnum ,
619625 function ()
0 commit comments