Sphinx.doc v2.5b © 1991, Nicolas Dade. All Rights Reserved permission is hereby granted for non-commercial duplication and distribution doc file for the SPHINX: AmigaDOS device last revised: January 9th, 1992 New in version 2.5b from version 2.5a (in the order implemented) 1) Fixed bug in C-S & C-G in which the cursor was left erased until the next operation (was being redrawn by the writing of text when I was test- ing, but if C-S was pressed when nothing was going on, the cursor was erased and nothing (until the next operation) was redrawing it--no crash, no problem internally, but still unsettling to the user. 2) Changed the window size & position to wb screen bounds checking so that it uses GetScreenData(), and is no longer ever automatically shut off. 3) As was really going on, the first iconized wd is always placed where the main wd was. 4) Null pointer in UndoGadget's image structure when first main wd is opened fixed, now points to `X' (it didn't for an instant during the opening of the initial window; it was visible really only if the program was run in slow motion). 5) C-S is now not canceled by RETURN & its friends, but is canceled by changing the contents of the inputsave (any text key, insert or searching), C-G and S-DOWN 6) Fixed the fragment comparison (again). So simple an algorithm, such a small bit of code (6 lines init, 10 lines loop), and so many bugs. Well, again I think that it will work as described, but I've said that before... . 7) Fixed and cleaned up more stuff in the startup code than I care to admit (single stepped through from first instruction to receiving first write packet from shell). sketched list of changes: a) when using multiple differently named SPHINXs, bug involving code in use being freed (leading to many sorts of crashes) fixed. b) some of the flag bytes are now initialized upon startup. c) no longer bsr to a subroutine which may have been freed. d) reorganized the abort-startup code so that it is simpler, smaller, and fixed a bug involving Audio.device not being closed. e) Got a bunch of stuff (like message ports & messages, and the title of the window, gadgets, etc...) off the stack and into mem that is guranteed to be PUBLIC (the stack is not allocated in PUBLIC mem!). f) some mem wasn't being freed on shutdown (256 bytes worth); it is freed now. 8) CON and NEWCON support some formats in the window definition string of which I was not aware; there are "default" positions and sizes, i.e. `NEWCON:////' is legal, and SPHINX now understands SPHINX:////. In addition, since in WB2.0 there can be further parameters beyond the window name, SPHINX does not understand them (because as of I now, I don't know what they do), but does strip them off when it sets up the window's name. 9) I am not sure, but I think that in v2.5a the deferment of the cursor was not enabled because some debugging code was left. 10)Fixed two bugs involving empty saves. One involved scrolling backwards over empty input saves when there was nothing above these saves. The other happened when all the packets between two input saves ended up compiling to nothing (SPHINX found no characters it wished to save--all just unknown control codes); then the list of saves was corrupted, and any sort of crash was soon to follow (usually just Odd Address, but...). 11)Changed the SPHINX guru displayer so that it used AutoRequest() instead of DisplayAlert(), so it is much less jarring. Note however that an AutoRequest() can still end up as an alert if, say, there is not enough memory to do the whole window thing. 12)Changed C-S to SC-S, and renamed it defer-scrolling. Assigned C-S to toggle stop-output. C-G and C-Q both restart output and un-defer scrolling. 13)Changed written text interpretor so that it handles ESC & CSI sequences better, and so that it correctly strips DCS,OSC,PM & APC sequences and SS2 & SS3. 14)Now ARP.library pattern matching can be used to search for old input lines. Using a wildcard character in the search string causes the arp.library to be searched for, and if it is found then wildcard pattern matching is used to search, and the case sinsitive/insensitive still applies (all uppercase means case insensitive) 15)Found some code which claimed to do dead keys, spent some time finding out just what it did (I can't read Pascal very well), and then implemented it in sphinx, and it works! To handle dead keys, when building an inputevent out of the intuitionmessage set Class=IECLASS_RAWKEY,SubClass=0,Code= im_Code,Qualifier=im_Qualifier,TimeStamp+TV_SECS=im_Secs,TimeStamp+TV_MICRO= im_Micros,NextEvent=null,and, most important, Address=contents of the address pointed to by im_IAddress. I don't known what it points to, but there is something there which makes the dead keys work. 16)RA-C now opens a configuration window in which the settings of the SPHINX are reflected and may be changed. 17)SPHINX now understands the window bounds report request CSI (CSI0 q), so now programs like LS work as they did in a CON/NEWCON window: i.e. LS now prints out using multiple columns. 18)Write() compiler now handles SGR22,23 and 24 (Bold,Italics,Underline off). 19)When interpreting an SGR the order in which the arguments are acted upon now matches that of CON/NEWCON; from left to right. (so CSI0;32;43m will end up with normal text in color 2 on color3, instead of normal text in the normal colors) 20)Using RA-C when the config window is already open brings it to the front and activates it. 21)The faked coniorequest and conunit which are returned in a DiskInfo() call had a bug in them: the io_Unit was not pointing to the conunit; this is fixed and now some programs are actually fooled! 22)Added non-blocking-typeahead mode where typing ahead does not block output to the window. 23)RA-B causes the bell to be rung (or, if there is no bell file, the screen to be flashed) the next time a read packet is recieved and there is nothing to give it. It can be canceled by going to the RA-C configuration window. 24)RA-R and SRA-R cause, if it is not already there, an arp file requester to pop up. When a file is selected, if RA-R was last pressed, just the filename is inserted; if SRA-R was last pressed, the whole path & filename. RA-R & SRA-R may be pressed (in the SPHINX window) while the file requester is visible; SPHINX just does the insert when the file requester returns, but in the mean time continues to run. 25)RA-W searches back in all text for the next word which starts exactly like the word to the left of the cursor, and if it finds one, finishes the word under the cursor; can be hit multiple times. This is called wording. 26)RA-X/Undo cancels wording if wording is the state you are in. 27)The word left & right routines (A-LEFT & A-RIGHT) now stop at the end of words too-this is a better implementation since the end of the word is where you are headed for as often as not. 28)When the iconize gadget is pressed (or RA-Z), instead of closing the window right away, I set a flag to pend the operation until all the other messages in the window's port have been handled. That way if the SPHINX is doing something, and you press RA-Z, and then, since the wd has not gone away yet, you type some other stuff, it is recieved by SPHINX. 29)S-UP and C-R do not repeat at all. 30)Played with word right & left again. Now if we are thinking of stopping at the end of a word there are some conditions under which we do not. First if the start of the next word to the right is one non-word character away from the word to the left, then we go on to the next start of a word, in the direction we where headed in the first place. Secondly if we are headed towards the right and distance we have crossed was one character wide, then we keep on going to the start of the next word to the right. Don't worry about trying to memorize this-it is easier to watch the cursor move and stop when it gets clossest to where you wish it to be. 31)Changed copyright notice so that it contained both `(c)' and the word `copyright', as a good copyright notice should. 32)Global toggle added so that you may tell SPHINX not to try to open arp.library if you don't like those alerts in WB2.0. 33)SRA-I now first pops up an arp file requester which shows the default insert file, and you can specify any file you like, or cancel the insertion. 34)Added ARP call to SPHINXConfig (it doesn't need arp.library, but it is nicer if you have it); now when you click on the filename gadget, if arp could be opened you get an arp file requestor. 35)Made SPHINXConfig more robust about error recovery. Now if it is given a file to load which exists but which is not a SPHINX config file, it changes filename, but does not change the gadgets, and does not lock up! --- In progress: 1) Finishing the config window. Most of all, put a [Save Config] gadget and get rid of SPHINXConfig completely. All that would be needed would be a little program which converts a 2.5 config file to a 2.6 by adding in the new fields. --- To be implemented/ideas (maybe): 1) When a word is grabbed w/ double-click, while the second click is held down, leave the word inverse-videoed so that the user can see what he is clipping. And while the lmb is down, clicking the rmb cancels the clip. This rmb cancel should work w/ any clipping, really. 2) Have some way of opening the intconfig window using only the mouse, since you may be about to grab the mouse to change something in it anyhow. 3) Some sort of "on-line" help. 4) Go back and work on letting the user type into the main wd from the config wd & the RA-O no-refresh-message problem. 5) If clipping by dragging the mouse, can clip either just a part of a line, or, if you move to other lines, can clip the whole set of lines, and the window scrolls to help you do this. 6) Alt-up/down,Ctrl-up/down work while mouse is being held down for a multi-line clip. 7) Allow a string to be searched for in the outputed text by having the user type the string in the input line, and then press RA-S. The input line in seen as a pattern "*inputlinetext*", and that includes ANY characters in the input line Window is scrolled so that, if the next occurance is not yet visible, it is on the top line of the window, and a little image of a hand/finger (get it from MD&D's menus) is drawn pointing to the first character of the string, and in sich a way that it does not go out of the bounds of the window, so it can point either way, and also so that it does not overwrite the string, it is pointing upwards so that the wrist is below the string's first character. When the hand is drawn, a flag bit is set, and the next manipulation of the display causes the hand to be replaced with the imagery that was drawn there before (which was saved when the hand was drawn). Look into using the blitter's animations/double buffering to do this. To accumpany this, a new config option to set the color of the hand, and the color of the border of the hand. These can be any color (0-255), instead of just (0-7). 10)Change the extracharlists so that they can define other sets of characters which also count as a word: so that [abc...xyz][012...789] sort of thing could be done: `abcdefg' is a word, `01234' is a word, but `abcd123' is two words. 11)Allow the user to chose what percentage of the screen to scroll when the "half screen scrolling" is enabled, since when a very tall screen a 50% scroll is quite a bit/most of the time the bottom half of the screen is not used. This is also good for those who want the speed-up but not the extent of a half screen scroll. Implement as % to scroll, min # of lines, max # of lines (and, of course, Y/N flag) so that everyone can have their preference. 12)Change the SPHINX Open() string interpretor so that it understands or at least strips off CONMAN style opens. 13)Understand at least some of the 2.0 flags and stuff in filename, at least ACTIVATE/INACTIVATE, because that one can be a real nuisance, bot others too if easy & possible. 14)While clipping with the mouse, do: RMB cancels clip. while the LMB is held down, any "strange" IMMsg cancels the clip, but the keys `C', `P' and `F' finish the clip and send it to the clipboard, private or file respectively, irrespective of the state of the undo gadget. Also think about what would happen if SPHINX was not able to run (WAITING) when the user tried to do a clip. If the wd did not need to be scrolled, would it all work out? That is, would the fact that the MOUSEMOVE flag was never set not matter? SPHINX just looking at the XY in the LMB DOWN IMMsg and the LMB UP IMMsg. 15)Think about rewriting the scroll gadget and the clipping routines so that the loop goes back through Main_Loop so that the user can use all the keys he is acustomed to during the scroll or clip w/o extra code for that. This would mean getting rid of some optimizations but it might be possible. (at a miminum forbid the freeing of anything during a clip or a scroll) 16)Add an option to the scroll gadget so that it scrolls you inside a subset of the full list of saves (like just back to the last non-just-LF inputsave for quick scanning of, say, the last `dir'. The way to do this is to have the user hold down the SHIFT key when fiddling with the gadget to indicate that he wants to look at just the last output. 17)Add the possibility of having a log file (would hold everything that was entered or outputed in chronological order). Could either rewrite or append the log file. 18)Except for the clip-file, when a file exists and you are going to rewrite it, put up a requestor saying "File exists/[Cancel][Append][WriteOver]" 19)Have some sort of insert/typeover mode and toggle 20)Provide some way of a) entering an input line w/o having it ever be made available-that is, it is just there for the history, and b) some way of loading a history (This should be done both in startup, with a global history file, and at any later time privately by going to Sphinx-Config 21)Have a flag in the config file which says "don't actually open the window until something is read or written to it". It would work by saving the open string, and when a read or write packet is recieved and wd_not_open, would first simulate an open packet. 23)Have numerical string gadget to say what wd height to use when lying 24)Go back and add all this stuff to SPHINXConfig & the config file. 25)Have clipping mode "And To Clipboard" where any clips go to their usual destination and also to the clipboard. 26)Let the user chose the clipboard unit read from & and clipboard unit written to both for the "& to Clipboard" and the explicit to clipboard clip. 27)SRA-F should first put up a requestor which does not put SPHINX to sleep explaining what is going to happen if the user says OK. Since SPHINX is not asleep the user can reposition the top line and spot10 before saying OK, or can cancel if a mistake was made. 28)Add toggle `Spot-10 Defined' so the user does not have to remember A-F10. 29)The insert filename ((S)RA-R) should first try to use the req.library since its requester is better than arp's, and would permit more complicated insertions (multiple filenames for a delete, for example). 50)Add ExtraUserWordWordChars to the configuration file (and make it v2.5) and change RA-W code so that the extra chars are used. 51)Add Sphinx Alerts all over the place (especially for AllocMem: in fact, maybe have a second Alloc_Mem call which shows an Alert if it is not successfull). 52)There is going to be a problem with changing a global var like fgb_NoArp since other SPHINXs aren't going to update their config wd's when they aren't the ones who toggled it. Is a global list of all SPHINXs in order? ------------------------------------------------------------------------------ New in version 2.5a from version 2.4b (in the order implemented) NOTE: Because it is just about to evolved into two independant things, the term grabbing is now replaced by two different terms, clipping or inserting. 1) When a window is iconized for the first time, the iconized window opens where the main window was when it was iconized, not where the main window opened. After that the iconized window opens were the iconized window was closed, like before. 2) SRA-[ and SRA-] now also do WindowToFront/Back, for those moments when you cannot bear to lift the shift key. 3) RA-O opens the window to the full size of the screen (but does not change its depth arrangement), or, if has already been opened with RA-O, shrinks it back down to its pre-RA-O size and position. 4) Changed wording of Sphinx alert from `Cancel' to `Continue', and from `guru' to `alert'. 5) Changed size of icon file for SPHINXConfig to about half previous size. 6) Changed SPHINXConfig so that it checks/alters Minimum Write Buffer Length before it saves it, so now if you reload that config file, your value may have been adjusted. 7) RA-I inserts from the clipboard.device unit 0 to the input line. 8) Changed Write() handling code so that characters between $80 and $80+' ' are stripped out. 9) Fixed bug in bell file loading code. Now when the bell file cannot be found you don't get an alert and then window closing, but rather, as the docs say (and said), I use DisplayBeep() instead. 10)Changed insert_n_chars_into_inputbuffer routine so now if the string won't fit, as many characters as will fit are inserted. This effects all insertions (typed text, from clipping, clipboard or file). 11)Fixed bug in which the last character of the first window line of an input line was sometimes not being drawn by some of the text drawing routines. 12)Changed deiconizing routine so that if you want to deiconize with a key- stroke it must be a keystroke that produces a (or some) characters in the default keymap; just hitting the shift, alt, amiga, ctrl, or caps keys won't deiconize the window. 13)Clipping can now also go to the clipboard (so that programs like Snap can use it), or to a file, and that file can be either appended or rewritten. 14)To go with new clipping modes, RA-G has been changed: now, if you start out in private clipping, successive presses of RA-G cycle through (one time clipboard clipping),(one time file clipping) and (private clipping). Successive presses of SRA-G cycle through the same things in their locked versions (of course, locked and "one time" private clipping are the same thing). If you in a locked clipping mode, once you have clipped, the next time RA-G or SRA-G is pressed, you go back to private clipping. Then, from there, you start cycling through as usual. NOTE: there is no longer such a thing as global grabbing-that is now achieved by clipping to either clipboard or file, and then, in the destination window, inserting from either clipboard or file. 15)RA-X and UNDO no longer cancel the clipping mode, only (S)RA-G does this. 16)New Config options: file name to clip to, from, inital clipping type (private|clipboard|file), and initial dest file mode (rewrite|append). 17)RA-P and a config option specify whether inserted text should be inserted as literal characters or parsed. Thus you can form simple (no ifs, loops, etc...) macros by asking that a file containing the commands in the macro be inserted and parsed. When parsing an insert, CR = LF = enter line and make it available to caller (Read()). 18)Made undo gadget imagery changing routine safer. (used RemoveGadget & AddGadget before and after change) 19)Fixed bug in my msgport w/ sigbit initializing routine in which the msgport's list was not being correctly initialized to empty. I don't know why this did not cause crashes earlier, because this is rather a nasty mess, but, oh well, it's fixed now. 20)Set up a work around of a problem in C='s dos.library by setting up, for each SPHINX window, a second task caller SPHINX.doscaller.v2.5a which calls dos.library for the SPHINX task when before SPHINX was doing so itself. The reason I have to do this is 1) the dos.library calls are synchronous calls, they use the pr_MsgPort to wait for and receive replied packets from the dos device to whom we are talking. In SPHINX, since SPHINX is also a dos device, messages from other programs to SPHINX also arrive at this same port. If this happens while SPHINX is itself inside a dos.library call (or if there is already a message/packet waiting at that port) then the dos.library call find that one, realizes it is not the message/packet which it sent, and goes to an AsyncPacket GURU. I do not see how to use pr_PktWait since I do not know what packet I/ dos sent, and therefore should be waiting for; I see no way of distin- guishing between the replied packet and the packets comming from other tasks talking to us. This task is also used for OpenLibrary and OpenDevice when C= has not promised that the devices will be in ROM (like clipboard- .device) NOTE: this is really simple to solve, but C= has to do it, since all that code is in ROM. All they have to do is do like DoIO: WaitPort(port), look for the expected msg, if there, unlink it and exit, restoring the task's signals to reflect whether any msgs arrived to that port which were not dos's and/or whether the sigbit for that port was already set, else Wait(port's sigbit) again.... 21)RA-A will insert the last clipboard or private insertion again. This saves you from having to go back and find the text again if you have moved, or from having to not put anything in the clipboard. This is done by saving the inserted text when it is inserted the first time, so even if the privately clipped text has been freed, or the clipboard file has been changed, this still inserts what was last inserted. File insertions are not saved by SPHINX for RA-A because of the next change... 22)The insertion of a file is handled by a seperate task (SPHINXFileInserter) so that the rest of SPHINX does not go to sleep while the insertion is taking place; the insertions looks just as if you are typing the lines in, except that those lines do not get in the way of any lines which you might be typing in: you can scroll the window, clip from or to it, type in stuff, etc... while the insertion is taking place. What's more, you can start an insertion, use RA-C and change the insert file, and hit SRA-I again, and change the insert file again, and use RA-P to toggle parsing on or off, and hit SRA-I again... as many times as you like and all these file insert- ions will be performed sequencially each from the insertfile which was defined and the parsing/no parsing mode active when SRA-I was hit. This is not much of a big deal when you are inserting a small, quick file, but if you are inserting with parsing from, say, a SER: or AUX: sort of device, you can now manipulate the contents of the window while the insertion is taking place, and this insertion may actually never end (if the insert device or file never returns an error or eof), and you can still use the SPHINX window as your own. Does this give you any ideas? 23)Fixed bug in the undoing of an A-DEL. Sorry about the characters comming out in the wrong order; just a little bset that should have been a bclr. 24)Added support for ACTION_UPDATE packets, since I now know what they are. Sphinx now reacts to ACTION_UPDATE just like ACTION_FINDINPUT or OUTPUT. 25)C-B now always cancels the search and restores the input buffer, so it is no longer equivalent to S-DOWN, but rather to the C='s shell's definition. 26)SPHINX now works a little bit better with programs who ask for DISK_INFO; it now builds a fake console unit structure for the callers. XX)C-S sets a flag which disables the automatic scrolling of the window when when the cursor goes off the window. This is usefull when, say, you are running a program which i outputing a lot, and you are reading some stuff which it printed at the top of the window while it is just about to fill the window and cause the window to scroll. By pressing C-S before this happens you keep the window from scrolling (when you want to see the text which would have caused the scrolling, just A or C or S-DOWNARROW. This flag is canceled by entering a line (RETURN,ENTER,C-J,C-M,C-\) or S-DOWN. 28)C-G manually cancels the scroll lock New in version 2.4b, from version 2.4 (in the order implemented): 1) Fixed bug in the font finding code. If you don't specify a font in the configuration, SPHINX now really doesn't display an alert. 2) Changed AutoCanceledGlobalGrabbing so that it no longer is a config option, but instead is selected by you in the same way that Literal or LockedLiteral is selected; by using either RA-G (cancel after this line) or SRA-G (locked). This does not make the 2.4 config file incompatiable, but it does get rid of that flag in SPHINXConfigv2.4b. Feed Sphinxv2.4b a v2.4 config file, and that option is ignored. 3) Fixed big bug! When a line with a change of text style (SGR) in the middle of it was written to the window, and that line did not end with a CR or LF, but rather was part of a larger line, then the cursor was being misplaced after that line was written, and later characters, which start being drawn at the cursor, would write over previous text. When that line was redrawn later (due to scrolling, etc...) the text came out correctly. This is fixed (just needed a little bcc.s in the right spot). NOTE TO THE ANNOYED: If you have some scripting stuff that talked to a SPHINX window, and it no longer works because I have changed the clipping/inserting completely, I can only say I am sorry, but that is why I do not ask for money--so that I can make mistakes and fix them cleanly, instead of using some backwardsly compatible kludge I would feel abligated to use if money was involved. If you really need your scripts that only work with an older version then you can have different versions of SPHINX in your machine at once. To do this, you have to rename the different version handlers to different names, change the configuration file names, the Mount in the startup sequence, and make different entries in the Mountlist, just as you would to have two differently configured but same version SPHINXs. And in the Mountlist entries, use different names and, unlike with differently configured same version SPHINXs, USE THE HANDLER CORRESPONDING TO THE VERSION YOU DESIRE. ------------------------------------------------------------------------------ New in version 2.4, from version 2.3 (in the order implemented): NOTE: those changes numbered with an X no longer apply to v2.5 X) Global grabbing from any SPHINX window to any other with RA-G. 2) New config option (yes or no) to allow stripping of CR, LF or FF from the end of a grabbed line, and another having to do with global grabbing. 3) Bell files can be shared between any SPHINXs. 4) Duplicate input lines are not shown when searching back with S-UP,UP and DOWN. You only see the newest version. 5) RA-] and RA-[ move the window to the front and back respectively. 6) Code that is used only once is freed when it is no longer needed. This saves about 2 to 18K, depending on how much can be freed. 7) The little `10' that used to appear only over the `X' when spot 10 was defined now appears no matter what background letter is displayed. 8) The comparison of old input lines (S-UP) can now be case sensative or case insensative, depending on whether the search string is all uppercased or not. This effects all the comparisons. 9) Bug in SPHINXConfig involving the blanking out of the Save gadget is fixed. 10)Bug in SPHINX involving extra memory not being freed upon startup is fixed. 11)User configurable input strings can be tied to C-Fn for quicker access to common input lines. 12)If there are differently configured SPHINXs around, all but one (the first loaded) free most of themselves (all but about 500 bytes) and use the code of the first. This saves a lot of memory when using differently configured SPHINXs. Because of this, much of the startup code has been rewritten, so any old bugs there may be gone (replaced no doubt by new ones). While I was at it, found bug in the error recovery code and fixed it. 13)New keystroke SRA-F (Shift + Right Amiga-F) which frees all memory that can be freed. Now you dont have to hold down RA-F if you want to free everything. 14)Only the very first SPHINX window prints out the startup message, instead of every first differently configured SPHINX's window. 15)Bug in editor in which when exiting search mode the cursor could exit the window without the window being scrolled is fixed. 17)New config option InputTxtColor (1 through 7) choses the color with which to draw the input lines, so that they may be differentiated more easily from written text. 18)The fragment comparison is completely rewritten, so all old bugs are gone (and some new ones probably introduced) (actually the new code is much simpler than the old, so I have more hopes in its being bugless than the old.) The new code now does exactly what the DOCS describe, and is much faster than the old. 19)The don't-repeat-a-key routine is changed so that a key that is not sup- posed to repeat does nothing at all if the key has been released, instead of doing whatever action was assigned to that key one last time. 20)Bug involving the undo buffer flags not being canceled when the cursor is moved with the mouse is fixed. 21)New key stroke SRA-L (Shift + Right Amiga-L) which toggles the literal trigger like RA-L, but when the trigger is set by this keystroke it is not automatically canceled by useing it; this key locks the literal trigger until it is cancel manually, allowing you to type a large amount of text that involves characters that would have required reloading the literal retrigger a good deal by just setting the trigger once with this key, typing the text, and then unloading it with SRA-L (or RA-L, or UNDO). 22)The drawing of text has been changed so that lines that contain a lot of low valued characters ($05 to $19) are drawn at full speed, instead of one character at the time. characters $00 to $04 are still drawn one character at a time, but that is because of the way they are stored internally. 23)Bug in keyboard handler which took 40 bytes from the stack when a key returned a too long string is fixed. 24)If you are searching, but have scrolled so that the cursor is no longer visible, when S-DOWN is pressed, instead of canceling the search, the window is scrolled to make the cursor visible. 25)Internal change makes writing text to SPHINX faster. This has turned out to be a large rewrite. 26)Bug in which when the upper left character was in the input buffer, and the window was resized, the cursor ended up at the wrong place has been fixed. 27)Bug involving the input buffer characters being drawn in italics, under- lined, etc... when the input and write fonts were the same font is fixed. 28)Bug in which if the SPHINX was occupied doing something else, a single lmb click could leave you stuck in the grabbing mode until you did some- thing else is fixed. 29)The window now scrolls continuously when the scroll gadget is moved, which makes it much easier to find the text you seek. 30)A multiplicity of bugs that occur when the upper left character is in the input buffer, and the cursor is out of sight above the window, and the input buffer is edited have been fixed. XX)Various parts of this file have been edited for, I hope, greater clarity, or to add new features. This list and SECTION V are the only places any reference to the v2.3 are made. The rest of the file can stand alone as the DOC for v2.4. 32)PowerPacker was never usable on SPHINX. That was a misconception of mine that crept into the DOC file and was never deleted. (the problem is that the second time the code is run, PP's decoder is still there, and tries to decompress the decompressed code, which leads to garbage) 33)The v2.3 icon (SShell.info) made reference to AShell (Arp's Shell). It now makes no reference at all, and must be edited before it can be used. (See setup instructions) 34)Some internal changes in SPHINXConfig have made it more usable, and you now can specify an initial filename if you start it from a CLI. XX)SPHINX now tries to open the arp.library when it is needed, not at start- up. This solves the problem of having to cancel an alert telling you that SPHINX wanted arp.library in WB2.0 when SPHINX was started. Now if you never (try to) do a wildcard comparison, then SPHINX never looks for arp.library. (Like the bell files, the arp.library pointer is shared between all SPHINX's, so only one SPHINX needs to open it, or only one needs to try and fail) 36)If the lnheight supplied in the config file is too small for the fonts SPHINX is actually going to use, then it is automatically increased. 37)Fonts must, in addition to the older criteria, have a non-zero width. 38)Added alerts to SPHINX so that using the chart in SECTION I you can find out why SPHINX refuses to run on your system, which gives you some chance of correcting the error. 39)BS, DEL, A-BS and A-DEL do not repeat after being released. 40)Improved an achiles heel of SPHINX: when the iconized window cannot be opened, it now alerts, then waits 2 minutes and tries again, giving you a chance free some memory. 41)Added file SShell to package so that workbench can be used to manipulate SShell.info. 42)Bug in which if the user's font cannot be used, it is not closed (CloseFont()) is fixed. 43)Bug in the testing of the font to see if it is proportional or not is fixed. 44)Bug in the testing of the memory font to see if it is exactly what was requested is fixed, so that now if in the machine you have a font of the desired family, but not the desired height, the font is looked for on disk instead of the wrong-height version in the machine being used. 45)No key is allowed to repeat after it has been released. 46)Bug in which when the input font was not square (font height = font width) editing the input buffer when it covered only one line made a mess visually is fixed. 47)Iconizing routine changed so that the iconized window is made active only if the main window is active just before it is closed, and the main wd is made active when it opens only if the iconized window was active (it might not have been if the main window reopening was forced because of a DiskInfo packet). 48)The Free-A-Save routine (used by the automatic memory use limiter and RA-F) is changed so that it always frees the whole set of blocks of text between the input lines, even if there is more than 32K of text. And the write save counting routine has been changed so that all that text counts as only one save. 49)Write save compression/optimization is gone. It has been replaced with a new config line, the minimum length of the write buffer, and new code. Now the written text goes into a buffer until the buffer is full or a new input line is added. 50)Dropped the idea of using the arp.library for a comparison for two reasons: the arp.library's compare was slow, and the fragment comparison takes care of the most common use of the wildcards, the xxx*yyy*zzz or xxx#?yyy#?zzz sort of comparison. Due to this, the config file has the wildcards line removed, etc.... 51)Replaced the wildcard line in the config file with a new option: the minimum number of characters - 1 the search string must have in order for the fragment comparison to be attempted. 52)More speedups and optimizations have now made SPHINX's speed comparing to or even greater than NEWCON's. 53)The (re)drawing of the cursor is now defered internally until the SPHINX has nothing else to do (about to call Wait()). This makes SPHINX faster when the program talking to it talks quickly and asynchronously. It also, in a strange reversal of the expected, sometimes makes SPHINX faster when you reduce its priority, because since the program sending the packets can make the next packet before SPHINX would go to sleep, so the cursor is not drawn and then erased until all the data is written. This is a help with some terminal programs, which, due to their nature, communicate asynchonously with SPHINX. 54)New Config option allows the window to be scrolled half its height instead of just enough to bring the cursor into sight after new text has been drawn (Write()) and the cursor has gone out of sight. This speeds up text output because of the reduced number of scrolls that have to take place. 55)Changed the auto-save freeing so that empty input saves are freed first, then duplicate ones, and only after these have been finished, are unique input saves freed. Also changed the way write saves are freed, all those between two input saves (or the top and an input save) are freed as a block. And input saves cannot be freed unless they are above all write saves. 56)SPHINXConfig is compressed since it contains a lot of zeros, but not in a pattern such that a BSS hunk can be used. 57)Changed word left or right routines so that they stop with the cursor at the beginning of a word, like most other word left/right routines. XX)Added code to window opening routine so that it moves or shrinks the new window if it is not going to fit in the screen where it is. This can only happen if the workbench screen can be found before the window is opened, and the screen structure has not ever moved, so that if they are multiple wb screen, like a certain PD program allows you to have, then this is disabled rather quickly. 59)Changed delete word right or left routines so that the first non-word character is no longer deleted. 60)Added support for C-J, so now multiple input lines can be entered and visually seperated without making them available to Read(). 61)Bug in which when searching, the input save you are looking at, or one below all this can be freed is fixed. 62)Rewrote keystroke parser so that keys that return a string that is really several commands in one (the default keymaps dont have this, but anyone can edit/create/use a custom keymap that does do this) are handled correctly. This also ended up making that hunk smaller, since the keyboard decoding routine was becoming spaghetti code (is there any language/organ- ization that makes the interpretation of an ascii command string elegant?). 63)Changed C-X routine so that if the cursor is not at one of the ends of the inputsave, then the old undo block is erased before the new characters are added to it. This way when you undo after a C-X, there is no garbage. 64)Changed keystroke handler so that anything SPHINX does not understand ends up in the input buffer, instead of some stuff (like HELP) being ignored 65)Height of iconized window is topborder-1 of main window, or 4, whichever is larger. 66)Once the first window is opened, and so therefore two fonts have been found somewhere, the user no longer gets font related alerts from another SPHINX that has the same configuration except the topaz font alerts, which are fatal (to that SPHINX, not the system, of course). 67)Changed delete word routines, A-BS & A-DEL, so that they delete nothing to the wrong side of the cursor. This, incidently, also fixes the bug in which the undo buffer recieved characters in the wrong order if, after some other deletions, a word deletion is started in the middle of a word. 68)Fixed bug in which when the last text consisted of an input line and the input buffer, with nothing in between, then clicking just beyond the end of the input line moved the cursor in the input buffer to the first character instead of starting a grab 69)Bug in which the cursor, characters etc... end up at the wrong character position in the input buffer when there is no write save between it and the right edge is fixed. 70)Changed the whole format of the config file so that most of the work is done by SPHINXConfig instead of SPHINX. This makes SPHINX and the config file smaller. It also makes the v2.3 file completely incompatible with everything. However future versions of SPHINXConfig should be able to read in v2.4 config files for conversion to the higher version, since the file now starts with a long word version identifier ('SPX'<<8+$24). 71)Added config options to give the iconized window front-to-back gadget(s) and make it automatically go to back after it is opened. 72)Added config option to have the window, when the cursor scrolls off the window because the cursor moved back or forth in the input buffer, be scrolled enough so that the the cursor is centered, instead of just in sight. 73)Changed startup code so that if the long startup fails, it is tried again if SPHINX is started again, and got rid of the self modifying code. 74)Changed the routine that changes the imagery of the undo gadget so that if you are clicking on it at the moment it is changed, or you have resized the window, it is drawn correctly (used RefreshGList() instead of DrawImage()). 75)Changed keystroke interpretor so that keys that I map beyond the capabi- lities of the ansi ascii I interpret at the raw key code stage (Fn,BS,DEL and ARROWS) However, if their key codes appear in a string of another key, that still works.