GetName returns the name that should be displayed in the statusline for this buffer
()
| 537 | // GetName returns the name that should be displayed in the statusline |
| 538 | // for this buffer |
| 539 | func (b *Buffer) GetName() string { |
| 540 | name := b.name |
| 541 | if name == "" { |
| 542 | if b.Path == "" { |
| 543 | return "No name" |
| 544 | } |
| 545 | name = b.Path |
| 546 | } |
| 547 | if b.Settings["basename"].(bool) { |
| 548 | return filepath.Base(name) |
| 549 | } |
| 550 | return name |
| 551 | } |
| 552 | |
| 553 | // SetName changes the name for this buffer |
| 554 | func (b *Buffer) SetName(s string) { |
no outgoing calls