change the SMOOTHSCROLL flag to the SMOOTH_SCROLL flag

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2692 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
David Lawrence Ramsey 2005-06-16 02:13:10 +00:00
parent 7a4aaa53a1
commit b2b6976bd9
7 changed files with 10 additions and 9 deletions

View File

@ -95,6 +95,7 @@ CVS code -
toggle_init(), usage(), do_tab(), main(), nanorc.sample, toggle_init(), usage(), do_tab(), main(), nanorc.sample,
nano.1, nanorc.5, and nano.texi. (DLR, suggested by many nano.1, nanorc.5, and nano.texi. (DLR, suggested by many
people) people)
- Change the SMOOTHSCROLL flag to the SMOOTH_SCROLL flag. (DLR)
- Change the NO_UTF8 flag to the USE_UTF8 flag, and reverse its - Change the NO_UTF8 flag to the USE_UTF8 flag, and reverse its
meaning. (DLR) meaning. (DLR)
- chars.c: - chars.c:

View File

@ -1138,7 +1138,7 @@ void toggle_init(void)
toggle_init_one(TOGGLE_BACKUP_KEY, N_("Backup files"), toggle_init_one(TOGGLE_BACKUP_KEY, N_("Backup files"),
BACKUP_FILE); BACKUP_FILE);
toggle_init_one(TOGGLE_SMOOTH_KEY, N_("Smooth scrolling"), toggle_init_one(TOGGLE_SMOOTH_KEY, N_("Smooth scrolling"),
SMOOTHSCROLL); SMOOTH_SCROLL);
toggle_init_one(TOGGLE_SMARTHOME_KEY, N_("Smart home key"), toggle_init_one(TOGGLE_SMARTHOME_KEY, N_("Smart home key"),
SMART_HOME); SMART_HOME);
#ifdef ENABLE_COLOR #ifdef ENABLE_COLOR

View File

@ -107,7 +107,7 @@ void do_page_up(void)
/* If we're in smooth scrolling mode and there's at least one /* 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 * page of text left, move the current line of the edit window
* up a page. */ * up a page. */
if (ISSET(SMOOTHSCROLL) && current->lineno > editwinrows - 2) { if (ISSET(SMOOTH_SCROLL) && current->lineno > editwinrows - 2) {
int i; int i;
for (i = 0; i < editwinrows - 2; i++) for (i = 0; i < editwinrows - 2; i++)
current = current->prev; 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 /* 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 * page of text left, move the current line of the edit window
* down a page. */ * down a page. */
if (ISSET(SMOOTHSCROLL) && current->lineno + editwinrows - 2 <= if (ISSET(SMOOTH_SCROLL) && current->lineno + editwinrows - 2 <=
filebot->lineno) { filebot->lineno) {
int i; int i;
for (i = 0; i < editwinrows - 2; i++) for (i = 0; i < editwinrows - 2; i++)
@ -201,7 +201,7 @@ void do_up(void)
if (current_y == 0) if (current_y == 0)
edit_scroll(UP, edit_scroll(UP,
#ifndef NANO_SMALL #ifndef NANO_SMALL
ISSET(SMOOTHSCROLL) ? 1 : ISSET(SMOOTH_SCROLL) ? 1 :
#endif #endif
editwinrows / 2); editwinrows / 2);
@ -234,7 +234,7 @@ void do_down(void)
if (current_y == editwinrows - 1) if (current_y == editwinrows - 1)
edit_scroll(DOWN, edit_scroll(DOWN,
#ifndef NANO_SMALL #ifndef NANO_SMALL
ISSET(SMOOTHSCROLL) ? 1 : ISSET(SMOOTH_SCROLL) ? 1 :
#endif #endif
editwinrows / 2); editwinrows / 2);

View File

@ -4255,7 +4255,7 @@ int main(int argc, char **argv)
#endif #endif
#ifndef NANO_SMALL #ifndef NANO_SMALL
case 'S': case 'S':
SET(SMOOTHSCROLL); SET(SMOOTH_SCROLL);
break; break;
#endif #endif
case 'T': case 'T':

View File

@ -290,7 +290,7 @@ typedef struct syntaxtype {
#define CUT_TO_END (1<<13) #define CUT_TO_END (1<<13)
#define REVERSE_SEARCH (1<<14) #define REVERSE_SEARCH (1<<14)
#define MULTIBUFFER (1<<15) #define MULTIBUFFER (1<<15)
#define SMOOTHSCROLL (1<<16) #define SMOOTH_SCROLL (1<<16)
#define DISABLE_CURPOS (1<<17) /* Damn, we still need it. */ #define DISABLE_CURPOS (1<<17) /* Damn, we still need it. */
#define REBIND_DELETE (1<<18) #define REBIND_DELETE (1<<18)
#define NO_CONVERT (1<<19) #define NO_CONVERT (1<<19)

View File

@ -81,7 +81,7 @@ const static rcoption rcopts[] = {
{"rebinddelete", REBIND_DELETE}, {"rebinddelete", REBIND_DELETE},
#ifndef NANO_SMALL #ifndef NANO_SMALL
{"smarthome", SMART_HOME}, {"smarthome", SMART_HOME},
{"smooth", SMOOTHSCROLL}, {"smooth", SMOOTH_SCROLL},
#endif #endif
#ifndef DISABLE_SPELLER #ifndef DISABLE_SPELLER
{"speller", 0}, {"speller", 0},

View File

@ -3522,7 +3522,7 @@ void edit_refresh(void)
* is no danger of getting an infinite loop. */ * is no danger of getting an infinite loop. */
edit_update( edit_update(
#ifndef NANO_SMALL #ifndef NANO_SMALL
ISSET(SMOOTHSCROLL) ? NONE : ISSET(SMOOTH_SCROLL) ? NONE :
#endif #endif
CENTER); CENTER);
else { else {