Commit Graph

26 Commits

Author SHA1 Message Date
agc eb7c1594f1 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22280, verified by myself.
2003-08-07 16:42:00 +00:00
christos 839ca00b3c From michael@moria.de:
- use __attribute__((__unused__)) in arguments where appropriate.
- some int -> size_t and char * to const char * conversions.
2003-06-19 15:55:05 +00:00
christos 687b5d51e3 s/u_int32_t/unsigned int/ 2003-03-10 21:18:49 +00:00
christos d10066b927 de-lint 2002-11-15 14:33:53 +00:00
christos 39f224af48 PR/18995: David Laight: libedit fixes for posix conformant sh
The posix 'sh' specification defines vi-mode editing quite tightly.
The netbsd libedit code (used by sh to do this) was missing several
features, there were also minor errors in others.

Compare netbsd sh to the definition available from:
http://www.opengroup.org/onlinepubs/007904975/utilities/sh.html
In particular the following were not supported:
	U - undo all changes to line
	| - goto column
	Y - yank to end of line
	y - yank
	# - comment out current line
	@ - take input from shell alias [1]
	G - goto numbered line in history buffer
	v - edit history line with vi
	_ - append word from last input line
	. - redo last command
Other minor changes have also been made.

[1] This needs the shell to define an appropriate routine to
return the text of the alias.  There is no requirement that
such a function exist.
2002-11-15 14:32:32 +00:00
thorpej f53bc0b607 Fix signed/unsigned comparison warnings. 2002-11-12 00:01:21 +00:00
christos a17c7fe4a6 vi mode and memory fixes from david laight. 2002-10-27 21:41:50 +00:00
christos 8572d89c2c PR/17954: SAITOH Masanobu: since we have opost and onlcr set, we don't need
to output \r to go to the end of line; \n is enough. From David Laight.
2002-10-27 20:04:36 +00:00
christos 0e0ac6b723 - constify; passes all gcc and lint strict checks.
- add config.h [Jason Evans], to create a portable version of libedit that
  can be easily compiled on other OS's.
2002-03-18 16:00:50 +00:00
lukem 4241f48b35 rename 3 arg ELRE_DEBUG to ELRE_ASSERT, add 2 arg ELRE_DEBUG, and change all
occurences of ELRE_DEBUG(foo,bar,) -> ELRE_DEBUG(foo,bar).  some compilers
(e.g, gcc on darwin) bitch about the former (`not enough args').
2001-04-13 00:53:11 +00:00
jdolecek 00ff7cacf5 Enlarge editline buffers as needed to support arbitrary length lines.
This also addresses lib/9712 by Phil Nelson.
2001-01-10 07:45:41 +00:00
lukem d30d584a91 convert to new style guide, which includes:
- ansi prototypes & features (such as stdargs)
- 8 space indents
2000-09-04 22:06:28 +00:00
soren 89c5a767f8 Fix doubled 'the's. 2000-03-13 22:55:05 +00:00
mycroft 05fc321ebf Fix refresh glitches when using auto-margin. 2000-02-19 09:08:16 +00:00
christos 0dded5f65c Add support for automatic and magic margins (from tcsh)
This makes the rightmost column usable on all programs
that use editline.
2000-01-20 22:56:21 +00:00
lukem 1f11bc4cc8 instead of using a private coord_t global variable to store the size of the
rprompt, use the previously unused coord_t el->el_rprompt.p_pos
1999-11-13 11:32:12 +00:00
lukem 509864fa8f - implement printing a right-side prompt. code derived from similar work
I wrote for tcsh(1) three years ago.
- implement EL_RPROMPT, which allows a setting/getting of a function which
  returns a string to be used as the right-side prompt.
- improve HISTORY and AUTHORS sections in editline(3).
- bump shlib minor version for EL_RPROMPT.

XXX: due to an implementation issue, the rprompt has a 1 space gap before the
     edge of the logical screen. editline's logical screen is 1 space less
     than the full screen width, so there's a 2 space gap between the rprompt
     and the right end of the physical screen. i'm not concerned about this.
1999-11-12 01:05:07 +00:00
jdolecek 7c714abab4 don't assume locales are not working - it may not be the case
re_refresh(): cast the character passed to re_addc() to unsigned char,
        so we don't end up calling isprint() with negative value
        when chars are signed and character value is >= 128
1999-10-15 17:01:19 +00:00
simonb 1528b77539 More trailing white space. 1999-07-02 15:14:07 +00:00
christos c3f0ff041d Make this compile under linux 1999-06-12 18:58:05 +00:00
christos 571b899770 delint. 1999-02-05 20:53:49 +00:00
christos a6d4afba22 delint 1998-12-12 20:08:21 +00:00
christos 32cdebd7ac cast is*() arg to unsigned char 1998-05-20 01:03:30 +00:00
christos 54fac6850e Fix compiler warnings. 1997-07-06 18:25:21 +00:00
lukem 2543e3e651 RCSid police
editline first appeared in 4.4BSD not NetBSD1.0
1997-01-11 06:47:47 +00:00
cgd 6dc2f1db52 libedit! 1994-05-06 06:01:42 +00:00