1

Given 2 absolute numbers (compatible with region-beginning, region-end).

How can these numbers be used to set the evil-mode line visual selection?

(note, I originally asked this question, but found its not compatible with evil-visual-line-mode)


This page looks like it's the same issue, but the solution doesn't apply here AFAICS.

ideasman42
  • 8,786
  • 1
  • 32
  • 114

1 Answers1

3

Evil offers two functions for creating regions, evil-visual-select and evil-visual-make-selection. You'll want the former as it accepts two locations, whereas the latter accepts values for point and mark. The following creates a visual line selection from point to end of buffer:

(evil-visual-select (point) (point-max) 'line)
wasamasa
  • 22,178
  • 1
  • 66
  • 99