[Tutor] Correct style of line break when chaining methods

Cameron Simpson cs at cskk.id.au
Fri Jul 16 19:00:48 EDT 2021


On 16Jul2021 16:01, Mats Wichmann <mats at wichmann.us> wrote:
>On 7/16/21 3:55 PM, Alan Gauld via Tutor wrote:
>>And contrary to popular opinion vi does not really use curses,
>>rather it uses termcap (and now terminfo), the raw terminal
>>control codes. There is, so far as I can tell, no actual
>>curses specific code in vi. It does include curses but never
>>enters curses mode, it just uses the termcap/info control
>>definitions.
>
>I don't know about vim, which is a rewrite I've never poked at the 
>code for, but for the original vi, definitely true - curses grew out of 
>the learnings from building vi, but it wasn't pulled back into vi.

Aye.

Back in the day I sometimes dialed in to the university on a TRS-80 and 
a 300baud modem. The TRS-80's cursor codes were quite limited. Vi had a 
distinct mode for terminals with no "delete line" function - if you 
deleted a line of text it would just leave a marker there (a line with a 
single "@" at the left) rather than close up the display. You could do 
this with curses I suppose, but you wouldn't.

At some point I wrote some assembler to provide a few capabilities line 
delete-line for the TRS-80 and vi behaved a lot more like a modern one, 
but on a slow serial line with no delete/scroll-up the placeholder 
approach was very effective.

I've still got the terminfo entries for each :-)

    -rw-r--r--  1 cameron  cameron   998 29 May  1999 /Users/cameron/rc/term/info/t/trs80m1
    -rw-r--r--  1 cameron  cameron  1119 29 May  1999 /Users/cameron/rc/term/info/t/trs80m1cs

Cheers,
Cameron Simpson <cs at cskk.id.au>


More information about the Tutor mailing list