Chris Allegretta [Sun, 21 Sep 2008 23:02:30 +0000 (23:02 +0000)]
2008-09-21 Chris Allegretta <chrisa@asty.org>
* rcfile.c, color.c, nano.h: Add new capability for matching a syntax type by the "header" (1st line)
of a file being edited. Based on Savannah bug 24197 and inital proof of concept by Dave Geering
<dgeering@toshiba-tap.com>
Chris Allegretta [Tue, 16 Sep 2008 21:35:19 +0000 (21:35 +0000)]
2008-09-16 Chris Allegretta <chrisa@asty.org>
* text.c: Add support for undoing a text uncut. Split out the undo and redo of a text cut
in order to avoid code duplication.
Chris Allegretta [Sat, 30 Aug 2008 21:00:00 +0000 (21:00 +0000)]
* 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.
Chris Allegretta [Sat, 30 Aug 2008 05:16:20 +0000 (05:16 +0000)]
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.
Chris Allegretta [Thu, 28 Aug 2008 06:13:05 +0000 (06:13 +0000)]
2008-08-28 Chris Allegretta <chrisa@asty.org>
* configure.ac, rcfile.c: Add support for an alternate rcfilename at configure time. Maybe this
should become a command line option some day, but I don't see the need currently. Start of
fix for Savannah bug #24128: Add nanorc support to win32 platform.
Chris Allegretta [Thu, 21 Aug 2008 04:21:06 +0000 (04:21 +0000)]
2008-08-21 Chris Allegretta <chrisa@asty.org>
* text.c: Change error messages where we may possibly get into a bad state and urge
the user to save when this happens. Originally by Benno Schulenberg <bensberg@justemail.net>
Chris Allegretta [Sun, 17 Aug 2008 16:25:40 +0000 (16:25 +0000)]
2008-08-08 Magnus Granberg <zorry@ume.nu> / Adam Conrad <?>
* files.c: (write_file): Add needed flags to open() calls when writing out files. Fixes Savannah bug
#23827: Compilation fails with -D_FORTIFY_SOURCE=2
Chris Allegretta [Sat, 16 Aug 2008 23:54:15 +0000 (23:54 +0000)]
* files.c (write_file): Check exit code of fclose(), since in certain out of space conditions the OS will
happily report successful fwrite()s until you try and close the file. Fix for Savannah bug
#24000: no free space on partition - nano claims successful write - file empty
* text.c: Reset openfile-> to OTHER after an undo or redo so we don't mistakenly
mistakenly think this is an update when it's really an add. Also
Fix an extra ; after an if statement which makes nano try to free a struct which
may be NULL
- 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
- When undoing a cut, set cutbuffer to NULL after freeing the current one
- When updating a normal consecutive ^K cut, bail from add_undo since it's not an add, and in update_undo free the old cutbuffer before copying it again.
Chris Allegretta [Sun, 13 Jul 2008 16:44:19 +0000 (16:44 +0000)]
Allow backspace to be bound to keys in .nanorc
Allow kdel to be rebound
Add note about rebinding kdel to backspace for those using OSX or PuTTY to connect to remote Linux machines in nanorc.sample.in
When undoing text deletes, move current_x to proper location
Chris Allegretta [Sat, 12 Jul 2008 02:20:16 +0000 (02:20 +0000)]
2008-07-11 Michael Haubenwallner <michael.haubenwallner@salomon.at>
* global.c: include proto.h earlier in file to fix AIX compilation
(Savannah patch 6559)
Chris Allegretta [Sat, 12 Jul 2008 02:13:22 +0000 (02:13 +0000)]
2008-07-11 Michael Haubenwallner <michael.haubenwallner@salomon.at>
* global.c: include proto.h earlier in file to fix AIX compilation
(Savannah patch 6559)
Chris Allegretta [Thu, 10 Jul 2008 20:13:04 +0000 (20:13 +0000)]
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.
Chris Allegretta [Sat, 31 May 2008 21:55:21 +0000 (21:55 +0000)]
New syntax highlighting from Mike F. Credits:
awk.nanorc by Donnie Berkholz <dberkholz@gentoo.org>
css.nanorc by Simon Rupf <simon.rupf@int-ag.ch>
xml.nanorc by Josef 'Jupp' Schugt <jupp@rubyforge.org>
Slight tweak by chrisa on the CSS file to make the brightwhite section end on line boundary due to matching too greedily on valid CSS
(see digg's css/111/global.css as an example)
Chris Allegretta [Thu, 20 Mar 2008 05:52:08 +0000 (05:52 +0000)]
Wow, I somehow did not run into the "invalid range" error
until after I committed, how does that work? Anyway, fix
the range error message for debian.nanorc.
Chris Allegretta [Fri, 14 Mar 2008 04:08:51 +0000 (04:08 +0000)]
- 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.
Chris Allegretta [Thu, 13 Mar 2008 08:23:52 +0000 (08:23 +0000)]
- 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
Chris Allegretta [Tue, 11 Mar 2008 03:03:53 +0000 (03:03 +0000)]
Fix bug 79, add sentinels for function keys in case the user
rebinds them to something else. Fix debug mode crash when the user
typos a menu name. Add menus for pageup and pagedown bindings and make
rebinding up and down actually do up and down and not page up and page down.
Fix workaround for user assigning a meta sequence to a key which has
a dedicated keyboard equivalent (arrows, home/end, page up/down, etc).
Not fully fixable so document the remaining issue in bug 79.
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
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.
Part 2 of commit since I accidentally did it in src/ the first time. Yeah,
welcome back bonehead.
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.