The attached patch fixes the indentation errors in text.c
text.c still has a mixture of tabs and spaces. This patch only uses spaces.
forwardWordAP() could be fixed completely wrt. tabs but I have kept this
patch minimal.
diff -r -U3 nedit.isj7/source/text.c nedit.isj8/source/text.c
--- nedit.isj7/source/text.c 2007-10-02 17:47:08.000000000 +0200
+++ nedit.isj8/source/text.c 2007-10-15 22:59:41.000000000 +0200
@@ -2496,7 +2496,7 @@
return;
if (insertPos == lineStart) {
ringIfNecessary(silent, w);
- return;
+ return;
}
pos = max(insertPos - 1, 0);
while (strchr(delimiters, BufGetCharacter(textD->buffer, pos)) != NULL &&
@@ -2604,7 +2604,7 @@
cancelDrag(w);
if (!TextDMoveRight(((TextWidget)w)->text.textD))
- ringIfNecessary(silent, w);
+ ringIfNecessary(silent, w);
checkMoveSelectionChange(w, event, insertPos, args, nArgs);
checkAutoShowInsertPos(w);
callCursorMovementCBs(w, event);
@@ -2618,7 +2618,7 @@
cancelDrag(w);
if (!TextDMoveLeft(((TextWidget)w)->text.textD))
- ringIfNecessary(silent, w);
+ ringIfNecessary(silent, w);
checkMoveSelectionChange(w, event, insertPos, args, nArgs);
checkAutoShowInsertPos(w);
callCursorMovementCBs(w, event);
@@ -2639,22 +2639,22 @@
return;
}
pos = insertPos;
- if (hasKey("tail", args, nArgs)) {
+ if (hasKey("tail", args, nArgs)) {
for (; pos<buf->length; pos++) {
- if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
- break;
+ if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
+ break;
}
if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
- pos = endOfWord((TextWidget)w, pos);
- }
- else {
+ pos = endOfWord((TextWidget)w, pos);
+ }
+ else {
if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
- pos = endOfWord((TextWidget)w, pos);
+ pos = endOfWord((TextWidget)w, pos);
for (; pos<buf->length; pos++) {
- if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
- break;
+ if (strchr(delimiters, BufGetCharacter(buf, pos)) == NULL)
+ break;
}
- }
+ }
TextDSetInsertPosition(textD, pos);
checkMoveSelectionChange(w, event, insertPos, args, nArgs);
checkAutoShowInsertPos(w);
--
NEdit Develop mailing list - [email protected]
http://www.nedit.org/mailman/listinfo/develop