aboutsummaryrefslogtreecommitdiff
path: root/plugin/max-set-window-title.vim
blob: 1a84ac3428a3e645e5f3b48fc694807495c4025b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21


augroup SET_WINDOW_TITLE
    set title
    set titlelen=40

    " set window title for screen(3)
    " if &term == "screen" || &term == "xterm" 
    if &term == "screen"
        set t_ts=k
        set t_fs=\
    endif

    " autocmd BufEnter * let &titlestring = hostname() . "[vim(" . expand("%:t") . ")]"
    " autocmd CursorHold * let &titlestring = "%t %y ".$USER."@".hostname().":%{expand("%:~:.:h")}"
    " Fix terminal title =================================================================================================
    " autocmd VimEnter * let &t_EI .= "\<Esc>[0 q"
    " autocmd VimEnter * let &t_SI = "\<Esc>]12;green\x7"
    autocmd VimLeave * silent !echo -ne "\033]112\007"
augroup END

..