I found this snippet online which is apparently a way to make vim a little faster if your terminal background is the same as what vim's is meant to be (right?)
" General colors if has('gui_running') || has('nvim') hi Normal guifg=#a89984 guibg=#282828 else " Set the terminal default background and foreground colors, thereby " improving performance by not needing to set these colors on empty cells. hi Normal guifg=NONE guibg=NONE ctermfg=NONE ctermbg=NONE let &t_ti = &t_ti . "\033]10;#a89984\007\033]11;#282828\007" let &t_te = &t_te . "\033]110\007\033]111\007" endif
I looked up
:help t_te and found out that these
t_te "put terminal in termcap mode", looking up
:help termcap didn't help me (I don't really understand what it is/means). Also looking up
:help & didn't help me understand why
t_ti etc. have had
I thought this kind of stuff
\033]... were escape codes so I also did
:helpgrep escape code but didn't find anything useful. Probably they're a part of the terminal/shell so not in vim's help, but then I don't know how to try to find out more about them.
Is someone able to explain what exactly the snippet is doing/how it does it?