From 41a4aaf6ac518707850beee6158ab232d1bf7d03 Mon Sep 17 00:00:00 2001 From: Neil Hodgson Date: Wed, 13 Sep 2017 11:27:44 +1000 Subject: Backport: Bug [#1971]. Fix line selection by clicking in the margin when scrolled. Backport of changeset 6389:96506cab38bd. --- src/Editor.cxx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/Editor.cxx b/src/Editor.cxx index 766d0fac2..80b1d7ad3 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -4320,6 +4320,8 @@ bool Editor::PointInSelMargin(Point pt) const { PRectangle rcSelMargin = GetClientRectangle(); rcSelMargin.right = static_cast(vs.textStart - vs.leftMarginWidth); rcSelMargin.left = static_cast(vs.textStart - vs.fixedColumnWidth); + const Point ptOrigin = GetVisibleOriginInMain(); + rcSelMargin.Move(0, -ptOrigin.y); return rcSelMargin.ContainsWholePixel(pt); } else { return false; -- cgit v1.2.3