aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2012-02-15 10:50:02 +1100
committernyamatongwe <devnull@localhost>2012-02-15 10:50:02 +1100
commite9f19dc73287d101d234ae12733a35d9e8a831ef (patch)
treea437a00727895db4670214def1ecdabc578de03b /src
parentab0a84caf6a80667612dca9484c4f39e536a6413 (diff)
downloadscintilla-mirror-e9f19dc73287d101d234ae12733a35d9e8a831ef.tar.gz
Bug #3487440. Fix bug where setting an indicator on for whole document
had no effect since that was regarded as an empty indicator.
Diffstat (limited to 'src')
-rw-r--r--src/Decoration.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Decoration.cxx b/src/Decoration.cxx
index 24632d7c1..b489c3c02 100644
--- a/src/Decoration.cxx
+++ b/src/Decoration.cxx
@@ -28,7 +28,7 @@ Decoration::~Decoration() {
}
bool Decoration::Empty() {
- return rs.Runs() == 1;
+ return (rs.Runs() == 1) && (rs.AllSameAs(0));
}
DecorationList::DecorationList() : currentIndicator(0), currentValue(1), current(0),
@@ -148,7 +148,7 @@ void DecorationList::DeleteRange(int position, int deleteLength) {
void DecorationList::DeleteAnyEmpty() {
Decoration *deco = root;
while (deco) {
- if (deco->Empty()) {
+ if ((lengthDocument == 0) || deco->Empty()) {
Delete(deco->indicator);
deco = root;
} else {