Copyright 1999 by Craig A. Finseth. Contact the author with questions about distribution rights.
This web site contains the full text of the book "The Craft of Text Editing." That book was published in 1991 by Springer-Verlag & Co. By arrangement between the author and the publisher, the book version is now out of print and all rights have been returned to the author. Note that there may be some slight differences in typograhic corrections between this version and the printed one.
If you wish to cite this work, please use the following URL:
If you should notice typos or formatting problems, please let me know. I am not, however, planning on revising or updating the book anytime soon.
Here is a tar file that contains the complete work and Here.gz is a gzip'd tar.
Preface
Introduction: What Is Text Editing All About?
Chapter 1: Users
Chapter 2: User Interface Hardware
Chapter 3: Implementation Languages
Chapter 4: Editing Models
Chapter 5: File Formats
Chapter 6: The Internal Sub-Editor
Chapter 7: Redisplay
Chapter 8: User-Oriented Commands: The Command Loop
Chapter 9: Command Set Design
Chapter 10: Emacs-Type Editors
Epilogue
Appendix A: A Five-Minute Introduction to C
Appendix B: Emacs Implementations
Appendix C: The Emacs Command Set
Appendix D: The TECO Command Set
Appendix E: ASCII Chart
Bibliography
Book Index
The chapter quotes comprise the verse "Jabberwocky" by Lewis Carroll, from the work Through the Looking Glass.
Annex is a registered trademark of Xylogics.
CP/M is a registered trademark of Digital Research.
DEC, Tops-20, VT52, VT100, VT200 and VAX/VMS are registered trademarks of Digital Equipment Corp.
FinalWord and MINCE are registered trademarks of Mark of the Unicorn.
IBM and IBM PC are registered trademarks of IBM Corp.
Apple ][ is a registered trademark of Apple Computer, Inc.
Macintosh is a trademark licensed to Apple Computer, Inc.
MS/DOS is a registered trademark of Microsoft Corp.
TTY is a registered trademark of Teletype Corp.
UNIX is a registered trademark of AT&T
Introduction: What Is Text Editing All About?
The Basic Get_Line
Version One
Version Two
Version Three
Version Four
The Forest
Questions to Probe Your Understanding
Users Categories
Amount of Experience
Type of Experience
"Religion"
User Goals
Physiological Constraints
Applying These Physiological Constraints
Users Who Have Handicaps
Questions to Probe Your Understanding
Chapter 2: User Interface Hardware
Display Types
TTY and Glass TTY
Basic Displays
Advanced Displays
"Memory Mapped" Displays
Graphics Displays
Keyboards
Special Function Keys
Extra Shift Keys
Key Placement
Example Keyboards
Graphical Input
Touch Sensitive Display
Tablet
Mouse
Trackball
Joystick
A Different Mouse
Other Devices
Conclusion
Communications Path Issues
Speed and Character Format
Flow Control
Echo Negotiation
Fancy Modems
Questions to Probe Your Understanding
Chapter 3: Implementation Languages
General Considerations
Availability and Implementation Quality
Text Handling Power
Support for Extensibility
Large Project Support
Efficiency
Specific Language Notes
TECO
Lisp
C
PL/1
Other Systems Languages
Fortran
Pascal
Basic
Ada
Sine
Custom Editor Languages
Questions to Probe Your Understanding
One-Dimensional Array of Bytes
Two-Dimensional Array of Bytes
List of Lines
Paged Models
Objects
Dealing With Real Text
Questions to Probe Your Understanding
Text Files
Line Boundaries
Line Contents
End of File
Binary Files
Structured Files
Where to Store the "Extra" Information
In-Band
Out-of-Band
Conclusion
The Additional Information
Fonts, Sizes, Attributes
Line, Paragraph, Page, and Other Formats
Non-Text Objects
Internationalization
Questions to Probe Your Understanding
Chapter 6: The Internal Sub-Editor
Basic Concepts and Definitions
Internal Data Structures
Procedure Interface Definitions
Characteristics of Implementation Methods
No Management
Extra Space at the End
Buffer Gap
Multiple Gaps and Why They Don't Work
The Hidden Second Gap
Implementation Method Overview
Buffer Gap
Linked Line
Paged Buffer Gap
Other Methods
Method Comparisons
Storage
Crash Recovery
Efficiency of Editing
Efficiency of Buffer/File I/O
Efficiency of Searching
Multiple Buffers
Paged Virtual Memory
Recommedations
Editing Extremely Large Files
Difference Files
Questions to Probe Your Understanding
Constraints
Procedure Interface Definitions
Editor Procedures
Display Independent Procedures
Considerations
Status Line
End of the Buffer
Horizontal Scrolling
Line Wrap
Word Wrap
Tabs
Control Characters
Proportionally Spaced Text
Attributes, Fonts and Scripts
Breaking Out Between Lines
Multiple Windows
Redisplay Itself
The Framer
The Basic Algorithm
Sub-Editor Interaction
The Advanced Algorithm
Redisplay for Memory Mapped Displays
Questions to Probe Your Understanding
Chapter 8: User-Oriented Commands: The Command Loop
The Core Loop: Read, Evaluate, Print
The Evaluate Procedure
Move by a Character
Insert a Character
Second-Level Dispatch
Accept an Argument
Philosophy
A Minimalist Command Set Design
Errors
Internal Errors
External Errors
Exiting
Arguments
Numeric (Prefix) Arguments
String (Suffix) Arguments
Positional Arguments
Selection Arguments
Rebinding
Rebinding Keys
Rebinding Functions
Modes
Modes and Dynamic Rebinding
Implementing Modes
Changing Your Mind
Command Set Design
Kill Ring or "Clipboard"
Undo
An Undo Heresy
Redo
Macros
Again
Keystroke Recording
Macro Languages
Redisplay Interaction
Questions to Probe Your Understanding
Responsiveness
Consistency
Permissiveness
Progress
Simplicity
Uniformity
Extensibility
Modes
Use of Language
Guideline Summary
Overall
Modes
Use of Language
Structure Editors
Programing Assistance
Command Behavior
Does Down Move the Point or the Text?
Scrolling vs. Paging
Page Breaks
How Many Ways Can You Move by a Word?
Moving by Words
Deleting by Words
Where Do Sentences and Paragraphs End?
How to Search
Commands to Handle Typos
Capitalization Commands
Twiddling
Questions to Probe Your Understanding
Chapter 10: Emacs-Type Editors
"What Do You Mean, 'Emacs-type?' "
The Command Set
The Extended Environment
Extensibility
Questions to Probe Your Understanding
Questions to Probe Your Understanding
Appendix A: A Five-Minute Introduction to C
Case Conventions
Data Types and Declarations
Constants
Pre-defined Constants
Procedure Structure
Statements
Operators
Standard Library Functions Used in This Book
Non-Standard Library Functions Used in This Book
Appendix B: Emacs Implementations
The following sections appeared in the book's table of contents. This entire appendix has been replaced with a pointer to the current Emacs Implementations lisst.
Acronyms
Implementations Mentioned in my Thesis (Pre-1980)
GNU-Emacs
Newer Implementations Available for No Charge
Newer Implementations Sold by Vendors
Appendix C: The Emacs Command Set
Notation
Default GNU-Emacs Command Set
The Author's Command Set
Appendix D: The TECO Command Set
Current
Thesis
Emacs-Type Editors
ITS EMACS
Lisp Machine Zwei
Multics Emacs
MagicSix TVMacs
Other Emacs-Type Text Editors
Non-Emacs Display Editors
Structure Editors
Other Editors
Visits since no time in particular...