Text Editing and 3 Processing Symbolicstm
Total Page:16
File Type:pdf, Size:1020Kb
Text Editing and 3 Processing symboliCSTM Cambridge I Massachusetts Text Editing and Processing # 999020 July 1986 This document corresponds to Genera 7.0 and later releases. The software, data, and information contained herein are proprietary to, and comprise valuable trade secrets of, Symbolics, Inc. They are given in confidence by Symbolics pursuant to a written license agreement, and may be used, copied, transmitted, and stored only in accordance with the terms of such license. This document may not be reproduced in whole or in part without the prior written consent of Symbolics, Inc. Copyright© 1986,1985,1984,1983,1982,1981,1980 Symbolics,lnc. All Rights Reserved. Portions of font library Copyright © 1984 Bitstream Inc. All Rights Reserved. Portions Copyright © 1980 Massachusetts Institute of Technology. All Rights Reserved. Symbollcs, Symbollcs 3600, Symbollcs 3670, Symbollcs 3675, Symbollcs 3640, Symbollcs 3645, Symbollcs 3610, Genera, Symbollcs-L1sp®, Wheels, Symbollcs Common Lisp, Zetallsp®, Dynamic Windows, Document Examiner, Showcase, SmartStore, SemantiCue, Frame-Up, Firewall, S-DYNAMICS®, S-GEOMETRY, S-PAINT, S-RENDER®, MACSYMA, COMMON LISP MACSYMA, CL-MACSYMA, LISP MACHINE MACSYMA, MACSYMA Newsletter and Your Next Step In Computing are trademarks of Symbolics, Inc. Restricted Rights Legend Use, duplication, and disclosure by the Government are subject to restrictions as set forth in subdivision (b)(3)(ii) of the Rights in Technical Data and Computer Software Clause at FAR 52.227-7013. Symbolics, Inc. 4 New England Tech Center 555 Virginia Road Concord, MA 01742 Text written and produced on Symbolics 3600-family computers by the Documentation Group of Symbolics, Inc. Text masters produced on Symbolics 3600-family computers and printed on Symbolics LGP2 Laser Graphics Printers. Cover design: Schafer/LaCasse Printer: CSA Press Printed in the United States of America. Printing year and number: 888786987654321 Iii July 1986 Text Editing and Processing Table of Contents Page I. Zmacs Manual 1 1. Introduction to the Zmacs Manual 3 Overview of the Zmacs Manual 4 Introduction to Zmacs 6 Zmacs Manual Notation Conventions 9 2. Getting Started in Zmacs 11 Entering Zmacs 12 Zmacs Help 14 Organization of the Screen 18 Inserting Text 24 Numeric Arguments 26 Introduction to Moving the Cursor 28 Introduction to Erasing Text 30 Creating and Saving Buffers and Files 32 Zmacs Commands for Formatting Text 35 Executing CP Commands From Zmacs 43 Leaving Zmacs 44 3. Getting Help in Zmacs 47 Getting Out of Trouble 48 Finding Out About Zmacs Commands 51 The Editor Menu 57 More on the Minibuffer 59 Getting Information About Buffers and Regions 61 4. Moving the Cursor in Zmacs 63 Overview of Moving the Cursor 64 Redisplaying the Window 65 Moving the Cursor with the Mouse 67 Motion Commands 71 Motion by Lisp Expression 76 Motion by Paragraph 79 Motion by Page 80 iv Text Editing and Processing July 1986 Motion with Respect to the Whole Buffer 81 5. Deleting and Transposing Text in Zmacs 83 Deleting V s. Killing Text 84 Deleting and Transposing Characters 90 Deleting and Transposing Words 92 Deleting and Transposing Lisp Expressions 93 Deleting and Transposing Lines 95 Deleting Sentences 97 6. Working with Regions in Zmacs 99 What is a Zmacs Region? 100 Registers in Zmacs 104 Commands to Mark Regions 106 Region-Manipulating Commands 109 7. Searching, Replacing, and Sorting in Zmacs 113 Searching in Zmacs 114 Locating and Replacing Strings Automatically 118 Tag Tables and Search Domains 122 Sorting 128 8. Manipulating Buffers and Files in Zmacs 129 Working with Buffers and Files 130 Selecting, Listing, and Examining Buffers 132 Buffer Commands 133 Appending, Prepending, and Inserting Text 141 Comparing Files and Buffers 142 Window Commands 146 File Manipulation Commands 148 Buffer and File Attributes 155 Dired Mode 163 9. Setting the Zmacs Major Mode 175 Major Editing Modes 176 10. Zmacs Speller 179 Using the Zmacs Speller 180 Speller Commands for Spelling 184 Speller Dictionaries 187 v July 1986 Text Editing and Processing 11. Word Abbreviations 197 Using Word Abbreviations 198 Word Abbreviation Commands 200 12. Using Character Styles in Zmacs 205 Introduction to the Character Style Commands 206 Character Style Commands in Zmacs 210 13. Changing Case and Indentation in Zmacs 213 Changing Case 214 Indentation 216 14. Editing Lisp Programs in Zmacs 223 Introduction 224 Commenting Lisp Code 226 Evaluating and Compiling Lisp Programs 229 Parenthesizing Lisp Expressions 233 Expanding Lisp Expressions 234 Locating Source Code to Edit 235 Patching 242 15. Customizing the Zmacs Environment 251 Overview 252 Built-in Customization Using Zmacs Minor Modes 253 Major Modes 256 Creating New Commands with Keyboard Macros 257 Key Bindings 267 How to Specify Zmacs Variable Settings 269 Customizing Zmacs in Init Files 272 Appendix A. Zmacs Help Command Summary 277 Zmacs Commands for Finding Out About the State of Buffers 278 Zmacs Commands for Finding Out About the State of Zmacs 279 Zmacs Commands for Finding Out About Lisp 280 Zmacs Com~ands for Finding Out About Flavors 281 Zmacs Commands for Interacting with Lisp 282 II. Font Editor 283 16. Font Basic Concepts 285 vi Text Editing and Processing July 1986 16.1 Attributes of TV Fonts 285 16.2 Standard TV Fonts 287 17. Entering and Leaving FED 289 18. Font Editor Basic Concepts 291 18.1 FED, the Subsystem 291 18.2 Selecting a Font 294 18.2.1 Creating a New Font 297 18.2.2 Displaying Characters in the Font 297 18.3 Selecting a Character 297 18.3.1 From the Character Select Menu 298 18.3.2 By Creating a New Character 298 18.3.3 From the [Show Font] Display 298 18.3.4 With the C Command 298 18.3.5 By Renaming Characters 298 19. Drawing 299 19.1 Drawing Characters with the Mouse 299 19.2 The Nonmouse Cursor 300 20. Viewing and Altering a Character in the Character Box 301 20.1 What the Lines Mean 301 20.2 Altering the Character Box 302 21. The Gray Plane 303 21.1 Getting Things Into Gray 303 21.1.1 With [Swap Gray] 303 21.1.2 With [Gray Char] 303 21.2 Merging Characters with the Gray Plane 304 22. Saving Characters and Pieces of Characters in Registers 307 22.1 Saving a Drawing Into a Register 307 22.2 Retrieving the Contents of a Register 307 22.3 Retrieving the Black Plane While Manipulating Registers 307 23.· Transformations 309 23.1 Clearing the Drawing 309 23.2 Rotating Drawings 309 23.3 Reflecting Drawings 309 23.4 Moving the Drawing 312 vii July 1986 Text Editing and Processing 23.5 Drawing Lines and Curves 312 23.6 Stretching and Contracting 316 23.6.1 Stretching a Drawing Horizontally 316 23.6.2 Contracting a Drawing Horizontally 316 23.6.3 Stretching a Drawing Vertically 316 23.6.4 Contracting a Drawing Vertically 316 24. The Sample String 321 25. Adjusting the Display 323 25.1 Positioning the Drawing 323 25.2 Setting the Box Size in the Drawing Pane 324 25.3 Setting the Height and Width of the Drawing Pane 324 26. Reading and Writing Files 325 26.1 Reading Files 325 26.2 Writing Files 326 27. Command List 327 27.1 Menu and Keyboard Commands 327 27.1.1 Configuration and Drawing Transformation 327 27.1.2 Gray Plane Menu Items 328 27.1.3 Outside World Interface Menu Items 329 27.1.4 Evaluating Forms From FED 330 27.2 Keyboard-only Commands 330 27.3 Mouse Sensitivities 330 27.3.1 The Drawing Pane 330 27.3.2 The Draw Mode Menu 331 27.3.3 The Sample Pane 331 27.3.4 The Character Select Pane 331 27.3.5 The Font Parameters Menu 331 27.3.6 The Register Pane 331 27.3.7 The List Fonts and Show Font Displays 332 Index 333 viii Text Editing and Processing July 1986 List of Figures Figure 1. Initial FED Display 290 Figure 2. Tall Configuration 295 Figure 3. Wide Configuration 296 Figure 4. [Rotate (R)] 310 Figure 5. [Rotate (M)] 311 Figure 6. [Reflect] 313 Figure 7. The X axis (-) 314 Figure 8. Moving the Drawing with [Move Black] 315 Figure 9. Stretching Horizontally 317 Figure 10. Contracting Horizontally 318 July 1986 Zmacs Manual PART I. Zmacs Manual 2 Text Editing and Processing July 1986 3 July 1986 Zmacs Manual 1. Introduction to the Zmacs Manual 4 Text Editing and Processing July 1986 Overview of the Zmacs Manual Scope The Zmacs Manual is primarily a reference manual and is intended for all users of Zmacs on the Lisp Machine. It contains both conceptual overview and reference material that together describe the Zmacs editor. We assume that you have already read the User's Guide to Symbolics Computers. Organization The first three chapters contain introductory material for users who are unfamiliar with Zmacs concepts. Experienced users can skim the remaining chapters, which are organized according to editing function, and use them as reference material. "Introduction" gives an overview of Zmacs and describes Zmacs documentation conventions in this manual. "Getting Started" introduces basic Zmacs concepts and commands, such as how to enter text, move the cursor, and make simple corrections. "Getting Help" describes ways to get out of trouble and how to get Zmacs information during editing. "Moving the Cursor" includes descriptions of both mouse and keyboard motion commands. "Deleting and Transposing Text" explains Zmacs deletion and text retrieval concepts, as well as the ways to delete and transpose text. "Working With Regions" tells how to manipulate blocks of text. "Searching, Replacing, and Sorting" describes the commands for locating and replacing character strings in one or many files. "Manipulating Buffers and Files" gives more information on manipUlating blocks of text, inserting files, keeping track of everything, and editing your directory.