Index: makefiles/Makefile.linux =================================================================== RCS file: /cvsroot/nedit/nedit/makefiles/Makefile.linux,v retrieving revision 1.11 diff -U5 -r1.11 Makefile.linux --- makefiles/Makefile.linux 20 May 2003 00:27:56 -0000 1.11 +++ makefiles/Makefile.linux 15 Aug 2004 13:18:34 -0000 @@ -1,7 +1,7 @@ # $Id: Makefile.linux,v 1.11 2003/05/20 00:27:56 n8gray Exp $ -CC=cc +CC=distcc AR=ar # For editres, add -DEDITRES to CFLAGS and -lXmu to LIBS # If using a Motif 2.1 compatible library (LessTif, OM) add # a '-lXp' in front of the -lXext in LIBS. You also drop the @@ -15,11 +15,11 @@ # -DREPLACE_SCOPE to the CFLAGS. See the README file for more information. # # To test if the Motif library exports the runtime version # add -DHAVE__XMVERSIONSTRING to CFLAGS # -CFLAGS=-O -I/usr/X11R6/include -DUSE_DIRENT -DUSE_LPR_PRINT_CMD +CFLAGS=-g -O2 -Wall -pedantic -I/usr/X11R6/include -DBUILD_UNTESTED_NEDIT -DHAVE__XMVERSIONSTRING -DUSE_DIRENT -DUSE_LPR_PRINT_CMD ARFLAGS=-urs LIBS= -L/usr/X11R6/lib -Wl,-Bstatic -lXm -Wl,-Bdynamic -lXp -lXpm -lXext -lXt -lSM -lICE -lX11 -lm Index: source/text.c =================================================================== RCS file: /cvsroot/nedit/nedit/source/text.c,v retrieving revision 1.48 diff -U5 -r1.48 text.c --- source/text.c 28 Jul 2004 18:02:03 -0000 1.48 +++ source/text.c 15 Aug 2004 13:21:16 -0000 @@ -4122,10 +4122,34 @@ XtWidgetToApplicationContext((Widget)w), w->text.cursorBlinkRate, cursorBlinkTimerProc, w); } /* +** Sets the caret to on or off and restart the caret blink timer. +** This could be used by other modules to modify the caret's blinking. +*/ +void ResetCursorBlink(TextWidget textWidget, Boolean startsBlanked) +{ + if (0 != textWidget->text.cursorBlinkRate) + { + if (0 != textWidget->text.cursorBlinkProcID) + { + XtRemoveTimeOut(textWidget->text.cursorBlinkProcID); + } + + startsBlanked + ? TextDBlankCursor(textWidget->text.textD) + : TextDUnblankCursor(textWidget->text.textD); + + textWidget->text.cursorBlinkProcID + = XtAppAddTimeOut(XtWidgetToApplicationContext((Widget) textWidget), + textWidget->text.cursorBlinkRate, cursorBlinkTimerProc, + textWidget); + } +} + +/* ** look at an action procedure's arguments to see if argument "key" has been ** specified in the argument list */ static int hasKey(const char *key, const String *args, const Cardinal *nArgs) { Index: source/text.h =================================================================== RCS file: /cvsroot/nedit/nedit/source/text.h,v retrieving revision 1.19 diff -U5 -r1.19 text.h --- source/text.h 21 Jul 2004 11:32:05 -0000 1.19 +++ source/text.h 15 Aug 2004 13:21:16 -0000 @@ -165,10 +165,11 @@ int TextLastVisiblePos(Widget w); char *TextGetWrapped(Widget w, int startPos, int endPos, int *length); const char *GetDefaultTranslations(void); XtActionsRec *TextGetActions(int *nActions); void ShowHidePointer(TextWidget w, Boolean hidePointer); +void ResetCursorBlink(TextWidget textWidget, Boolean startsBlanked); #ifdef VMS /* VMS linker doesn't like long names (>31 chars) */ #define HandleAllPendingGraphicsExposeNoExposeEvents HandlePendingExpNoExpEvents #endif /* VMS */ Index: source/window.c =================================================================== RCS file: /cvsroot/nedit/nedit/source/window.c,v retrieving revision 1.169 diff -U5 -r1.169 window.c --- source/window.c 12 Aug 2004 16:51:06 -0000 1.169 +++ source/window.c 15 Aug 2004 13:21:57 -0000 @@ -2238,10 +2238,12 @@ return text; } static void movedCB(Widget w, WindowInfo *window, XtPointer callData) { + TextWidget textWidget = (TextWidget) w; + if (window->ignoreModify) return; /* update line and column nubers in statistics line */ UpdateStatsLine(window); @@ -2249,10 +2251,13 @@ /* Check the character before the cursor for matchable characters */ FlashMatching(window, w); /* Check for changes to read-only status and/or file modifications */ CheckForChangesToFile(window); + + /* Start blinking the caret again. */ + ResetCursorBlink(textWidget, False); } static void modifiedCB(int pos, int nInserted, int nDeleted, int nRestyled, char *deletedText, void *cbArg) {