This document describes TEXTRA, a very user-friendly text editor. So user-friendly, I hope, that you could use it without reading a manual. Good learning philosophy: play with it. One of the easiest, that's the goal. TEXTRA is SHAREWARE. For $25.00, I will send you a personalized executable that does not contain the 60-second startup-delay screens that are in the otherwise-identical UN-registered version. The UN-registered version is freely-distributable. However, please insure that the unaltered 'doc' files & rexx scripts accompany the executable if you do pass it around. If you are using TEXTRA to read this file, just Press F4 to view the next page. F5 to review the previous page. TEXTRA was written in JForth Professional, which I recommend highly. As far as I know, TEXTRA is enforcer-clean under WB 2.04. 26-Apr-89 v1.01 executable size 60148 29-May-89 v1.02 " " " 60864 22-Jul-89 v1.03 " " " 61080 21-Oct-89 v1.04 " " " 65208 05-Jan-90 v1.05 " " " 69836 18-Feb-90 v1.06 " " " 69400 18-Apr-90 v1.07 " " " 70520 06-Jun-90 v1.08 " " " 71544 15-Dec-90 v1.09 " " " 79404 26-Aug-91 v1.10 " " " 98976 ARexx, horiz scroll bar, help kbd 23-Oct-91 v1.11 " " " 100500 WB2.0 graphics, fix GET CURSOR CHAR 16-Mar-92 v1.12 " " " 108920 Undo, SmartLaunch, 1st shareware " " " " " " 111280 -- v1.12 Unregistered version 07-Jan-93 v1.13 " " " 126780 Fonts, Multi-Processing, lots more " " " " " " 129252 -- v1.13 Unregistered version (see the 'WhatsNew.doc' file for better history/features information) --------------------------------------------------------------------------- T A B L E O F C O N T E N T S --------------------------------------- NOTE: If you're using TEXTRA to read this Table Of Contents, a GREAT way to find specific topics is to... 1. Double-click on the section number (for example, 9.2.1 ) 2. "Find" it by using Right-Amiga-F (press RETURN in the requester) 3. If necessary, use Right-Amiga-N (Find Next) to locate the next occurence of the same text (most likely a cross-reference). 1. INSTALLING TEXTRA 1.1 The Textra Package 1.1.1 The Program and Icon 1.1.2 The ARexx Scripts 1.1.3 The Documentation 1.2 The Provided Installation Program 1.2.1 Installation of the program and icon 1.2.2 Installation of the Textra-ARexx Scripts 1.2.3 Installation of the Documentation 1.2.4 Final Verification before Installation 1.3 Manual Installation 2. INVOKING TEXTRA 2.1 General 2.2 Invoking from Workbench 2.3 Invoking from CLI or SHELL 2.4 TEXTRA as the Default Tool for "Project"-type icons 2.5 Launching more than once. 3. THE TEXTRA CURSOR 3.1 Cursor appearance 3.2 Positioning the cursor with the mouse 3.3 Positioning the cursor with the keyboard arrow keys 3.4 Quickly finding the cursor (function key F3) 4. ENTERING TEXT INTO THE DOCUMENT 4.1 Inserting text at the cursor location 4.2 The RETURN key 4.2.1 The "Auto-Indent" mode 4.3 The BACKSPACE key 4.3.1 The "Auto-BackSpace" mode 4.4 The DEL key 4.5 The TAB key 4.6 The control-key filter and defeat feature (Function key F2) 4.7 The HELP key 5. SELECTING A RANGE OF TEXT 5.1 Using the mouse to select a range of characters 5.2 Selecting text by double and triple clicking 5.3 Operations on selected ranges 5.4 Selecting more than the visible screen 5.5 Extending a select range by SHIFT-clicking 6. VIEWING PAGES 6.1 The vertical scroll arrow gadgets 6.2 The vertical scroll thumb gadget 6.3 Scrolling the page with the keyboard arrow keys 6.4 Keys that PAGE-up or PAGE-down 6.5 The horizontal scroll gadget 7. TEXTRA WINDOWS 7.1 Limitations 7.2 The title bar 7.3 The close gadget 7.4 The sizing gadget 7.5 The Window-Size-Toggle feature (Function key F1) 7.6 The 'Previous Window' feature (Function key F6) 7.7 The Window's font 8. THE TEXTRA AREXX INTERFACE ("TREXXTRA" -- hoo boy!) 8.1 General AREXX Information 8.2 Executing TEXTRA/AREXX Scripts or Commands 8.3 Running scripts in the background 8.4 Writing Your Own TEXTRA/AREXX scripts 9. TEXTRA MENUS 9.1 Accessing the menus 9.2 The "Project" menu 9.2.1 Open A File... 9.2.2 Open By Name... 9.2.3 New File 9.2.4 Insert File... 9.2.5 Revert To Saved 9.2.6 Save File 9.2.7 Save File As... 9.2.8 Save All Files 9.2.9 Close File 9.2.10 Print File 9.2.11 Print Selected Lines 9.2.12 Printing Preferences... 9.2.13 About TEXTRA... 9.2.14 Quit 9.3 The "Windows" menu 9.3.1 Dynamically-changing items 9.3.2 Additional information 9.4 The "Edit" menu 9.4.1 Undo 9.4.2 Cut 9.4.3 Copy 9.4.4 Paste 9.4.5 Find 9.4.5.1 String... 9.4.5.1.1 Wrap-around search option 9.4.5.2 Next Occurence 9.4.6 Replace 9.4.6.1 String... 9.4.6.2 Next Occurence 9.4.6.3 Then Find 9.4.7 Case 9.4.7.1 lower 9.4.7.2 UPPER 9.4.7.3 Capitalize 9.4.8 Go to Line... 9.4.9 Editing Preferences... 9.5 The "Utilities" menu 9.5.1 File Protections... 9.5.2 Help on Keyboard... 9.5.3 ARexx... 9.5.4 Set Window Font... 9.5.5 Font Preferences... 10. TEXTRA GENERAL INFORMATION 10.1 TEXTRA's use of Path and File names 10.2 TEXTRA String Gadget Shortcuts 10.3 TEXTRA String Gadgets and the RETURN key 10.4 TEXTRA Requesters 10.5 TEXTRA Preferences File 10.6 TEXTRA behavior when reading in files 10.6.1 Converting CR,LF sequences to Amiga End-Of-Lines. 10.6.2 Checks file type when reading in a file. 10.7 TEXTRA behavior when writing files to disk 10.7.1 Stripping extra Blank Lines. 10.8 Operation under Workbench 2.0+ vs. earlier 10.9 TEXTRA Keyboard Summary --------------------------------------------------------------------------- 1. INSTALLING TEXTRA 1.1 TEXTRA may be run without any installation at all. The installation procedure simply copies the program and a set of support files (none required) to your hard disk. 1.1.1 The program and icon file are supplied at the root of the installation package. They may be used to view any and all documentation. All supplied text files default tool fields point to this TEXTRA. 1.1.2 The TEXTRA package includes a variety of macro files, executable under its powerful ARexx interface. General page/paragraph-formatting macros, useful utilities, and scripts that allow TEXTRA to act as an integrated editing environment for JForth Professional and HSPascal are provided. 1.1.3 The accompanying documentation, of which this is a part of, is detailed and complete. It includes separate files covering Textra as editing environment, its ARexx interface and command set, detailed version history, and list of known gotchas (almost empty!). 1.2 The package provides an installation program with icon that will prompt the user through the installation process. When the installer prompts for a destination location for anything, it will create the specified directory, if it doesn't already exist. 1.2.1 The user is asked for the location for the program and icon. 1.2.2 If ARexx is running on the system, it will automatically copy the ARexx scripts in the REXX: directory, if assigned. (If REXX: is not assigned, the user is prompted to specify their location.) If Arexx does not seem to be running at all on the system, then the user is give the option of installing the scripts. 1.2.3 The user is asked if he/she wishes the Documentation files to be copied, and prompted for a location if so. 1.2.4 Finally, all choices are listed, ending with a prompt to either continue, retry or exit the installer. 1.3 If desired, the package can be installed from CLI with the following commands (assuming the Textra package is on a floppy in df0:)... copy df0:Textra#? "" If you want the docs... copy df0:docs/#? "" If you want the ARexx macro files... copy df0:scripts/#?.textra rexx: If you want the JForth-oriented ARexx macros... copy df0:scripts/JForth_Scripts/#?.textra rexx: If you want the C-oriented ARexx macros... copy df0:scripts/C_Scripts/#?.textra rexx: If you want the HSPascal-oriented ARexx macros... copy df0:scripts/HSPascal_Scripts/#?.textra rexx: --------------------------------------------------------------------------- 2. INVOKING TEXTRA 2.1 TEXTRA may be launched in all of the various ways the Amiga permits. 2.2 TEXTRA may double-clicked from Workbench (probably the most common means of starting it). Workbench Extended-Selection mode is implemented to provide opening a specific set of document icons. For information about this mode, refer to your Workbench manual. 2.3 "TEXTRA" may be typed into the CLI or SHELL, with as many optional filenames as the AmigaDOS command line will allow. For example... 1> RUN TEXTRA ... 2.4 A "Project" icon that has TEXTRA specified in its "Default Tool" field will invoke TEXTRA, when double-clicked, and be opened in its own window. 2.5 TEXTRA will not launch twice. If a TEXTRA B is launched and finds TEXTRA A already running, B will send to A the names of the files that B was passed via the mechanisms described above in sections 2.2, 2.3 or 2.4. TEXTRA B will the exit. This feature allows users to "get that file open" in the absolute most convienient method possible. (Note that enough memory must be available for TEXTRA B and TEXTRA A to momentarily reside in the machine.) --------------------------------------------------------------------------- 3. THE TEXTRA CURSOR 3.1 The current cursor location (where text will be inserted) is represented by a thin line, of a different color than either text or background. The cursor marks the place where newly-typed characters will be inserted (characters following will 'shift right'). 3.2 The cursor may be positioned by simply single-clicking the LEFT MOUSE BUTTON on the text where you want thecursor to be. 3.3 The cursor may also be moved with the "arrow" keys on the keyboard. A SHIFT-left-arrow or SHIFT-right-arrow will move the cursor to the beginning or end of the current line, respectively. 3.4 If the cursor or select range is not on the visible part of the screen, it can be located and displayed via the F3 key. --------------------------------------------------------------------------- 4. ENTERING TEXT INTO THE DOCUMENT 4.1 As keys are typed at the keyboard, they are entered in the file at the current cursor location, and the cursor is advanced by one. 4.2 The RETURN key inserts a new line, and moves the cursor there. 4.2.1 If the Auto-Indent mode is enabled (see section 9.4.9), the cursor will align with the line above when the RETURN key is pressed. 4.3 The BACKSPACE deletes the character to the immediate left of the cursor and backs the cursor up one column. If the cursor is at the leftmost column, the line is joined with the previous one. 4.3.1 When the cursor rests on the 1st non-blank character of a line, the Auto-BackSpace mode (section 9.4.9) comes into play, if enabled. The BACKSPACE key will"back-up" the line text by whatever it takes to line up with the beginning of the text on the line above. If the previous line does not start to the left of the cursor position, the alignment is made to the next line above that does. 4.4 The DELETE key removes the character to the immediate right of the cursor. If the cursor is at the end of a line, the next line is joined with the cursor line. 4.5 The TAB key advances the cursor to the next column that is an even multiple of the TAB width value (section 9.4.9). 4.6 Normally, TEXTRA will not allow control characters into the window, permitting only visible or white-space characters. This feature can be temporarily defeated, for 1 character, by pressing F2. Following F2, the next character will be accepted into the window unfiltered. 4.7 The HELP key will display an informational requestor, displaying information about the keyboard-activated functions. --------------------------------------------------------------------------- 5. SELECTING A RANGE OF TEXT 5.1 It is possible to mark a series of characters for the next operation by "dragging" with the mouse. Just press and hold the left mouse button, then drag to the desired selection end-point. 5.2 A series of characters will become selected when the LEFT MOUSE BUTTON is double-clicked while the mouse cursor is positioned over them. Based on the setting of the EDITING PREFERENCES (section xx), the series will consist of either contiguous non-white-space or aplha-numeric characters. If the LEFT MOUSE BUTTON is triple-clicked, that entire line will become selected. 5.3 When a range of text is selected, a subsequent operation will affect the entire selected area. For example, if a key is typed while a range is selected, the range will be cut from the file, replaced by that key. Other examples are the BACKSPACE and DEL keys, which both act to simply delete any selected area. Certain items under the EDIT menu, described later, also operate on any current range. 5.4 If, while selecting text, the mouse is moved near the bottom or top of the window, available text in the appropriate direction will scroll into view, becoming selected in the process. Therefore, a select range can extend past the visible limits of the window. 5.5 A select range may be established or size changed by holding down the SHIFT key when clicking in the window. If the click occurs outside the current select range, the range is extended to there. If inside, the end-point of the select range is adjusted to the click-point. --------------------------------------------------------------------------- 6. VIEWING PAGES 6.1 The easiest method for moving through the file is to use the vertical scroll bar on the right side of the window. Clicks of the left mouse button on the arrows at either end move the document vertically in continuous scroll fashion. 6.2 The "thumb" in the middle of the scroll bar not only indicates the visible-page-area relative to the total-file-size (by it's height), but also the position within the file (by its vertical positioning). It can also be "selected" with the left mouse button and moved as a "coarse adjust". The area immediately above and below the "thumb" may be clicked with the left button as a "page-scroll" mechanism. 6.3 Another method by which text may be scrolled into view is by moving the cursor...attempts to move the cursor "off the window" will cause text in that direction to scroll. 6.4 Function keys F4 and F5 will PAGE the display down and up, respectively. The Shift-UP/DOWN-arrow-key combinations will also PAGE the display in the appropriate direction AND position the cursor to the middle of the new page. 6.5 The horizontal scroll gadget works similarly to the vertical scroll gadget. It becomes functional when a line is being displayed that exceeds the current width of the window. When typing, the display will auto-scroll to center the cursor when it reaches a window edge. --------------------------------------------------------------------------- 7. TEXTRA WINDOWS 7.1 TEXTRA allows any number of windows, limited by the amount of memory in your computer (most limiting is possibly the amount of available CHIP ram, at least in early amigas). Textra lines can be up to 255 characters long, number of lines limited by your total available memory (entire file is kept in ram, FAST is grabbed first). 7.2 The title of each TEXTRA window is set to the full-pathname of the file that was read in (or created). This is also the name of the file that will be written during a SAVE operation (unless the "SAVE AS..." menu option is chosen, section 9.2.7). If the file has been modified since last saved, the filename will be preceeded by a '*'. 7.3 Each window includes a standard Intuition close gadget, which performs the same action as the "CLOSE FILE" menu option. See the discussion on "CLOSE FILE" (section 9.2.9) for more information. 7.4 The "sizing" gadget in the lower-right hand corner of each window may be used to adjust the dimensions of that window, up to the full-screen limitations of the Workbench. 7.5 Function key F1 may be used as a "window-size-toggle" between default size (when F1 was first hit) and that size specified in the "Edit Preferences..." requester (9.4.9). This preference setting defaults to full-screen. 7.6 Function key F6 will re-select the previously-selected window. This a handy "toggle between 2 windows" mode, facilitating convienient evolutions such as successive Cut, Copy & Paste sequences (sections 9.2.2, 9.2.3 and 9.2.5). 7.7 If the asl.library is available (usually means WB2.0 or later), the font in which a window is initially rendered is configurable via the "Font Preferences..." requester (9.5.5). A windows font may be changed at any time via the "Set WIndow Font..." asl requester (9.5.4). --------------------------------------------------------------------------- 8. THE TEXTRA-AREXX INTERFACE 8.1 When TEXTRA starts up, it opens a message port called "TEXTRA". This port listens for AREXX messages from other programs, and allows you to control the editor both from other applications or from AREXX "scripts", many of which are supplied with TEXTRA (they should be copied to your 'rexx:' directory). These scripts may contain a mixture of AREXX and TEXTRA commands; they allow access to many internal TEXTRA editing functions which may be performed on the 'current' window. 8.2 TEXTRA/AREXX scripts or commands may be executed via the "AREXX..." menu item (section 9.5.3). That will present present the ARexx requester which contains four string gadgets, each with an accompanying button describing the function key to execute the gadgets contents without having to bring up the requester. The string gadgets will assume default strings when initially installed. The contents may be changed and either executed and saved, just executed or just saved. The CANCEL button allows the requester to be closed and reverted to it's original state upon opening. Into any string gadget, you can enter the name of a Textra-ARexx script that exists in the rexx: directory (followed by any required arguments), as in... slide 8 Optionally, you can directly enter ARexx and Textra commandsinto the string gadgets, but they should be preceeded with an '@' char- acter. Examples... @notify "Hello world!" @prefs autoindent on @options results; get file name; notify result 8.3 Normally, while a script is executing, another window may be made frontmost and edited. (It should be noted that some system global resources, such as the cut, copy & paste buffer, are shared between the script and the edited window. While none of the supplied scripts use the CUT, COPY or PASTE commands, it is worth keeping in mind if you write your own.) 8.4 Please refer to the accompanying file "RexxCommand.doc" for a description of the TEXTRA/AREXX command set as well as general information about writing your own scripts. 8.5 Using section 8.2 as a guide, execute the "Tutorial" ARexx script for an interactive 'training session' for beginners. In one of the ARexx requester string gadgets, simply enter: tutorial --------------------------------------------------------------------------- 9. TEXTRA MENUS 9.1 Four menus are available and present themselves when the RIGHT MENU BUTTON is depressed and held. Some menu items may also be activated by simultaneously pressing the RIGHT AMIGA key and the one that is specified in the menu item text. When the HELP key is pressed (section 4.7), a list of such menu "key equivalents" presents itself. 9.2 The "Project" Menu 9.2.1 OPEN FILE... opens a new window with a full file-selector requester and buttons that allow quick access to the top 8 disk devices (like DF0:). The PARENT button changes the current directory to the level above the one being displayed. The KEYBOARD button presents the user with a string requester into which a file or directory specification may be typed. The CANCEL button exits the requester with no other action while the OK button enters the file or directory selected in the list box (the same as CANCEL if nothing is selected). Double-clicking one of the names performs the same action as the OK button. 9.2.2 OPEN BY NAME... opens a new window, then presents a string requester for specifying the filename from the keyboard, bypassing the directory scan for the list of names (which can take time on large directories, especially on floppy drives). The current directory of the requester is that of the spawning window. If a pathname is typed into this requester, the "OPEN FILE" selector requester is opened, presenting a list of the files in that directory. 9.2.3 OPEN NEW FILE opens a window without specifying a filename; the default name "Untitled" is assigned, at the directory level of the spawning window. (No actual disk file will be written until the SAVE AS... function is invoked.) 9.2.4 INSERT FILE... presents the TEXTRA file-requester allowing selection of a file to INSERT at the current cursor location (as though the entire file were typed in). Any select range will be deleted prior to the insertion. 9.2.5 REVERT TO SAVED causes the read-in version of the selected file to be discarded, replaced by the version that was last-saved to disk. A verification requester is presented to make sure this is not done accidently. 9.2.6 SAVE FILE causes the currently-selected file to be written to disk, if modified. If the file has not been changed (no '*' before the title), this menu item is disabled. 9.2.7 SAVE FILE AS... allows saving the currently selected file under a different name. After this operation, the title bar will contain the new name, and it will have been created on disk. If the specified file already exists, the user is warned and given a chance to abort. If a directory name is entered (or no name at all), the SAVE AS... file requester is presented. This requester is very similar in operation to the "OPEN FILE..." requester; all buttons work the same, except the OK button will overwrite the selected file (as does double-clicking a filename). 9.2.8 SAVE ALL FILES causes all files that have been modified and not saved to be written to disk. If there are no modified files, this menu item is disabled. 9.2.9 CLOSE FILE will check if the file has been modified but not saved and warn the user if so. Note that closing TEXTRA's last window will cause it to exit; a requester will notify you if you are closing the last window and give you the chance to abort. After the window has closed, TEXTRA will select and front another TEXTRA window if any remain. 9.2.10 PRINT FILE prints (to the printer.device) the currently selected window using the current preference settings (section 9.2.12). While a print job is in progress, other windows may be edited or have ARexx scripts executed in them, but not printed. Print jobs may be cancelled at any time by using the CANCEL button on the "Printing in progress..." requester. (Any delay experienced is the amount of time it takes your printer to respond to the RESET command). If the window to be printed is the only one open, TEXTRA will ask if you want to open another. 9.2.11 PRINT SELECTED LINES prints any and all lines, in their entirity, if any part of it is currently selected. The current preference settings (section 9.2.12) are observed. The same 'print job' behavior described in section 9.2.10 applies. 9.2.12 PRINTING PREFERENCES... presents a dialog to allow the user to enable/disable the following print job behavior... 1). Print a one-line page header at the top of each page noting the date, filename and page number. 2). Print sequential line numbers at the beginning of each line. 3). Skip over perforated page boundries of fanfold paper. 4). Eject the page (form-feed) after printing an entire file (9.2.10) 5). Eject the page (form-feed) after printing selected lines (9.2.11) Note that TEXTRA also observes the system 'Preferences' settings for left & right margin, characters-per-line, and lines-per-page (use your system 'Preferences' tool to set these). The USE button causes the currently displayed settings to go into effect. The USE+SAVE button does the USE function, and also saves the current settings in the Textra Preferences file (section 10.5). The CANCEL button causes any currently displayed settings that have been changed to be discarded. If the PRINT PREFERENCES requester is active, this menu item is disabled from other windows. 9.2.13 ABOUT TEXTRA provides the author's address and describes distribution information. Also, if the TEXTRA is registered, the name and address of the honest person who has earned my thanks and respect is displayed in this requester. 9.2.14 QUIT will exit TEXTRA, closing all files in the process. All files that have been modified but not saved will issue a notification requester, providing the opportunity to save at that time. 9.3 The "Windows" Menu 9.3.1 One item exists in the "WINDOWS" menu for each open file, the menu item text being the same as the title bar for the associated window. Selecting an item makes it the current window, if not already. 9.3.2 Additionally, the text includes the "*" character before the filename if the file has been modified since last written to disk. A checkmark preceeds the item representing the current file. 9.4 The "Edit" Menu 9.4.1 UNDO reverts all changes since the last time the cursor was positioned by clicking the mouse or by using the cursor arrow keys. 9.4.2 CUT removes the selected range of characters from the currently-selected file, but saves them in the TEXTRA clip area (TEXTRA does not interface with the standard Amiga Clipboard Device...future versions may do so). The previous contents of the TEXTRA clip area are lost. If there is no select range, this menu item is disabled. 9.4.3 COPY moves the selected range of characters of the currently-selected file to the TEXTRA clip area, but does not remove them from the file. The previous contents of the TEXTRA clip area are lost. If there is no select range, this menu item is disabled. 9.4.4 PASTE inserts whatever is in the TEXTRA clip area into the currently-selected file, at the current cursor location. If a select range is active in this file, it is deleted before the insertion takes place. There is no effect on the contents of the TEXTRA clip area. It nothing has been placed into the TEXTRA clip area (via CUT or COPY), this menu item is disabled. 9.4.5 FIND presents a sub-menu with 2 choices: 9.4.5.1 STRING... presents a requester prompting for the string to search for, ignoring character case. The string gadget will, as a default, contain the previous string searched for (empty if none). However, if a range of characters is selected that is ALL ON ONE LINE, it will supercede any previously-searched-for string as the default for the string gadget. The search begins just past the current cursor location or selected range of characters. 9.4.5.1.1 WRAP... On the FIND STRING requester is a checkbox that allows you to enable "wrap-around" search. Normally, if the search string is not found, TEXTRA terminates the search at the end of the document. With the "wrap" box checked, the search will continue from line 1, and end when either the text is found, or the starting line is reached. This mode also applies to the "FIND NEXT OCCURENCE" menu item (section 9.4.5.2). 9.4.5.2 NEXT OCCURENCE conducts another case-insensitive search for the same text string that had previously been searched for. If no search had yet been conducted the "STRING..." requester is presented. 9.4.6 REPLACE presents a sub-menu with 2 choices: 9.4.6.1 STRING... presents a double-string-requester, prompting for both the string to conduct a case-insensitive search for and a string to replace the it with. The RETURN key will toggle the selected string gadget. The user may optionally: 1). replace all instances of the found string (with the "ALL" button) 2). replace just the next one found (via the "ONCE" button) 3). abort (via "CANCEL"). The search begins just past the current cursor location or selected range of characters. 9.4.6.2 NEXT OCCURENCE conducts another "REPLACE" operation, using the same strings that were used last time. If none exist, the "STRING..." requester is presented. 9.4.6.3 THEN FIND allows the user to decide which instances of the specific text will be REPLACEd, and which will not. This feature is usually used thusly: 1). Bring up the REPLACE STRING Requester (via menu or Right-Amiga-R). 2). Enter the appropriate strings in the 2 string gadgets. 3). Click on the SEARCH button. The first instance of the "Search for:" text will be located and highlighted (text must occur AFTER the cursor in the file, so if you want the entire file checked, put the cursor at the beginning of the document). 4). If you want to REPLACE the highlighted text, press Right-Amiga-Y. If not, Right-Amiga-N. (like Yes and No) 5). The editor will respond accordingly and locate the next instance of the text. 9.4.7 CASE presents a sub-menu with 3 choices: 9.4.7.1 LOWER exhibits 2 behaviors depending on whether an area is selected or not. If there is, the entire selected area is converted to lower case. If not, the next word after the cursor is searched for and converted to lower case if found. 9.4.7.2 UPPER exhibits 2 behaviors depending on whether an area is selected or not. If there is, the entire selected area is converted to upper case. If not, the next word after the cursor is searched for and converted to upper case if found. 9.4.7.3 CAPITALIZE exhibits 2 behaviors depending on whether an area is selected or not. If there is, each word in the selected area is located and capitalized. If not, the next word after the cursor is located and capitalized. 9.4.8 GO TO LINE... presents a string requester prompting for the desired line number, with the initial string gadget contents being equal to the current cursor line (or the beginning of any selected range). First line of file is considered line 1. 9.4.9 EDITING PREFERENCES... presents a requester allowing configuration of: 1). "Auto-Indent" mode (section 4.2.1) 2). "Auto-BackSpace" mode (section 4.3.1) 3). TAB WIDTH value (section 4.5) 4). "Convert CR,LF to LF on OPEN" mode (section 10.6) 5). "Strip Extra Blank Lines on SAVE" mode (section 10.7.1) 6). AlphaNumeric OR Non-Whitespace double-click highlighting (section 5.2) 7). Operation of the F1 Window Size Toggle function key. (section xx). The USE button causes the currently displayed settings to go into effect. The USE+SAVE button performs the USE function, and also saves the current settings in the Textra Preferences file (section 10.5). The CANCEL button causes any currently displayed settings (that have been changed), to be discarded. If the EDITING PREFERENCES requester is active, this menu item is disabled from other windows. (Right-Amiga-E is a keyboard equivalent for this menu item.) 9.5 The "Utilities" Menu 9.5.1 FILE PROTECTIONS... provides the ability to set the 6 relevant file protection bits that are stored and processed by AmigaDOS. These include Deletable, Executable, Writable, Readable, Archived and Script (particularly handy when writing AmigaDOS scripts). The SAVE button causes the currently displayed settings to become active. The CANCEL button is self-explanatory. 9.5.2 HELP ON KEYBOARD... performs the same action as the HELP key (section 4.7). 9.5.3 AREXX... presents a requester with 4 string gadgets. Each will accept either the name of an available TEXTRA-AREXX script such as: slide 4 or a TEXTRA/AREXX command line such as: @gotoxy 0 0;text "Hi, there!" Note that if a command line is entered (as opposed to a script name), it must be preceeded by an '@' character. Also present on the requester is a button beside each string gadget. Clicking it has the same effect as selecting a string gadget and pressing RETURN...that is, to execute the contents of the string gadget. The button text describes the F-KEY that can be used to execute the string gadget contents, but only when the requester is NOT active. Two additional buttons are presented, one to SAVE the current strings for later reloading when TEXTRA is launched. The other button is to CANCEL the requester operation. (The string gadget contents are saved in "S:TEXTRA.CMDS" which is only as large as the length of the 4 strings plus 4 EOL characters). Note that the AREXX menu item is dimmed if AREXX is not available when TEXTRA is launched. While an ARexx script is executing, the 'ARexx...' menu text changes to "Cancel ARexx Script". This feature tries to tell the running script that the user wishes it to terminate, but will only have an effect if the running script uses the CHECKCANCEL Textra-ARexx command. The supplied TEXTRA/AREXX scripts, as well as any you might otherwise aquire, should be copied to your REXX: directory and should end in ".textra". 9.5.4 SET WINDOW FONT... allow the user to change or find the name of the currently selected window's font. This function requires the asl.library. The selection is completely independant of the selected font used for Newly-Opened Windows (9.5.5). 9.5.5 FONT PREFERENCES... presents those aspects of the font display facility which provide save-able configuration parameters. This version (v1.13) only has one; the selection of which font will be used for all subsequent newly- opened windows. The consistant USE, USE+SAVE, CANCEL interface of the other TEXTRA preferences dialog is preserved. --------------------------------------------------------------------------- 10. TEXTRA GENERAL INFORMATION 10.1 TEXTRA always fully expands a specified file or directory name and uses that form to again find the file, if necessary. For example, you may have typed in "DF1:MyFile" as the filename, but the window title will substitute the name of the volume, possibly "MyDisk:MyFile". This is almost always desirable, because if TEXTRA saved "DF1:", you might unknowingly save it to the wrong disk, just because you switched the disk in that drive. TEXTRA will ask you specifically for the same name. The only situation you should be aware of is WHEN YOU HAVE TWO DISKS OF THE SAME NAME in your system. In this case, AmigaDOS can sometimes choose the wrong disk when TEXTRA passes the full-pathname to it. In the above example, we could save it to the wrong disk if the disk in DF0: is also named "MyDisk:" (a backup, perhaps???). This is not caused by TEXTRA, but can happen anytime in AmigaDOS that you use the full-pathname to specify a file. 10.2 Intuition provides two String Gadget shortcuts that can be useful to the TEXTRA user. TEXTRA string gadgets that provide a default text string when they appear will revert back to this string whenever "Right Amiga-Q" is pressed. The "Right Amiga-X" combination will clear any displayed string. 10.3 For most string gadgets, the RETURN key will perform the same action as the "OK" button. One exception is the "REPLACE" double-string requester, where the RETURN key toggles between the two string gadgets. 10.4 TEXTRA Requesters are attached to (drawn in) the window that they have been spawned from. The advantage is that multiple requesters are possible...you can select and work in another file even if the previous window is waiting for you to answer a question. Every window can, in fact, have one or more open requesters. Note that a TEXTRA window will automatically increase in size to accomodate a given requester, and will return to it's original position/size when the requester is closed. 10.5 TEXTRA maintains certain user-settable parameters in the file "devs:Textra.prefs". If your system disk is of the floppy variety, you may therefore be asked to insert this disk if you elect to save it. Normally, TEXTRA looks for this file only once, at startup. 10.6 TEXTRA performs certain operations when reading in a file from disk... 10.6.1 Whenever TEXTRA reads in a file (as a result of an OPEN or REVERT operation, for example), any CR,LF (Carraige Return, Line Feed) combinations will be automatically converted to the standard Amiga End-of-Line representation (Line Feed alone) IF the "Convert CR,LF to LF on OPEN" item is checked in the "Editing Preferences" (section 9.4.9). 10.6.2 Whenever TEXTRA reads in a file, it examines the first 32 characters in an effort to evaluate the file's "text-ness". If TEXTRA thinks it may not be a text file, it will give you the opportunity to abort and read in another file. 10.7 TEXTRA performs certain operations when writing a file to disk... 10.7.1 If the "Strip Extra Blank Lines on SAVE" option is checked in the EDITING PREFERENCES requester (section 9.4.9), TEXTRA will insure that the version on disk will not contain any blank lines at the end. Note that if this feature is used, the SAVE (section 9.2.6) and SAVE AS... (section 9.2.7) operations will take a little longer. 10.8 TEXTRA v1.11 changed it's gadget imagery to be like that in Workbench 2.0. While this color scheme still looks quite attractive under the standard Workbench 1.3 and earlier colors, 1.3 users often customized their palette in radically different ways. For example, instead of something of intermediate brightness for the background color (color 0...WB 1.3 used pale blue), using black causes the shaded-gadget imagery of 2.0 to appear very odd. For this reason, under Workbench 1.3 and earlier, TEXTRA v1.11 will render it's requester and gadget imagery primarily in monochrome (colors 0 and 1). Boolean gadgets (checkboxes) are also rendered differently. 10.9 Keyboard Summary: F1 - Window Size Toggle (7.4) F2 - Keyboard Filter Defeat (4.6) F3 - Page to Cursor or Beginning of Select Range (3.4) F4 - Display next page (6.4) F5 - Display previous page (6.4) F6 - Present previous file (7.6) F7 - AREXX string (9.5.3) F8 - " " " F9 - " " " F10- " " " Help - Displays this information (Keyboard Summary) Shift-Left-arrow - Cursor to beginning of current line (3.2) Shift-Right-arrow - Cursor to end of current line (3.2) Shift-Up-arrow - Display previous page, cursor to middle (6.4) Shift-Down-arrow - Display next page, cursor to middle (6.4) Right-Amiga-O - Open existing file via file requester (9.2.1) Right-Amiga-P - Open existing file by typing its name (9.2.2) Right-Amiga-[ - Open a new file (9.2.3) Right-Amiga-S - Save the current file (9.2.6) Right-Amiga-X - Cut selected text, save in clip area (9.4.2) Right-Amiga-C - Copy selected text into clip area (9.4.3) Right-Amiga-V - Paste clip area into file (9.4.4) Right-Amiga-F - Find string in any case (9.4.5.1) Right-Amiga-N - Find the next occurance of same string (9.4.5.2) Right-Amiga-R - Replace string with another (9.4.6.1) Right-Amiga-T - Find & replace same string again (9.4.6.2) Right-Amiga-L - Set text or next word to lower case (9.4.7.1) Right-Amiga-U - Set text or next word to upper case (9.4.7.2) Right-Amiga-K - Capitalize words or next word (9.4.7.3) Right-Amiga-G - Go to a specific line (9.4.8) Right-Amiga-E - Display the Editing Preferences requester (9.4.9) Requester control... Right-Amiga-X - Clear text in string requester (10.2) Right-Amiga-Q - Restore original string requester text (10.2)