diff options
| author | Neil <nyamatongwe@gmail.com> | 2014-12-17 19:45:10 +1100 | 
|---|---|---|
| committer | Neil <nyamatongwe@gmail.com> | 2014-12-17 19:45:10 +1100 | 
| commit | 3cb12627268d09f6ea9608cd9d99994c36bf149c (patch) | |
| tree | 57c4948440fd6f19e90a6cae026ff000a8824fce | |
| parent | c00f641ebf31eafc77d72f87f825791b1b0efbf0 (diff) | |
| download | scintilla-mirror-3cb12627268d09f6ea9608cd9d99994c36bf149c.tar.gz | |
More natural looping over visual attributes.
| -rw-r--r-- | gtk/ScintillaGTK.cxx | 6 | 
1 files changed, 3 insertions, 3 deletions
| diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index 7ab638ada..61eba53c1 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -2387,7 +2387,7 @@ void ScintillaGTK::GetImeUnderlines(PangoAttrList *attrs, bool *normalInput) {  				glong start = attrunderline->start_index;  				glong end = attrunderline->end_index;  				PangoUnderline uline = (PangoUnderline)((PangoAttrInt *)attrunderline)->value; -				for (glong i=start+1; i <= end; ++i) { +				for (glong i=start; i < end; ++i) {  					switch (uline) {  					case PANGO_UNDERLINE_NONE:  						normalInput[i] = false; @@ -2417,7 +2417,7 @@ void ScintillaGTK::GetImeBackgrounds(PangoAttrList *attrs, bool *targetInput) {  			if (backcolor) {  				glong start = backcolor->start_index;  				glong end =  backcolor->end_index; -				for (glong i=start+1; i <= end; ++i) { +				for (glong i=start; i < end; ++i) {  					targetInput[i] = true;  // target converted  				}  			} @@ -2516,7 +2516,7 @@ void ScintillaGTK::PreeditChangedInlineThis() {  		// Display preedit characters, one by one  		glong imeCharPos[maxLenInputIME+1] = { 0 }; -		glong attrPos = 0; +		glong attrPos = -1; // Start at -1 to designate the last byte of one character.  		glong charWidth = 0;  		bool tmpRecordingMacro = recordingMacro; | 
