aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Selection.h
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2023-01-16 09:07:09 +1100
committerNeil <nyamatongwe@gmail.com>2023-01-16 09:07:09 +1100
commit887da82073d4ab855a3ba95deaa652d475df21e2 (patch)
treed1d9d02e5915726b3bb21e5ef95da4507a42ec18 /src/Selection.h
parent8fe06c8d006a9f149a964f1a69b4f1230082ed00 (diff)
downloadscintilla-mirror-887da82073d4ab855a3ba95deaa652d475df21e2.tar.gz
Use intervals for drawing.
Diffstat (limited to 'src/Selection.h')
-rw-r--r--src/Selection.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Selection.h b/src/Selection.h
index 4cda65d97..bc0f2208a 100644
--- a/src/Selection.h
+++ b/src/Selection.h
@@ -81,6 +81,12 @@ struct SelectionSegment {
if (end < p)
end = p;
}
+ SelectionSegment Subtract(Sci::Position increment) const noexcept {
+ SelectionSegment ret(start, end);
+ ret.start.Add(-increment);
+ ret.end.Add(-increment);
+ return ret;
+ }
};
struct SelectionRange {