CursorStartDoc moves the cursor to the start of the text, updating selection if select mode is active
()
| 514 | // CursorStartDoc moves the cursor to the start of the text, updating selection |
| 515 | // if select mode is active |
| 516 | func (ed *Editor) CursorStartDoc() { |
| 517 | ed.validateCursor() |
| 518 | org := ed.CursorPos |
| 519 | ed.CursorPos.Ln = 0 |
| 520 | ed.CursorPos.Ch = 0 |
| 521 | ed.cursorColumn = ed.CursorPos.Ch |
| 522 | ed.setCursor(ed.CursorPos) |
| 523 | ed.scrollCursorToTop() |
| 524 | ed.renderCursor(true) |
| 525 | ed.cursorSelect(org) |
| 526 | ed.NeedsRender() |
| 527 | } |
| 528 | |
| 529 | // cursorEndLine moves the cursor to the end of the text |
| 530 | func (ed *Editor) cursorEndLine() { |
no test coverage detected