aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md1
-rw-r--r--view.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index bc0d310..967f807 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -6,6 +6,7 @@
- fix a ~ being considered a special character in path patterns (except at the start)
- improvements to and clean-up of vis-open
- add Selection:remove() to lua API
+- fix bug where visual-line selections after view were considered visible
## [0.8] - 2022-11-01
diff --git a/view.c b/view.c
index 2788d85..afa0c0e 100644
--- a/view.c
+++ b/view.c
@@ -283,7 +283,7 @@ bool view_coord_get(View *view, size_t pos, Line **retline, int *retrow, int *re
size_t cur = view->start;
Line *line = view->topline;
- if (pos < view->start || pos > view->end) {
+ if (pos < view->start || pos >= view->end) {
if (retline) *retline = NULL;
if (retrow) *retrow = -1;
if (retcol) *retcol = -1;