diff --git a/ChangeLog b/ChangeLog index 0e601156e8b0bb8ff2bf7c2134e908092b7ff3cd..1c00bc87c3d2551354732e76717efcda2c767412 100644 --- a/ChangeLog +++ b/ChangeLog @@ -95,6 +95,7 @@ CVS code - toggle_init(), usage(), do_tab(), main(), nanorc.sample, nano.1, nanorc.5, and nano.texi. (DLR, suggested by many people) + - Change the SMOOTHSCROLL flag to the SMOOTH_SCROLL flag. (DLR) - Change the NO_UTF8 flag to the USE_UTF8 flag, and reverse its meaning. (DLR) - chars.c: diff --git a/src/global.c b/src/global.c index 74b8cee927f645df3636e53bac3065d783d4768f..172dde9abfb364fd2d65a5bf8025ab2246976360 100644 --- a/src/global.c +++ b/src/global.c @@ -1138,7 +1138,7 @@ void toggle_init(void) toggle_init_one(TOGGLE_BACKUP_KEY, N_("Backup files"), BACKUP_FILE); toggle_init_one(TOGGLE_SMOOTH_KEY, N_("Smooth scrolling"), - SMOOTHSCROLL); + SMOOTH_SCROLL); toggle_init_one(TOGGLE_SMARTHOME_KEY, N_("Smart home key"), SMART_HOME); #ifdef ENABLE_COLOR diff --git a/src/move.c b/src/move.c index 5d82785b50e7f41f4c38e6be20bb9a319c95b135..06efd761080ac47e432cec967ee4fd6a35e61467 100644 --- a/src/move.c +++ b/src/move.c @@ -107,7 +107,7 @@ void do_page_up(void) /* If we're in smooth scrolling mode and there's at least one * page of text left, move the current line of the edit window * up a page. */ - if (ISSET(SMOOTHSCROLL) && current->lineno > editwinrows - 2) { + if (ISSET(SMOOTH_SCROLL) && current->lineno > editwinrows - 2) { int i; for (i = 0; i < editwinrows - 2; i++) current = current->prev; @@ -153,7 +153,7 @@ void do_page_down(void) /* If we're in smooth scrolling mode and there's at least one * page of text left, move the current line of the edit window * down a page. */ - if (ISSET(SMOOTHSCROLL) && current->lineno + editwinrows - 2 <= + if (ISSET(SMOOTH_SCROLL) && current->lineno + editwinrows - 2 <= filebot->lineno) { int i; for (i = 0; i < editwinrows - 2; i++) @@ -201,7 +201,7 @@ void do_up(void) if (current_y == 0) edit_scroll(UP, #ifndef NANO_SMALL - ISSET(SMOOTHSCROLL) ? 1 : + ISSET(SMOOTH_SCROLL) ? 1 : #endif editwinrows / 2); @@ -234,7 +234,7 @@ void do_down(void) if (current_y == editwinrows - 1) edit_scroll(DOWN, #ifndef NANO_SMALL - ISSET(SMOOTHSCROLL) ? 1 : + ISSET(SMOOTH_SCROLL) ? 1 : #endif editwinrows / 2); diff --git a/src/nano.c b/src/nano.c index fb81890fe1c4c1d6b3641278acd36ed11bcc6cf4..4fe5a60dbcf802929ce8d374e3ce75cd03497ceb 100644 --- a/src/nano.c +++ b/src/nano.c @@ -4255,7 +4255,7 @@ int main(int argc, char **argv) #endif #ifndef NANO_SMALL case 'S': - SET(SMOOTHSCROLL); + SET(SMOOTH_SCROLL); break; #endif case 'T': diff --git a/src/nano.h b/src/nano.h index 49f6dcabba299e68643b5331601d5343e35dad3c..005643448cd9e0bfbed03abd407c7064dd700e9c 100644 --- a/src/nano.h +++ b/src/nano.h @@ -290,7 +290,7 @@ typedef struct syntaxtype { #define CUT_TO_END (1<<13) #define REVERSE_SEARCH (1<<14) #define MULTIBUFFER (1<<15) -#define SMOOTHSCROLL (1<<16) +#define SMOOTH_SCROLL (1<<16) #define DISABLE_CURPOS (1<<17) /* Damn, we still need it. */ #define REBIND_DELETE (1<<18) #define NO_CONVERT (1<<19) diff --git a/src/rcfile.c b/src/rcfile.c index 779a8446c6b435a56ec73929757717bc0991ebac..f1808ac1dd0c21fb9fd5632cd1e0ac7787f75f99 100644 --- a/src/rcfile.c +++ b/src/rcfile.c @@ -81,7 +81,7 @@ const static rcoption rcopts[] = { {"rebinddelete", REBIND_DELETE}, #ifndef NANO_SMALL {"smarthome", SMART_HOME}, - {"smooth", SMOOTHSCROLL}, + {"smooth", SMOOTH_SCROLL}, #endif #ifndef DISABLE_SPELLER {"speller", 0}, diff --git a/src/winio.c b/src/winio.c index 2eca8c219b2e63dfb8ea327c29dc053957f23468..51dd9220640001c634e4ca9d1cc4bc0a78465593 100644 --- a/src/winio.c +++ b/src/winio.c @@ -3522,7 +3522,7 @@ void edit_refresh(void) * is no danger of getting an infinite loop. */ edit_update( #ifndef NANO_SMALL - ISSET(SMOOTHSCROLL) ? NONE : + ISSET(SMOOTH_SCROLL) ? NONE : #endif CENTER); else {