Commit Graph

394 Commits (a117163a4cf598e391b7750a19ee5fd187d6263e)

Author SHA1 Message Date
Chris Allegretta a117163a4c 2009-01-19 Chris Allegretta <chrisa@asty.org>
* Change funcion definitions to shorts instead of (void *)s.  New mapping function
          iso_me_harder_funcmap().  Fixes compilation complaints with -pedantic, 
          reported by Eitan Adler <eitanadlerlist@gmail.com>.



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4349 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2009-01-19 19:10:39 +00:00
Chris Allegretta 1d77823f79 * global.c, help.c, browser.c, files.c, proto.h: Fix several compipation and programmatic
issues with --disable-help, especially that do-writeout was treating ^G the same as ^M.



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4317 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-08-30 21:00:00 +00:00
Chris Allegretta 6b83e5290c 2008-08-29 Chris Allegretta <chrisa@asty.org>
* configure.ac, color.c, rcfile.c, utils.c: 1st attempt at supporting systems which don't support
          GNU-style word boundaries.  New function fixbounds() to translate from GNU-style to
          BSD-style, autoconf option GNU_WORDBOUNDS.



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4315 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-08-30 05:16:20 +00:00
Chris Allegretta 14c8620e0b - Change add_undo and current_undo to only take action arg, as openfilestruct arg is always openfile
- Add ability to undo a file/cmd insert, needed to add undoable flag to read_file and open_buffer as a result



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4291 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-08-03 04:48:05 +00:00
Chris Allegretta 91a1862eed Add undoing argument to do_cut_text as we don't want to be messing around with the undo contents when we're in the
middle of an undo.



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4285 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-08-01 03:50:20 +00:00
Chris Allegretta 12dc8cae80 Commit back some undo/redo rewrites
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4283 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-07-31 04:24:04 +00:00
Chris Allegretta 07fcc4c973 Add beginning undo feature, since I want to start fixing bugs from savannah and don't want to manager another checking, and the code basically works for some operations.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4271 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-07-10 20:13:04 +00:00
Chris Allegretta 1b6ed07543 Add a fix for bug #23144 that actually works (several bugs in one here)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4264 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-06-03 08:09:05 +00:00
Chris Allegretta 8b6461fc80 files.c,proto.h,text.c: Fix for conflicts with AIX curses variables, from William Jojo <jojowil@hvcc.edu>
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4260 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-05-31 23:09:40 +00:00
Chris Allegretta 10f868d33c - Update man page a little bit more
- Change do_prompt and get_prompt_line to pass meta_key and func_key
  so the calling program can DTRT when it calsl get_shortcut.  In
  particular this allows the "new file buffer" toggle on the insert file
  menu to work, and presumably other rebinding stuff should now work also.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4226 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-03-14 04:08:51 +00:00
Chris Allegretta 0018d8ed6f - Fix tiny mode again after breaking it again
- Resurrect IFSCHELP to get rid of some needless help message stubs
- Add support for rebinding the suspend key
- Fix wrong refresh help message


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4224 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-03-13 08:23:52 +00:00
Chris Allegretta eb64314f8b Convert more code to use new backend. Add some more sentinel strings
for enter and backspace keys in case their control key alternates get
rebound.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4223 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-03-12 04:44:14 +00:00
Chris Allegretta e347efb9ff More keybinding fixes
- Fix tiny mode compilation problems
- Fix F-keys not working (silly typo)
- Change file browser to use new backend
- global.c - new helper function sc_seq_or, makes logic simpler down in the functions than calling first_sc_for directly


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4218 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-03-09 02:52:40 +00:00
Chris Allegretta 79a33bb38d New keybindings code and backend. New structs subnfunc for menu functions
and toggles and sc for shortcut keys, old 'shortcut' and 'toggles' structs are
gone.  The current implementation has a bunch of broken stuff (some of which is
documented in BUGS).  Updated nanorc.5 with some mostly complete documentation
on configuring.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4215 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2008-03-05 07:34:01 +00:00
David Lawrence Ramsey f78bc85db1 revert last changes, but disable all the same features that
--enable-tiny does when --with-slang is used


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4204 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-12-18 15:55:48 +00:00
David Lawrence Ramsey 7f6f5a64fb simplify terminal handling by using raw mode instead of cbreak mode
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4202 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-12-18 02:03:00 +00:00
David Lawrence Ramsey 6e6c80b181 in username_tab_completion() and cwd_tab_completion(), rename variable
buflen to buf_len, for consistency


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4175 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-10-11 15:38:32 +00:00
David Lawrence Ramsey d8a1d37161 update copyright notices, as Chris Allegretta's copyrights have now been
assigned to the Free Software Foundation; also, make copyright notices
consistent in style


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4173 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-10-11 05:01:32 +00:00
David Lawrence Ramsey c9694b7636 update copyright notices, as my copyrights have now been assigned to the
Free Software Foundation


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4172 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-10-05 16:44:45 +00:00
David Lawrence Ramsey d0035b4ab2 convert to GPLv3 or later
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4147 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-08-11 05:17:36 +00:00
David Lawrence Ramsey ae46b91b7e in nstrcasestr(), mbstrcasestr(), revstrstr(), revstrcasestr(), and
mbrevstrcasestr(), return char* instead of const char*


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4126 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-07-06 13:44:13 +00:00
David Lawrence Ramsey 3a5eaeb401 various mouse support-related simplifications, improvements, and fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4107 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-05-20 23:41:56 +00:00
David Lawrence Ramsey 4154d08362 miscellaneous minor fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4028 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-01-11 21:36:29 +00:00
David Lawrence Ramsey 0ec34ac28a make regexp_init() return a bool instead of an int
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4023 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-01-09 23:35:02 +00:00
David Lawrence Ramsey 6335fb54d5 miscellaneous comment fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4012 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2007-01-01 05:15:32 +00:00
David Lawrence Ramsey 4fd1ca07a7 more comment fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3976 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-11-27 05:09:16 +00:00
David Lawrence Ramsey 81371020bb revert erroneous changes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3973 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-11-27 04:56:16 +00:00
David Lawrence Ramsey 50d78a6f9a don't allow filenames entered at the "Write File" prompt or the "Insert
File" prompt to contain nulls


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3971 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-11-27 02:41:59 +00:00
David Lawrence Ramsey cb801d63a3 cosmetic copyright notice fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3950 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-11-10 02:47:11 +00:00
David Lawrence Ramsey fa38795ef5 miscellaneous minor fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3854 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-08-26 16:50:51 +00:00
David Lawrence Ramsey bd28ee472b when DISABLE_HELP is defined, leave out some unused shortcut and toggle
list parameters


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3815 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-25 21:13:30 +00:00
David Lawrence Ramsey 1b4ae6997e in parse_escape_seq_kbinput(), Don't ignore escape sequences anymore;
instead, return the corresponding key so that parse_kbinput() can
translate it


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3814 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-25 19:23:35 +00:00
David Lawrence Ramsey 5370b0cd19 in parse_escape_seq_kbinput(), handle unknown and unignored escape
sequences once instead of handling them twice in parse_kbinput()


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3807 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-23 17:54:35 +00:00
David Lawrence Ramsey b08c9f004c revert erroneous change
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3776 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-11 18:12:24 +00:00
David Lawrence Ramsey 87b37bde9b add miscellaneous minor cleanups to do_browser(), do_browse_from(), and
browser_init()


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3775 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-11 17:25:12 +00:00
David Lawrence Ramsey 2c36e2eb00 consolidate do_scroll_(up|down)() into do_(up|down)(), as they have a
lot of common code


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3763 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-06 22:17:47 +00:00
David Lawrence Ramsey aee00d4d14 if the mark isn't on, allow Meta-} and Meta-{ to indent and unindent
only the current line, just as it would if the mark covered only the
current line, instead of displaying a statusbar message and quitting


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3758 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-05 18:42:22 +00:00
David Lawrence Ramsey 2f7c1a0613 calculate width in browser_init(), as it's more consistent
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3741 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-05 02:05:24 +00:00
David Lawrence Ramsey b520d509cc still more cosmetic fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3740 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-05 01:13:19 +00:00
David Lawrence Ramsey c0ba4bf3e0 simplify and remove redundancies from various bits
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3739 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-07-05 01:10:18 +00:00
David Lawrence Ramsey 0457eb97af comment fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3712 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-30 22:34:10 +00:00
David Lawrence Ramsey a43b10854f add more miscellaneous cleanups
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3711 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-30 22:28:37 +00:00
David Lawrence Ramsey a4e92c8ad6 in striponedir(), return the stripped path instead of modifying path
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3704 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-30 14:14:40 +00:00
David Lawrence Ramsey d04037760d in do_browser(), after entering "..", select the directory we were in
before instead of the first filename in the list, as Pico does; add new
function browser_select_filename() to help do this properly


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3698 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-30 06:41:31 +00:00
David Lawrence Ramsey 5c878088a1 in update_line(), remove unneeded assert, and now-unused function
check_linenumbers()


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3676 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-21 16:54:51 +00:00
David Lawrence Ramsey 503bad02fe disable mouse support while suspended
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3655 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-09 18:24:37 +00:00
David Lawrence Ramsey f102208c05 don't display "Unknown Command" on the statusbar if we get an unknown
escape sequence at the statusbar prompt


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3631 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-08 02:01:49 +00:00
David Lawrence Ramsey b5a7bbf4f3 remove the workaround for glibc 2.2.3's broken regexec(), and replace it
with a FAQ entry explaining the problem, since it could break anything
using extended regular expressions, and glibc 2.2.3 is old


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3624 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-05 15:41:23 +00:00
David Lawrence Ramsey f70f67bd10 more miscellaneous minor fixes
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3615 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-06-03 17:31:52 +00:00
David Lawrence Ramsey a8239c313d another cosmetic fix
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3594 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
2006-05-28 22:24:03 +00:00