🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.c
Article #393

Re: Editor design & Buffer Gap

#393
From: Anthony Howe
Date: Sun, 18 Oct 2026 10:03
55 lines
4149 bytes
On 2026-10-12 17:42, steve g wrote:
> Anthony Howe <achowe@snert.com> writes:
> \
> 
>> The designing the edit engine is what fascinates me, regardless of UI.  Pity
>> there are few discussions any more around this topic.
> 
> 
> I agree. I would love to play with a redisplay engine. let alone read
> more about them. I usually just read some old pascal books from the
> 1990s. I would love to reimplement lotus style menus !

Redisplay in text, you thinking Curses/NCurses?

Curses was designed to abstract the assorted video terminals of the day (now 
everything is an VT100/ANSI derivative) and to optimise the sending of minimal 
sequences of escape codes to a **serial terminal** (or terminal emulator) to 
update the screen.

There used to be BSD Curses, Solaris Curses, System V Curses, pdcurses, (and 
Mortice Kern Systems (MKS) Curses).  X/Open (now SUS) created a standard for 
Curses that brought together the minor difference into one.  NCurses (written in 
C++) was starting around the time of POSIX.2, X/Open, and Unicode standards and 
hasn't change much since and is stable.  SUS has Curses Issue 7 which clarifies 
the text.

Terminal Difference algorithms are related to Edit Distance / Longest Common 
Subsequence algorithms - think `diff(1)`.  There is a paper from Bill Joy on 
Curses and some other papers related to terminal Edit Distance/LCS I obtained 
when working on MKS Curses (buried on my book shelf).

There are books "Software Tools in PASCAL" by Kernigan & Plauger ISBN 
0-201-103342-7 and "A Software Tools Sampler" by Web Miller ISBN 0-13-822305-X 
that cover editors.  The latter also covers terminal updating for an editor 
(Edit Distance/LCS).  See also `diff(1)` and my IOCCC 2015 `npdif(1)` also cover 
Edit Distance/LCS (I supply several References in the documentation to papers).

Frankly I think terminal updates is a well solved problem - worth learning and 
studying since the topic of Edit Distance/LCS relates to other subject areas 
like gene sequencing, but not worth a new library IMO.

 > UI is influenced by the history of interface hardware: teletype printers,
 > serial cable terminals, block-mode terminals, PC, PDAs + stylus, fondle slabs
 > (tablets/smart phones), voice, "mind control"/direct human interface.  These
 > are all interesting too, but they rely on the edit engine to do the work.

An editor's edit engine covers the storage and its manipulation of the text. 
The terminal update display algorithm for an editor would be part of the 
UI/hardware interface and as has been mentioned else where GUI for desktop 
paradigms.

-- 
Anthony C Howe
achowe@snert.com                              BarricadeMX & Milters
http://nanozen.snert.com/              https://github.com/SirWumpus
Technical Details
Message-ID: <11b25hh$11ann$1@dont-email.me>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
References: <slrn1184atm.1fe.zaydm@new.localdomain> <115tgk1$hmg2$2@kst.eternal-september.org> <1hEgS.428964$DOD1.142122@fx17.ams4> <11ag1j1$2lam4$1@dont-email.me> <87se2aeguh.fsf@gmail.com>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail
From: Anthony Howe <achowe@snert.com>
Newsgroups: comp.editors,comp.lang.c
Subject: Re: Editor design & Buffer Gap
Date: Sun, 18 Oct 2026 06:03:27 -0400
Organization: A noiseless patient Spider
Lines: 55
Message-ID: <11b25hh$11ann$1@dont-email.me>
References: <slrn1184atm.1fe.zaydm@new.localdomain>
 <115tgk1$hmg2$2@kst.eternal-september.org>
 <1hEgS.428964$DOD1.142122@fx17.ams4> <11ag1j1$2lam4$1@dont-email.me>
 <87se2aeguh.fsf@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 18 Oct 2026 10:03:30 +0000 (UTC)
Injection-Info: dont-email.me;
	logging-data="1092343"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX1+622NMSTD8wnbmTPZwYNDf"; posting-host="8c462b0497100e768a5a0b850df8e1ea"
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:M7uw6RiFG8uJE7WiqdEa/rcv3eM= sha256:Rwrv+dCq2EgAjSCMysP3XyMq1MWjwULf6951M3cXlxQ=
	sha1:bPAomkbfgkgPJbrMscYcxf/m2VU= sha256:p//AflmCedaw+fgIq26pDcV62VTYn3fNksmZlw8vAsw=
Content-Language: en-GB, fr
In-Reply-To: <87se2aeguh.fsf@gmail.com>