SelectTo selects from the current cursor location to the given location
(loc Loc)
| 399 | // SelectTo selects from the current cursor location to the given |
| 400 | // location |
| 401 | func (c *Cursor) SelectTo(loc Loc) { |
| 402 | if loc.GreaterThan(c.OrigSelection[0]) { |
| 403 | c.SetSelectionStart(c.OrigSelection[0]) |
| 404 | c.SetSelectionEnd(loc) |
| 405 | } else { |
| 406 | c.SetSelectionStart(loc) |
| 407 | c.SetSelectionEnd(c.OrigSelection[0]) |
| 408 | } |
| 409 | } |
| 410 | |
| 411 | // WordRight moves the cursor one word to the right |
| 412 | func (c *Cursor) WordRight() { |
no test coverage detected