GetEndOfLinePosition returns relative position for the end of this line.
()
| 431 | |
| 432 | // GetEndOfLinePosition returns relative position for the end of this line. |
| 433 | func (d *Document) GetEndOfLinePosition() int { |
| 434 | return len([]rune(d.CurrentLineAfterCursor())) |
| 435 | } |
| 436 | |
| 437 | func (d *Document) leadingWhitespaceInCurrentLine() (margin string) { |
| 438 | trimmed := strings.TrimSpace(d.CurrentLine()) |