Commit 37d594c1 authored by Chris Allegretta's avatar Chris Allegretta
Browse files

More bits left over from getting rid of pico mode, no more CLEAR_BACKUPSTRING,...

More bits left over from getting rid of pico mode, no more CLEAR_BACKUPSTRING, woo!  Also reodered flags to remove gaps


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1339 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 26 additions and 48 deletions
+26 -48
...@@ -275,14 +275,10 @@ void help_init(void) ...@@ -275,14 +275,10 @@ void help_init(void)
"for, then hit enter. If there is a match for the text you " "for, then hit enter. If there is a match for the text you "
"entered, the screen will be updated to the location of the " "entered, the screen will be updated to the location of the "
"nearest match for the search string.\n\n " "nearest match for the search string.\n\n "
"If using Pico Mode via the -p or --pico flags, the " "The previous search string will be shown in brackets after "
"Meta-P toggle, or a nanorc file, the previous search " "the Search: prompt. Hitting Enter without entering any text "
"string will be shown in brackets after the Search: prompt. " "will perform the previous search.\n\n The following function "
"Hitting Enter without entering any text will perform the " "keys are available in Search mode:\n\n");
"previous search. Otherwise, the previous string will be "
"placed before the cursor, and can be edited or deleted "
"before hitting enter.\n\n The following function keys are "
"available in Search mode:\n\n");
else if (currshortcut == goto_list) else if (currshortcut == goto_list)
ptr = _("Go To Line Help Text\n\n " ptr = _("Go To Line Help Text\n\n "
"Enter the line number that you wish to go to and hit " "Enter the line number that you wish to go to and hit "
...@@ -661,7 +657,6 @@ void usage(void) ...@@ -661,7 +657,6 @@ void usage(void)
#ifndef DISABLE_OPERATINGDIR #ifndef DISABLE_OPERATINGDIR
print1opt(_("-o [dir]"), _("--operatingdir=[dir]"), _("Set operating directory")); print1opt(_("-o [dir]"), _("--operatingdir=[dir]"), _("Set operating directory"));
#endif #endif
print1opt("-p", "--pico", _("Emulate Pico as closely as possible"));
#ifndef DISABLE_WRAPJUSTIFY #ifndef DISABLE_WRAPJUSTIFY
print1opt(_("-r [#cols]"), _("--fill=[#cols]"), _("Set fill cols to (wrap lines at) #cols")); print1opt(_("-r [#cols]"), _("--fill=[#cols]"), _("Set fill cols to (wrap lines at) #cols"));
#endif #endif
...@@ -2933,11 +2928,6 @@ void do_toggle(const toggle *which) ...@@ -2933,11 +2928,6 @@ void do_toggle(const toggle *which)
TOGGLE(which->flag); TOGGLE(which->flag);
switch (which->val) { switch (which->val) {
case TOGGLE_PICOMODE_KEY:
shortcut_init(0);
SET(CLEAR_BACKUPSTRING);
display_main_list();
break;
case TOGGLE_SUSPEND_KEY: case TOGGLE_SUSPEND_KEY:
signal_init(); signal_init();
break; break;
...@@ -3046,7 +3036,6 @@ int main(int argc, char *argv[]) ...@@ -3046,7 +3036,6 @@ int main(int argc, char *argv[])
#ifndef DISABLE_OPERATINGDIR #ifndef DISABLE_OPERATINGDIR
{"operatingdir", 1, 0, 'o'}, {"operatingdir", 1, 0, 'o'},
#endif #endif
{"pico", 0, 0, 'p'},
#ifndef DISABLE_WRAPJUSTIFY #ifndef DISABLE_WRAPJUSTIFY
{"fill", 1, 0, 'r'}, {"fill", 1, 0, 'r'},
#endif #endif
......
...@@ -222,29 +222,28 @@ typedef struct historyheadtype { ...@@ -222,29 +222,28 @@ typedef struct historyheadtype {
#define MARK_ISSET (1<<3) #define MARK_ISSET (1<<3)
#define CONSTUPDATE (1<<4) #define CONSTUPDATE (1<<4)
#define NO_HELP (1<<5) #define NO_HELP (1<<5)
#define NOFOLLOW_SYMLINKS (1<<7) #define NOFOLLOW_SYMLINKS (1<<6)
#define SUSPEND (1<<8) #define SUSPEND (1<<7)
#define NO_WRAP (1<<9) #define NO_WRAP (1<<8)
#define AUTOINDENT (1<<10) #define AUTOINDENT (1<<9)
#define SAMELINEWRAP (1<<11) #define SAMELINEWRAP (1<<10)
#define VIEW_MODE (1<<12) #define VIEW_MODE (1<<11)
#define USE_MOUSE (1<<13) #define USE_MOUSE (1<<12)
#define USE_REGEXP (1<<14) #define USE_REGEXP (1<<13)
#define REGEXP_COMPILED (1<<15) #define REGEXP_COMPILED (1<<14)
#define TEMP_OPT (1<<16) #define TEMP_OPT (1<<15)
#define CUT_TO_END (1<<17) #define CUT_TO_END (1<<16)
#define REVERSE_SEARCH (1<<18) #define REVERSE_SEARCH (1<<17)
#define MULTIBUFFER (1<<19) #define MULTIBUFFER (1<<18)
#define CLEAR_BACKUPSTRING (1<<20) #define DOS_FILE (1<<19)
#define DOS_FILE (1<<21) #define MAC_FILE (1<<20)
#define MAC_FILE (1<<22) #define SMOOTHSCROLL (1<<21)
#define SMOOTHSCROLL (1<<23) #define DISABLE_CURPOS (1<<22) /* Damn, we still need it */
#define DISABLE_CURPOS (1<<24) /* Damn, we still need it */ #define ALT_KEYPAD (1<<23)
#define ALT_KEYPAD (1<<25) #define NO_CONVERT (1<<24)
#define NO_CONVERT (1<<26) #define BACKUP_FILE (1<<25)
#define BACKUP_FILE (1<<27) #define NO_RCFILE (1<<26)
#define NO_RCFILE (1<<28) #define COLOR_SYNTAX (1<<27)
#define COLOR_SYNTAX (1<<29)
/* Control key sequences, changing these would be very very bad */ /* Control key sequences, changing these would be very very bad */
...@@ -385,7 +384,6 @@ know what you're doing */ ...@@ -385,7 +384,6 @@ know what you're doing */
#define TOGGLE_AUTOINDENT_KEY NANO_ALT_I #define TOGGLE_AUTOINDENT_KEY NANO_ALT_I
#define TOGGLE_SUSPEND_KEY NANO_ALT_Z #define TOGGLE_SUSPEND_KEY NANO_ALT_Z
#define TOGGLE_NOHELP_KEY NANO_ALT_X #define TOGGLE_NOHELP_KEY NANO_ALT_X
#define TOGGLE_PICOMODE_KEY NANO_ALT_P
#define TOGGLE_MOUSE_KEY NANO_ALT_M #define TOGGLE_MOUSE_KEY NANO_ALT_M
#define TOGGLE_CUTTOEND_KEY NANO_ALT_K #define TOGGLE_CUTTOEND_KEY NANO_ALT_K
#define TOGGLE_REGEXP_KEY NANO_ALT_R #define TOGGLE_REGEXP_KEY NANO_ALT_R
......
...@@ -110,14 +110,6 @@ int search_init(int replacing) ...@@ -110,14 +110,6 @@ int search_init(int replacing)
search_init_globals(); search_init_globals();
/* Clear the backupstring if we've changed from Pico mode to regular
mode */
if (ISSET(CLEAR_BACKUPSTRING)) {
free(backupstring);
backupstring = NULL;
UNSET(CLEAR_BACKUPSTRING);
}
if (backupstring == NULL) if (backupstring == NULL)
#ifndef NANO_SMALL #ifndef NANO_SMALL
backupstring = mallocstrcpy(backupstring, search_history.current->data); backupstring = mallocstrcpy(backupstring, search_history.current->data);
...@@ -131,7 +123,6 @@ int search_init(int replacing) ...@@ -131,7 +123,6 @@ int search_init(int replacing)
search_history.current = (historytype *)&search_history.next; search_history.current = (historytype *)&search_history.next;
#endif #endif
/* If using Pico messages, we do things the old fashioned way... */
if (last_search[0] != '\0') { if (last_search[0] != '\0') {
buf = charalloc(COLS / 3 + 7); buf = charalloc(COLS / 3 + 7);
/* We use COLS / 3 here because we need to see more on the line */ /* We use COLS / 3 here because we need to see more on the line */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment