Antonio Diaz Diaz wrote: > Changes in this version: > > * The "z" command has been fixed. ("zN" printed N + 1 lines). This bug was > present since at least ed-0.2.
This bug exists in the *BSD ed’s as well, unfortunately. Though documented otherwise in the ed man page (ed.1), the intent of the command `zN’ is to set the window size to N, which is persistent (unlike with ex(vim)). If the command prompt is counted as one line, then it should really display only N - 1 lines from the buffer. In your current implementation (1.11rc1), on an N line display, only N - 2 lines of the buffer are displayed - the top line being the previous command. To verify this: $ ed r !seq 100 ! <<<< Per POSIX, bang should be printed on return from shell command. 292 1z On the other hand, you’re in good company: ex(vim) exhibits this (mis)behavior too. And since the command `z' is explicitly omitted from SUSv4, you pretty much have a free hand to define the behavior as you wish. Then again, ex(vim) properly documents the command `zN' as setting the window height, indicating that the current behavior in ex(vim) is probably a bug... -AM
_______________________________________________ bug-ed mailing list bug-ed@gnu.org https://lists.gnu.org/mailman/listinfo/bug-ed