1 This document details the changes between this version, readline-4.2,
2 and the previous version, readline-4.1.
6 a. When setting the terminal attributes on systems using `struct termio',
7 readline waits for output to drain before changing the attributes.
9 b. A fix was made to the history word tokenization code to avoid attempts to
10 dereference a null pointer.
12 c. Readline now defaults rl_terminal_name to $TERM if the calling application
13 has left it unset, and tries to initialize with the resultant value.
15 d. Instead of calling (*rl_getc_function)() directly to get input in certain
16 places, readline now calls rl_read_key() consistently.
18 e. Fixed a bug in the completion code that allowed a backslash to quote a
19 single quote inside a single-quoted string.
21 f. rl_prompt is no longer assigned directly from the argument to readline(),
22 but uses memory allocated by readline. This allows constant strings to
23 be passed to readline without problems arising when the prompt processing
24 code wants to modify the string.
26 g. Fixed a bug that caused non-interactive history searches to return the
27 wrong line when performing multiple searches backward for the same string.
29 h. Many variables, function arguments, and function return values are now
30 declared `const' where appropriate, to improve behavior when linking with
33 i. The control character detection code now works better on systems where
34 `char' is unsigned by default.
36 j. The vi-mode numeric argument is now capped at 999999, just like emacs mode.
38 k. The Function, CPFunction, CPPFunction, and VFunction typedefs have been
39 replaced with a set of specific prototyped typedefs, though they are
40 still in the readline header files for backwards compatibility.
42 m. Nearly all of the (undocumented) internal global variables in the library
43 now have an _rl_ prefix -- there were a number that did not, like
44 screenheight, screenwidth, alphabetic, etc.
46 n. The ding() convenience function has been renamed to rl_ding(), though the
47 old function is still defined for backwards compatibility.
49 o. The completion convenience functions filename_completion_function,
50 username_completion_function, and completion_matches now have an rl_
51 prefix, though the old names are still defined for backwards compatibility.
53 p. The functions shared by readline and bash (linkage is satisfied from bash
54 when compiling with bash, and internally otherwise) now have an sh_ prefix.
56 q. Changed the shared library creation procedure on Linux and BSD/OS 4.x so
57 that the `soname' contains only the major version number rather than the
58 major and minor numbers.
60 r. Fixed a redisplay bug that occurred when the prompt spanned more than one
61 physical line and contained invisible characters.
63 s. Added a missing `includedir' variable to the Makefile.
65 t. When installing the shared libraries, make sure symbolic links are relative.
67 u. Added configure test so that it can set `${MAKE}' appropriately.
69 v. Fixed a bug in rl_forward that could cause the point to be set to before
70 the beginning of the line in vi mode.
72 w. Fixed a bug in the callback read-char interface to make it work when a
73 readline function pushes some input onto the input stream with
74 rl_execute_next (like the incremental search functions).
76 x. Fixed a file descriptor leak in the history file manipulation code that
77 was tripped when attempting to truncate a non-regular file (like
80 y. Changes to make all of the exported readline functions declared in
81 readline.h have an rl_ prefix (rltty_set_default_bindings is now
82 rl_tty_set_default_bindings, crlf is now rl_crlf, etc.)
84 z. The formatted documentation included in the base readline distribution
85 is no longer removed on a `make distclean'.
87 aa. Some changes were made to avoid gcc warnings with -Wall.
89 bb. rl_get_keymap_by_name now finds keymaps case-insensitively, so
90 `set keymap EMACS' works.
92 cc. The history file writing and truncation functions now return a useful
95 dd. Fixed a bug that could cause applications to dereference a NULL pointer
96 if a NULL second argument was passed to history_expand().
98 ee. If a hook function assigned to rl_event_hook sets rl_done to a non-zero
99 value, rl_read_key() now immediately returns '\n' (which is assumed to
100 be bound to accept-line).
102 2. New Features in Readline
104 a. The blink timeout for paren matching is now settable by applications,
105 via the rl_set_paren_blink_timeout() function.
107 b. _rl_executing_macro has been renamed to rl_executing_macro, which means
108 it's now part of the public interface.
110 c. Readline has a new variable, rl_readline_state, which is a bitmap that
111 encapsulates the current state of the library; intended for use by
112 callbacks and hook functions.
114 d. rlfe has a new -l option to log input and output (-a appends to logfile),
115 a new -n option to set the readline application name, and -v and -h
116 options for version and help information.
118 e. rlfe can now perform filename completion for the inferior process if the
119 OS has a /proc/<PID>/cwd that can be read with readlink(2) to get the
120 inferior's current working directory.
122 f. A new file, rltypedefs.h, contains the new typedefs for function pointers
123 and is installed by `make install'.
125 g. New application-callable function rl_set_prompt(const char *prompt):
126 expands its prompt string argument and sets rl_prompt to the result.
128 h. New application-callable function rl_set_screen_size(int rows, int cols):
129 public method for applications to set readline's idea of the screen
132 i. The history example program (examples/histexamp.c) is now built as one
135 j. The documentation has been updated to cover nearly all of the public
136 functions and variables declared in readline.h.
138 k. New function, rl_get_screen_size (int *rows, int *columns), returns
139 readline's idea of the screen dimensions.
141 l. The timeout in rl_gather_tyi (readline keyboard input polling function)
142 is now settable via a function (rl_set_keyboard_input_timeout()).
144 m. Renamed the max_input_history variable to history_max_entries; the old
145 variable is maintained for backwards compatibility.
147 n. The list of characters that separate words for the history tokenizer is
148 now settable with a variable: history_word_delimiters. The default
151 o. There is a new history.3 manual page documenting the history library.
153 -------------------------------------------------------------------------------
154 This document details the changes between this version, readline-4.1,
155 and the previous version, readline-4.0.
157 1. Changes to Readline
159 a. Changed the HTML documents so that the table-of-contents is no longer
162 b. Changes to the shared object configuration for: Irix 5.x, Irix 6.x,
165 c. The shared library major and minor versions are now constructed
166 automatically by configure and substituted into the makefiles.
168 d. It's now possible to install the shared libraries separately from the
171 e. The history library tries to truncate the history file only if it is a
174 f. A bug that caused _rl_dispatch to address negative array indices on
175 systems with signed chars was fixed.
177 g. rl-yank-nth-arg now leaves the history position the same as when it was
180 h. Changes to the completion code to handle MS-DOS drive-letter:pathname
183 i. Completion is now case-insensitive by default on MS-DOS.
185 j. Fixes to the history file manipulation code for MS-DOS.
187 k. Readline attempts to bind the arrow keys to appropriate defaults on MS-DOS.
189 l. Some fixes were made to the redisplay code for better operation on MS-DOS.
191 m. The quoted-insert code will now insert tty special chars like ^C.
193 n. A bug was fixed that caused the display code to reference memory before
194 the start of the prompt string.
196 o. More support for __EMX__ (OS/2).
198 p. A bug was fixed in readline's signal handling that could cause infinite
199 recursion in signal handlers.
201 q. A bug was fixed that caused the point to be less than zero when rl_forward
202 was given a very large numeric argument.
204 r. The vi-mode code now gets characters via the application-settable value
205 of rl_getc_function rather than calling rl_getc directly.
207 s. The history file code now uses O_BINARY mode when reading and writing
208 the history file on cygwin32.
210 t. Fixed a bug in the redisplay code for lines with more than 256 line
213 u. A bug was fixed which caused invisible character markers to not be
214 stripped from the prompt string if the terminal was in no-echo mode.
216 v. Readline no longer tries to get the variables it needs for redisplay
217 from the termcap entry if the calling application has specified its
218 own redisplay function. Readline treats the terminal as `dumb' in
221 w. Fixes to the SIGWINCH code so that a multiple-line prompt with escape
222 sequences is redrawn correctly.
224 x. Changes to the install and install-shared targets so that the libraries
225 and header files are installed separately.
227 2. New Features in Readline
229 a. A new Readline `user manual' is in doc/rluserman.texinfo.
231 b. Parentheses matching is now always compiled into readline, and enabled
232 or disabled when the value of the `blink-matching-paren' variable is
235 c. MS-DOS systems now use ~/_inputrc as the last-ditch inputrc filename.
237 d. MS-DOS systems now use ~/_history as the default history file.
239 e. history-search-{forward,backward} now leave the point at the end of the
240 line when the string to search for is empty, like
241 {reverse,forward}-search-history.
243 f. history-search-{forward,backward} now leave the last history line found
244 in the readline buffer if the second or subsequent search fails.
246 g. New function for use by applications: rl_on_new_line_with_prompt, used
247 when an application displays the prompt itself before calling readline().
249 h. New variable for use by applications: rl_already_prompted. An application
250 that displays the prompt itself before calling readline() must set this to
253 i. A new variable, rl_gnu_readline_p, always 1. The intent is that an
254 application can verify whether or not it is linked with the `real'
255 readline library or some substitute.
257 j. Per Bothner's `rlfe' (pronounced `Ralphie') readline front-end program
258 is included in the examples subdirectory, though it is not built
261 -------------------------------------------------------------------------------
262 This document details the changes between this version, readline-4.0,
263 and the previous version, readline-2.2.
265 1. Changes to Readline
267 a. The version number is now 4.0, to match the major and minor version
268 numbers on the shared readline and history libraries. Future
269 releases will maintain the identical numbering.
271 b. Fixed a typo in the `make install' recipe that copied libreadline.a
272 to libhistory.old right after installing it.
274 c. The readline and history info files are now installed out of the source
275 directory if they are not found in the build directory.
277 d. The library no longer exports a function named `savestring' -- backwards
278 compatibility be damned.
280 e. There is no longer any #ifdef SHELL code in the source files.
282 f. Some changes were made to the key binding code to fix memory leaks and
283 better support Win32 systems.
285 g. Fixed a silly typo in the paren matching code -- it's microseconds, not
288 h. The readline library should be compilable by C++ compilers.
290 i. The readline.h public header file now includes function prototypes for
291 all readline functions, and some changes were made to fix errors in the
292 source files uncovered by the use of prototypes.
294 j. The maximum numeric argument is now clamped at 1000000.
296 k. Fixes to rl_yank_last_arg to make it behave better.
298 l. Fixed a bug in the display code that caused core dumps if the prompt
299 string length exceeded 1024 characters.
301 m. The menu completion code was fixed to properly insert a single completion
302 if there is only one match.
304 n. A bug was fixed that caused the display code to improperly display tabs
307 o. A fix was made to the completion code in which a typo caused the wrong
308 value to be passed to the function that computed the longest common
309 prefix of the list of matches.
311 p. The completion code now checks the value of rl_filename_completion_desired,
312 which is set by application-supplied completion functions to indicate
313 that filename completion is being performed, to decide whether or not to
314 call an application-supplied `ignore completions' function.
316 q. Code was added to the history library to catch history substitutions
317 using `&' without a previous history substitution or search having been
321 2. New Features in Readline
323 a. There is a new script, support/shobj-conf, to do system-specific shared
324 object and library configuration. It generates variables for configure
325 to substitute into makefiles. The README file provides a detailed
326 explanation of the shared library creation process.
328 b. Shared libraries and objects are now built in the `shlib' subdirectory.
329 There is a shlib/Makefile.in to control the build process. `make shared'
330 from the top-level directory is still the right way to build shared
331 versions of the libraries.
333 c. rlconf.h is now installed, so applications can find out which features
334 have been compiled into the installed readline and history libraries.
336 d. rlstdc.h is now an installed header file.
338 e. Many changes to the signal handling:
339 o Readline now catches SIGQUIT and cleans up the tty before returning;
340 o A new variable, rl_catch_signals, is available to application writers
341 to indicate to readline whether or not it should install its own
342 signal handlers for SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP,
343 SIGTTIN, and SIGTTOU;
344 o A new variable, rl_catch_sigwinch, is available to application
345 writers to indicate to readline whether or not it should install its
346 own signal handler for SIGWINCH, which will chain to the calling
347 applications's SIGWINCH handler, if one is installed;
348 o There is a new function, rl_free_line_state, for application signal
349 handlers to call to free up the state associated with the current
350 line after receiving a signal;
351 o There is a new function, rl_cleanup_after_signal, to clean up the
352 display and terminal state after receiving a signal;
353 o There is a new function, rl_reset_after_signal, to reinitialize the
354 terminal and display state after an application signal handler
355 returns and readline continues
357 f. There is a new function, rl_resize_terminal, to reset readline's idea of
358 the screen size after a SIGWINCH.
360 g. New public functions: rl_save_prompt and rl_restore_prompt. These were
361 previously private functions with a `_' prefix. These functions are
362 used when an application wants to write a message to the `message area'
363 with rl_message and have the prompt restored correctly when the message
366 h. New function hook: rl_pre_input_hook, called just before readline starts
367 reading input, after initialization.
369 i. New function hook: rl_display_matches_hook, called when readline would
370 display the list of completion matches. The new function
371 rl_display_match_list is what readline uses internally, and is available
372 for use by application functions called via this hook.
374 j. New bindable function, delete-char-or-list, like tcsh.
376 k. A new variable, rl_erase_empty_line, which, if set by an application using
377 readline, will cause readline to erase, prompt and all, lines on which the
378 only thing typed was a newline.
380 l. There is a new script, support/shlib-install, to install and uninstall
381 the shared readline and history libraries.
383 m. A new bindable variable, `isearch-terminators', which is a string
384 containing the set of characters that should terminate an incremental
385 search without being executed as a command.
387 n. A new bindable function, forward-backward-delete-char.
389 -------------------------------------------------------------------------------
390 This document details the changes between this version, readline-2.2,
391 and the previous version, readline-2.1.
393 1. Changes to Readline
395 a. Added a missing `extern' to a declaration in readline.h that kept
396 readline from compiling cleanly on some systems.
398 b. The history file is now opened with mode 0600 when it is written for
401 c. Changes were made to the SIGWINCH handling code so that prompt redisplay
404 d. ^G now interrupts incremental searches correctly.
406 e. A bug that caused a core dump when the set of characters to be quoted
407 when completing words was empty was fixed.
409 f. Fixed a problem in the readline test program rltest.c that caused a core
412 g. The code that handles parser directives in inputrc files now displays
415 h. The history expansion code was fixed so that the appearance of the
416 history comment character at the beginning of a word inhibits history
417 expansion for that word and the rest of the input line.
419 i. The code that prints completion listings now behaves better if one or
420 more of the filenames contains non-printable characters.
422 j. The time delay when showing matching parentheses is now 0.5 seconds.
425 2. New Features in Readline
427 a. There is now an option for `iterative' yank-last-arg handline, so a user
428 can keep entering `M-.', yanking the last argument of successive history
431 b. New variable, `print-completions-horizontally', which causes completion
432 matches to be displayed across the screen (like `ls -x') rather than up
433 and down the screen (like `ls').
435 c. New variable, `completion-ignore-case', which causes filename completion
436 and matching to be performed case-insensitively.
438 d. There is a new bindable command, `magic-space', which causes history
439 expansion to be performed on the current readline buffer and a space to
440 be inserted into the result.
442 e. There is a new bindable command, `menu-complete', which enables tcsh-like
443 menu completion (successive executions of menu-complete insert a single
444 completion match, cycling through the list of possible completions).
446 f. There is a new bindable command, `paste-from-clipboard', for use on Win32
447 systems, to insert the text from the Win32 clipboard into the editing
450 g. The key sequence translation code now understands printf-style backslash
451 escape sequences, including \NNN octal escapes. These escape sequences
452 may be used in key sequence definitions or macro values.
454 h. An `$include' inputrc file parser directive has been added.