vim-devicons
vim-devicons copied to clipboard
colorize ctrlP icons
hey, thx for the great work!
i want to ask if it is possible to color the icons shown in ctrlp?
@divramod Thanks I really appreciate that! :smile:
It is possible but I think this suggested change would make it a lot easier: https://github.com/ctrlpvim/ctrlp.vim/pull/316
I know you are asking specifically about ctrlp but if you use NERDTree you'd like this: https://github.com/tiagofumo/vim-nerdtree-syntax-highlight
@HerringtonDarkholme any thoughts?
cc @tiagofumo (just in case you had some thoughts :smile:)
I didn't even know that icons show up in ctrlp, because mine don't. I tried configuring it just now, to see if I could make it to work, but I couldn't. My guess is that doing something similar to what I did for NERDTree is going to cause a lot of lag, given that I already have some complaints about lag on my plugin.
PS: I love you @ryanoasis, lol. Sometimes I get worried about "sounding" rude to people that are cool to me, so I just want to point that out hahaha. #jokes
@tiagofumo Oh you can't see the icons in ctrlp? Can I ask what mode you are in? They should show up in mru or file mode (not buffer currently -- that was breaking ctrlp integration).
:laughing: Love right back to ya! :smile: No worries here from my side, I am pretty chill and but I have learned that a lot of people on GitHub (or online in general) are... how you say very direct.
thx for the feedback guys. i have the colouring already running for nerdtree and it looks awesome. so as it looks like we have to wait for the landing of https://github.com/ctrlpvim/ctrlp.vim/pull/316 But the pull request is already 6 month old ;-/
@divramod since this https://github.com/ctrlpvim/ctrlp.vim/pull/316 has been merged, is it working for you now?
This can be done by adding syntax/ctrlp.vim
to runtime path. I don't have time for OSS for a while so I hope I can find syntax file I created years ago...
@her Yes it works, I confirm! @HerringtonDarkholme @ryanoasis This ticket should be closed. For those looking for how to use coloring, please add filetype "ctrlp" in the auto command filetype list for answers on this thread: https://github.com/ryanoasis/vim-devicons/issues/158. I am using the solution posted by user "zeorin" on that thread, and no it does not cause any performance issues. @tiagofumo And for why it causes performance issues for NERDtree: it does only if I scroll in a file while NERDtree window is open. I tested this with (CPU performance/temperature monitor) If I toggle the NERDtree window and scroll a file, it doesn't have any effect. IMHO, it could be a bug in the implementation of NERDtree that refreshes the NERDtree buffer when other files are being scrolled, causing it to redo pattern matches for coloring, etc. Otherwise, given its contents or their position is not changing, NERDtree shouldn't cause slowdown in scrolling of other files. I have implemented GUIs in past, though am new to Vimscript, so can't really help in its debug.
I didn't even know that icons show up in ctrlp, because mine don't. I tried configuring it just now, to see if I could make it to work, but I couldn't. My guess is that doing something similar to what I did for NERDTree is going to cause a lot of lag, given that I already have some complaints about lag on my plugin.
PS: I love you @ryanoasis, lol. Sometimes I get worried about "sounding" rude to people that are cool to me, so I just want to point that out hahaha. #jokes
Laod the CtrlP plugin before vim-devicons.
thx!