X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=cmd%2Fmicro%2Ftab.go;h=941e787aac56619ce4e3d9302c1d46b45b31b275;hb=97e2fb12883b10002e7b08feef3110495d22bb4a;hp=be1f364f981d955142c4270b65c249ace9e1fd2e;hpb=57c030d3b99aa0fa1d7c2e92b41601171a575391;p=micro.git diff --git a/cmd/micro/tab.go b/cmd/micro/tab.go index be1f364f..941e787a 100644 --- a/cmd/micro/tab.go +++ b/cmd/micro/tab.go @@ -2,7 +2,6 @@ package main import ( "sort" - "path/filepath" "github.com/zyedidia/tcell" ) @@ -90,15 +89,17 @@ func TabbarString() (string, map[int]int) { } else { str += " " } - //To address issue 556.2 - _, name := filepath.Split(t.views[t.CurView].Buf.GetName()) - str += name + buf := t.views[t.CurView].Buf + str += buf.GetName() + if buf.IsModified { + str += " +" + } if i == curTab { str += "]" } else { str += " " } - indicies[len(str)-1] = i + 1 + indicies[Count(str)-1] = i + 1 str += " " } return str, indicies