
LispWorks® for Macintosh Editor User Guide Version 6.0 Copyright and Trademarks LispWorks Editor User Guide (Macintosh version) Version 6.0 November 2009 Copyright © 2009 by LispWorks Ltd. All Rights Reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, photocopying, recording, or otherwise, without the prior written permission of LispWorks Ltd. The information in this publication is provided for information only, is subject to change without notice, and should not be construed as a commitment by LispWorks Ltd. LispWorks Ltd assumes no responsibility or liability for any errors or inaccuracies that may appear in this publication. The software described in this book is furnished under license and may only be used or copied in accordance with the terms of that license. LispWorks and KnowledgeWorks are registered trademarks of LispWorks Ltd. Adobe and PostScript are registered trademarks of Adobe Systems Incorporated. Other brand or product names are the registered trade- marks or trademarks of their respective holders. The code for walker.lisp and compute-combination-points is excerpted with permission from PCL, Copyright © 1985, 1986, 1987, 1988 Xerox Corporation. The XP Pretty Printer bears the following copyright notice, which applies to the parts of LispWorks derived therefrom: Copyright © 1989 by the Massachusetts Institute of Technology, Cambridge, Massachusetts. Permission to use, copy, modify, and distribute this software and its documentation for any purpose and without fee is hereby granted, pro- vided that this copyright and permission notice appear in all copies and supporting documentation, and that the name of M.I.T. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. M.I.T. makes no representa- tion about the suitability of this software for any purpose. It is provided “as is” without express or implied warranty. M.I.T. disclaims all war- ranties with regard to this software, including all implied warranties of merchantability and fitness. In no event shall M.I.T. be liable for any special, indirect or consequential damages or any damages whatsoever resulting from loss of use, data or profits, whether in an action of con- tract, negligence or other tortious action, arising out of or in connection with the use or performance of this software. LispWorks contains part of ICU software obtained from http://source.icu-project.org and which bears the following copyright and permis- sion notice: ICU License - ICU 1.8.1 and later COPYRIGHT AND PERMISSION NOTICE Copyright © 1995-2006 International Business Machines Corporation and others. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Soft- ware"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, provided that the above copyright notice(s) and this permission notice appear in all copies of the Software and that both the above copyright notice(s) and this permission notice appear in supporting documentation. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIM- ITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. Except as contained in this notice, the name of a copyright holder shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization of the copyright holder. All trademarks and registered trademarks men- tioned herein are the property of their respective owners. US Government Restricted Rights The LispWorks Software is a commercial computer software program developed at private expense and is provided with restricted rights. The LispWorks Software may not be used, reproduced, or disclosed by the Government except as set forth in the accompanying End User License Agreement and as provided in DFARS 227.7202-1(a), 227.7202-3(a) (1995), FAR 12.212(a)(1995), FAR 52.227-19, and/or FAR 52.227-14 Alt III, as applicable. Rights reserved under the copyright laws of the United States. Address Telephone Fax LispWorks Ltd From North America: 877 759 8839 From North America: 617 812 8283 St. John’s Innovation Centre Cowley Road (toll-free) From elsewhere: +44 870 2206189 Cambridge CB4 0WS From elsewhere: +44 1223 421860 England www.lispworks.com Contents 1 Introduction 1 Using the editor within LispWorks 2 2 General Concepts 5 Window layout 5 Buffer locations 7 Modes 8 Text handling concepts 8 Executing commands 9 Basic editing commands 11 3 Command Reference 15 Aborting commands and processes 16 Executing commands 17 Help 18 Prefix arguments 23 File handling 25 Movement 37 Marks and regions 43 Locations 47 Deleting and killing text 48 Inserting text 53 Delete Selection 56 Undoing 56 iii Contents Case conversion 57 Transposition 58 Overwriting 60 Indentation 61 Filling 64 Buffers 68 Windows 72 Pages 74 Searching and replacing 77 Comparison 89 Registers 90 Modes 91 Abbreviations 96 Keyboard macros 101 Echo area operations 103 Editor variables 107 Recursive editing 107 Key bindings 108 Running shell commands from the editor 110 Buffers, windows and the mouse 113 Miscellaneous 115 4 Editing Lisp Programs 117 Automatic entry into lisp mode 118 Syntax coloring 118 Functions and definitions 119 Forms 136 Lists 139 Comments 140 Parentheses 143 Documentation 145 Evaluation and compilation 147 Breakpoints 156 Removing definitions 157 5Emulation159 Using Mac OS editor emulation 159 iv Contents Key bindings 160 Replacing the current selection 161 Emulation in Applications 161 6 Advanced Features 163 Customizing default key bindings 164 Customizing Lisp indentation 166 Programming the editor 166 Editor source code 195 Glossary 197 Index 207 v Contents vi 1 1 Introduction The LispWorks editor is built in the spirit of Emacs. As a matter of policy, the key bindings and the behavior of the LispWorks editor are designed to be as close as possible to the standard key bindings and behavior of GNU Emacs. For users more familiar with Mac OS keys, an alternate keys and behaviour model is provided. This manual however, generally documents the Emacs model. The LispWorks editor has the following features: •It is a screen editor. This means that text is displayed by the screenful, with a screen normally displaying the text which is currently being edited. •It is a real-time editor. This means that modifications made to text are shown immediately, and any commands issued are executed likewise. •An on-line help facility is provided, which allows the user quick and easy access to command and variable definitions. Various levels of help are provided, depending on the type of information the user currently pos- sesses. •It is customizable. The editor can be customized both for the duration of an editing session, and on a more permanent basis. • A range of commands are provided to facilitate the editing of Lisp pro- grams. 1 1Introduction • The editor is itself written in Lisp. 1.1 Using the editor within LispWorks The LispWorks editor is fully integrated into the LispWorks programming envi- ronment. If you don’t currently have an Editor (check the Window menu), start one by choosing Window > Tools > Editor or clicking on in the LispWorks toolbar. There are a number of editor operations which are only available in Listener windows (for example, operations using the command history). These opera- tions are covered in the LispWorks IDE User Guide. 1.1.1 About this manual The Editor User Guide is divided into chapters, as follows: Chapter 2, “General Concepts”, provides a brief overview of terms and con- cepts which the user should be familiar with before progressing to the rest of the manual. The section ‘Basic editing commands’ provides a brief description of commands necessary to edit a file from start to finish. If you are already familiar with Emacs, you should be familiar with most of the information contained in this chapter. Chapter 3, “Command Reference”, contains full details of most of the editor commands. Details of editor variables are also provided where necessary. Not included in this chapter are commands used to facilitate the editing of Lisp pro- grams. Chapter 4, “Editing Lisp Programs”, contains full details of editor commands (and variables where necessary) to allow for easier editing of Lisp programs. Chapter 5, “Emulation”, describes use of Mac OS style key bindings rather than Emacs style. Chapter 6, “Advanced Features”, provides information on customizing and programming the editor. The features described in this chapter allow permanent changes to be made to the editor. A “Glossary” is also included to provide a quick and easy reference to editor terms and concepts. 2 1.1 Using the editor within LispWorks Each editor command, variable and function is fully described once in a rele- vant section (for example, the command Save File is described in “File han- dling” on page 12). It is often worthwhile reading the introductory text at the start of the section, as some useful information is often provided there. The descriptions all follow the same layout convention which should be self-explan- atory. Command description layouts include the name of the command, the default Emacs binding, details of optional arguments required by the associated defin- ing function (if any) and the mode in which the command can be run (if not glo- bal).
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages234 Page
-
File Size-