aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Selection.h
diff options
context:
space:
mode:
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 c18e5c02e..b0c286866 100644
--- a/src/Selection.h
+++ b/src/Selection.h
@@ -98,6 +98,9 @@ struct SelectionRange {
bool operator ==(const SelectionRange &other) const {
return caret == other.caret && anchor == other.anchor;
}
+ bool operator <(const SelectionRange &other) const {
+ return caret < other.caret || ((caret == other.caret) && (anchor < other.anchor));
+ }
void Reset() {
anchor.Reset();
caret.Reset();
@@ -161,6 +164,9 @@ public:
void RemoveDuplicates();
void RotateMain();
bool Tentative() const { return tentativeMain; }
+ std::vector<SelectionRange> RangesCopy() const {
+ return ranges;
+ }
};
#ifdef SCI_NAMESPACE