home *** CD-ROM | disk | FTP | other *** search
/ Otherware / Otherware_1_SB_Development.iso / amiga / system / sphinx.lzh / SPHINX2.5y / Docs / Commands.doc < prev    next >
Encoding:
Text File  |  1992-01-09  |  22.8 KB  |  527 lines

  1.  
  2.                   Sphinx.doc v2.5b
  3.          ⌐ 1991, Nicolas Dade. All Rights Reserved
  4.  permission is hereby granted for non-commercial duplication and distribution
  5.           doc file for the SPHINX: AmigaDOS device
  6.  last revised: January 9th, 1992
  7.  
  8.             - - - - - - - - - - - - - - - - - -
  9.  
  10. The gadgets:
  11.  
  12. [Iconize] (or RA-Z):
  13. This closes the SPHINX window and opens a small drag bar in its place.
  14. Everything else keeps working as if the main window were open except,
  15. naturally, nothing is drawn. This results in both a speed increase and an
  16. uncluttering of the workbench screen.
  17. To reopen the main window, activate the drag bar (click on it with the lmb
  18. (left mouse button)), then either try to access a menu (rmb) or press a key
  19. which produces a character (Shift won't work). If you press a key, the key
  20. is only used to open the window-it is not entered into the input buffer.
  21.  
  22. The iconized window and, when it is reopened, the main window, are made
  23. active only if the previous window was active.
  24.  
  25. The first time you iconize, the iconized window opens where the main window
  26. was when it was iconized. From there on, the iconized window opens were it
  27. was when it was deiconized.
  28.  
  29. There is a certain request that the calling program can make of SPHINX:
  30. (DiskInfo packet) that is rarely done, but that forces SPHINX to lock the
  31. window; thereafter you cannot iconize it because that would close the main
  32. window. When this happens, if the window is iconized, it is deiconized. Then,
  33. in either case, the iconize gadget is ghosted and RA-Z is disabled.
  34. This condition is rare, but if it does occur and you dont like it, then it
  35. was some program you ran that caused it. Not running that program will
  36. be as close to a fix as you are going to get.
  37. NOTE: It is my guess that most programs that ask for this information are
  38. about to do something not quite legal, and probably are going to crash
  39. anyhow. But you can never tell... .
  40. NOTE: WB1.3's SetMap does use this (I have no idea why), and does not crash.
  41.  
  42. RA-Z:
  43. Keyboard equivalent to the Iconize Gadget.
  44.  
  45.  
  46. [Scroll]:
  47. When depressed and when moved, the window is redrawn making the top line the
  48. line the fraction of the gadgets distance from the top into the list of saved
  49. text. This is determined by bytes, not lines, since the number of lines
  50. changes every time the window is resized.
  51.  
  52. Unlike most scroll gadgets, this one does NOT move when the window is
  53. scrolled by some other means. This is done for speed, since scanning through
  54. many KBytes of data to compute what its position would be is slow. If you
  55. don't like it, then don't use the scroll gadget. (actually you will find that
  56. this is not as big a problem as you may imagine it to be. Try it and you will
  57. see you really didn't need the scroll gadget's position to always be
  58. correct-just after scrolling is all that seems to be needed, and that is does
  59. happen with SPHINX).
  60. Clicking above or below the scroll gadget will move it by a very small
  61. fraction (so small that often the image itself doesn't move). This gives you
  62. a way to scroll the window small increments without using the keyboard.
  63. The image on the scroll gadget is a sphinx (or as close to one as can be
  64. drawn in such a small space)
  65. Sometimes the redrawing of the window is achieved by a short scroll, at other
  66. times the whole window is redrawn. What is happening is internally SPHINX is
  67. trying to do a scroll, since it is faster, but when certain internal
  68. variables change (like the total length of the text saved), the scroll
  69. routine cannot be used, the the whole window must be redrawn.
  70.  
  71.  
  72. [Undo] (Literal,Searching,F10 Locked,Clipping) (or RA-X):
  73. This gadget serves various purposes, depending on the state of SPHINX.
  74. Ordinarily its imagery represents the current clipping mode:
  75.  `X' for private, `C' for one-time clipboard, script `C' for locked to
  76.   clipboard, `F' for one-time file, and script `F' for locked to file.
  77.   When it is hit, the last deletion or insertion is undone:
  78.  If you have just inserted some unparsed text, or just undone a deletion,
  79.  then Undo deletes the text you have just inserted. This is canceled once the
  80.  cursor is moved or a character inserted or deleted. Else the last block of
  81.  text that was deleted in one place using any combination of (BS, DEL, S-BS,
  82.  S-DEL, A-BS, A-DEL, C-X, or Undo) is restored.
  83. When the literal trigger is loaded, its imagery is an `L', either script L or
  84.  straight L. When hit it just unloads the trigger.
  85. When the contents of the search buffer are valid, then its imagery shows an
  86.  `S'. When it is hit, it cancels the search and copies the search buffer back
  87.  into the input buffer-restoring the input buffer to what it was before the
  88.  search.
  89. When the Spot 10 is defined, a small `10' appears in the lower right corner
  90.  of this gadget, on top of the main imagery.
  91. When inserts are going to be parsed, a small `P' appears in the lower left
  92.  corner of this gadget, on top of the main imagery.
  93.  
  94. RA-X:
  95. Keyboard equivalent to the Undo Gadget.
  96.  
  97.  
  98. [Resize]:
  99. When the window is resized the whole window is redrawn. The old upperleft
  100. character is kept in the top line of the window, unless the cursor was
  101. previously visible and would not be visible in the new window if the old
  102. upperleft character were put in the new top line. In this case the window is
  103. scrolled down to that the cursor is visible again.
  104.  
  105.  
  106. RA-] & SRA-]:
  107. Pop the SPHINX window and, if it is open, the configuration window, to the
  108. front (keyboard equivalent to the WindowToFront Gadget).
  109.  
  110. RA-[ & SRA-[:
  111. Push the SPHINX window and, if it is open, the configuration window, to the
  112. back (keyboard equivalent to the WindowToBack Gadget).
  113. NOTE: if you cannot remember which is which, remember this: the [ and ] keys
  114. are arranged on the keyboard in the same ordinal pattern as the WindowToFront
  115. and WindowToBack gadgets are in the upper right of a window (well, in WB1.3
  116. and lower): the key on the right pops to front, the key on the left pushes to
  117. back.
  118.  
  119.             - - - - - - - - - - - - - - - - - -
  120.  
  121. The Left Mouse Button and Clipping:
  122.  
  123. The mouse can be used to clip text from the window. To clip some text, first
  124. get the text in view by scrolling the window vertically. Then place the mouse
  125. pointer on one end if the block of characters you wish to clip. Then hold
  126. down the lmb while moving to the other end of the block, and release the lmb.
  127. The text is then clipped to whatever the current clipping mode specifies (the
  128. input buffer, the clipboard (unit 0)or a file)
  129. NOTE: if you are clipping a TAB (perhaps along with other characters) the
  130. block of text will jump from the TAB to the next character as you move the
  131. mouse, since the TAB is really occupying all those spaces.
  132. NOTE: if you have configured the SPHINX not to strip the EOL characters, if
  133. you move the mouse out beyond the end of a line, if there is an invisible
  134. character there (like CR, LF or FF), then it will be clipped too. With an
  135. ordinary font, this will show up as a sort of box at the end of the clipped
  136. text. If you dont want it, just BackSpace and be more carefully next time you
  137. clip: dont go far beyond the end of the line, or, more permanently, change
  138. configuration to that these are automatically stripped out.
  139.  
  140. A word, as defined by the ExtraClipWordChars, or one character that is not in
  141. the set of ExtraClipWordChars, can be clipped by double-clicking either on
  142. one character of the word, or on the one non-word character. The edges of the
  143. word are defined by the first characters which do not belong to the set of
  144. characters (A-Z + a-z + ExtraClipWordChars), or the first change in format
  145. (italics, color,...) or a change from an inputed text to written text.
  146.  
  147. Text cannot be clipped solely from the input buffer. Instead, when a
  148. character in the input buffer is clicked on, the cursor is moved to that
  149. character. It is possible, and perfectly legal, to start clipping to the left
  150. of the input buffer, and have the block extend into the input buffer; the
  151. block just can't start in the input buffer.
  152.  
  153. Clicking to the right of the last input buffer character jumps the cursor to
  154. the end of the input buffer.
  155.  
  156. Clicking below the last line of the input buffer does nothing (except maybe
  157. activate the window).
  158.  
  159. RA-G
  160. If we are not in a locked clipping mode, this cycles through the one-line
  161. clipping modes (private->clipboard->file-<). The undo gadget's imagery
  162. changes to show the current mode (`X'->`C'->`F'-<). The clipping mode
  163. selected is canceled after a clip has been performed.
  164. If we are in a locked clipping mode, this cancels that mode, putting you
  165. back into private clipping.
  166.  
  167. SRA-G
  168. If we are not in a locked clipping mode that has been used (something has
  169. been clipped using this mode), then this cycles through the locked clipping
  170. modes (private->locked clipboard->locked file-<) and the undo gadget's
  171. imagery shows which mode is currently selected (`X'->script `C'->script `F').
  172. If we are in a locked clipping mode which has been used, then this cancels
  173. that mode, putting us back into private clipping.
  174.  
  175.             - - - - - - - - - - - - - - - - - -
  176.  
  177. Inserting:
  178.  
  179. RA-I:
  180. This inserts whatever text is in the clipboard (unit 0). If input parsing is
  181. enabled, then the characters are treated as if they had been typed in, if
  182. not then they are inserted at the cursor as if Literal were enabled.
  183. (looks down inside all CATs,LISTs and FORMs, and inserts the contents of
  184. all CHRS hunks it finds inside FTXT forms)
  185.  
  186. SRA-I:
  187. This inserts the contents of the file InsertFile using the current parsing
  188. mode (or saves this information so that the insertion may be done when the
  189. previous file insertion(s) are completed, if there are already some going
  190. on).
  191. This insertion is done without blocking up the SPHINX window-everything
  192. still works while the insertion is taking place. In fact, the insertion
  193. looks like you were typing the text in, except that the inserted text never
  194. gets mixed up with any inputlines you may be typing.
  195. The file is treated as a plain ascii file.
  196.  
  197. RA-P:
  198. Toggles whether inserted text (from private clip, clipboard or insert file)
  199. is just inserted at the cursor, or is parsed just as if it had been typed in.
  200. This means that by inserting from a file and parsing that insert you now
  201. have a primitive (no conditions or loops,...) macro facility within SPHINX:
  202. just have the insert file contain the input lines as you would type them.
  203. NOTE: there is one difference between keyboard stroke parsing and insert
  204. parsing, in an insert, both CR and LF end the input buffer and make it
  205. available, while in keyboard parsing LF just end the input buffer, but does
  206. not make it available.
  207.  
  208. RA-A:
  209. Inserts again the last clipboard or private insertion as if you had just
  210. hit RA-I or clipped the text, even if the text is now gone (private text
  211. was freed, or clipboard file is changed)
  212. NOTE: does not work with file insertions
  213.  
  214.             - - - - - - - - - - - - - - - - - -
  215.  
  216. Vertical Movement keystrokes:
  217. (see also scroll gadget)
  218.  
  219. SA-UP (shift-alt-UP):
  220. This scrolls back to the next previous beginning of an input line. This is a
  221. very usefull keystroke; when you have a short window and have just typed a
  222. command that returned more text that fitted in the window, pressing SA-UP
  223. will jump you back to the first text returned by that command. Then you can
  224. scroll slowly down the text with C-DOWN or A-DOWN.
  225.  
  226. S-DOWN:
  227. If we are searching and the cursor is visible, then cancels the search and
  228. restores the input buffer.
  229. If the cursor is not in sight, this scrolls just enough to bring it into
  230. sight.
  231. If the cursor is already in sight, this scrolls the cursor to the top line of
  232. the window.
  233.  
  234. A-UP & A-DOWN:
  235. Scrolls the window up or down by half the height of the window unless the
  236. first or last bit of text would be reached, in which case the scroll goes
  237. only as far as possible. The number of lines to scroll is determined by the
  238. number of lines visible divided by two, rounded up. This way a one line
  239. window can still be scrolled.
  240.  
  241. C-UP & C-DOWN:
  242. Scrolls the window up or down by one line, unless the first or last bit of
  243. text has been reached.
  244.  
  245. SC-S: (Shift-Control-S)
  246. Disables the automatic scrolling. Now when the window would ordinarily have
  247. scrolled because text drawn to it had reached the bottom of the window, the
  248. window will not scroll (and the text will just be "drawn" below what is
  249. visible in the window; just down arrow to see it when you are ready).
  250. This is very usefull when you have a program which is writing a lot of lines
  251. to the window (say, a directory) and you are reading what is at the top of the
  252. window but the cursor is about to reach the bottom of the window, and so the
  253. window would scroll. By quickly presing SC-S you keep the window from
  254. scrolling, and therefore your reading from being interrupted.
  255. This is canceled by editing the input line in any way (typing a text key,
  256. inserting or searching), S-DOWN or C-G; RETURN,ENTER,C-J, C-M and C-\ to not
  257. cancel the auto-scrolling disablement, so you may enter a line of text, press
  258. SC-S, and then RETURN.
  259.  
  260. C-S:
  261. The first time, it stops output to the window, the next it allows it. When
  262. output is not allowed you may still edit and enter input lines.
  263. This is most usefull when the non-blocking type ahead is enabled and you
  264. want to see what you are entering w/o having it jump around ahead of the
  265. text being outputed.
  266.  
  267. C-Q & C-G:
  268. Manually cancels the auto-scroll disable put in place by SC-S, and the output
  269. stop put in place by C-S.
  270.  
  271.  
  272.             - - - - - - - - - - - - - - - - - -
  273.  
  274. Spots and Jumping:
  275.  
  276. F1 to F10:
  277. These jump the window to a predefined spot. You may program ten of these
  278. spots.
  279. When blocks of text are freed, any spots that specified a character in those
  280. blocks are cleared. The exception is the F10 spot.
  281. When the jump is done, the character the spot specifies is put in the topmost
  282. line of the window. (similar to what goes on when the window is resized)
  283.  
  284.  
  285. S-F1 to S-F9:
  286. Defines the specified spot by saving the current upper left character.
  287.  
  288. S-F10:
  289. Defines the F10 spot by saving the current upper left character. In addition,
  290. the whole time the F10 spot is defined, a small 10 appears in the lower right
  291. corner of the undo gadget. The F10 spot operates like the F1 through F9 spots
  292. with one addition: the automatic and (S)RA-F memory freeing is not allowed to
  293. free text at or below the character specified by the spot. This way if there
  294. is some text you would like to keep from being freed automatically, you can
  295. lock it down by placing the F10 spot at the beginning of that text. (In addi-
  296. tion, you can jump back to that text by pressing F10).
  297.  
  298. A-F10:
  299. Since the F10 spot is not cleared automatically by the memory being freed,
  300. and if it is not freed, will cause memory to no longer be freed, A-F10 is
  301. used to free the F10 spot. When the F10 spot is freed, the small 10 in the
  302. lower right corner of the undo gadget disappears.
  303.  
  304.             - - - - - - - - - - - - - - - - - -
  305.  
  306. Editing keystrokes:
  307.  
  308. RETURN, ENTER and C-M (ascii $0d):
  309. This ends inputing. The current input line is copied elsewhere, input buffer
  310. is cleared, the undo buffer is cleared, etc..., and makes the input available
  311. to the program reading from SPHINX (Read()). It appends a LF to the end of
  312. the current input line.
  313.  
  314. C-\ (ascii $1c):
  315. This ends the input line, resets the buffer, etc... just like RETURN, but
  316. does not append a LF. Then, if the line is not empty, the next read returns a
  317. zero length read. This way it simulates the EOF (End Of File) of a file
  318. system file.
  319.  
  320. C-J (ascii $0a):
  321. This ends the current input line only, not making it available for input. It
  322. will be made available when, at the end of some later input line, RETURN or
  323. C-/ is pressed.
  324.  
  325. C-Fn:
  326. If the string correspond to this key (specified in the configuration file)
  327. is not empty, then that string is inserted at the cursor, as if it had been
  328. typed in, and then the line is entered, as if RETURN had been pressed.
  329. If there is not enough room in the input buffer for the string, nothing
  330. happens.
  331.  
  332. BACKSPACE, C-H:
  333. Deletes the character the left of the cursor, if one exists, moving the tail
  334. of characters and the cursor to the left to fill the gap.
  335.  
  336. DELETE
  337. Deletes the character to the right (or under, if a block or underline cursor
  338. is being used). Again the tail is scrolled in order to fill the gap.
  339.  
  340. S-BS/C-U:
  341. Deletes all characters to the left of the cursor.
  342.  
  343. S-DEL/C-K:
  344. Deletes all characters to the right (or under and to the right) of the
  345. cursor.
  346.  
  347. C-X:
  348. Deletes everything in the input buffer.
  349.  
  350. A-BS:
  351. Deletes the word (or part of word) to the left of the cursor, as defined by
  352. the configuration delete word characters, or, if there is no word there,
  353. deletes one character to the left. Does not delete anything to the right of
  354. the cursor.
  355.  
  356. A-DEL:
  357. Deletes the word (or part of word) to the right of the cursor, or, if there
  358. is no word there, deletes one character to the right. Does not delete
  359. anything to the left of the cursor.
  360.  
  361. RIGHT ARROW:
  362. Moves the cursor one character to the right.
  363.  
  364. LEFT ARROW:
  365. Moves the cursor one character to the left.
  366.  
  367. A-RIGHT/C-RIGHT:
  368. Moves the cursor to the right until the start of a word is found, as defined
  369. by the configuration move word characters, or to the end of the input buffer,
  370. which ever comes first.
  371.  
  372. A-LEFT/C-LEFT:
  373. Moves the cursor to the left until the start of a word is found, etc...
  374. similarly to A-RIGHT.
  375.  
  376. S-RIGHT/C-Z:
  377. Moves the cursor to the end of the input buffer.
  378.  
  379. S-LEFT/C-A:
  380. Moves the cursor to the beginning of the input buffer.
  381.  
  382. C-W:
  383. Moves the cursor to the right to the next "tab stop" (included really for
  384. NEWCON compatability).
  385.  
  386. RA-L:
  387. See also Undo Gadget
  388. This toggles the literal trigger. When the trigger is loaded, the undo
  389. gadget's imagery shows an `L', and the next keystroke will be entered
  390. directly into the input buffer, not interpreted (unless it is an RA-key).
  391. This way, for example, a Ctrl-X ($18) can be put in the input buffer, instead
  392. of having it clear the buffer. The literal trigger is unloaded after one
  393. keystroke has been entered.
  394.  
  395. SRA-L:
  396. This does the same thing as RA-L except that when the literal trigger is
  397. loaded with this keystroke, it is locked: it is not canceled until SRA-L,
  398. RA-L or UNDO is pressed, instead of being automatically canceled after one
  399. keystroke has been entered. The undo gadget shows a script `L'.
  400.  
  401.             - - - - - - - - - - - - - - - - - -
  402.  
  403. Searching keystrokes:
  404.  
  405. Searching and Search mode are synonymous. They refer to the state in which
  406. the UNDO GG's picture shows an `S', and the input buffer shows old input. It
  407. is exited by editing the input line, DOWN ARROWING to the input buffer, or
  408. SHIFT-DOWN, or UNDO GG/RA-X. When searching, only the newest copy of
  409. identical input lines is shown to you.
  410.  
  411. UP ARROW:
  412. Look at the next higher input line, if one exists.
  413.  
  414. DOWN ARROW:
  415. Look at the next lower input line, or, if the input buffer has been reached,
  416. cancel the searching mode and restore the input buffer.
  417.  
  418. SHIFT-DOWN/C-B:
  419. When searching, if the cursor is visible, cancels the search and restores the
  420. input buffer, like in NEWCON. (see also this key under Vertical Movement)
  421.  
  422. UNDO GG/RA-X:
  423. When searching, cancels the search and restores the input buffer.
  424.  
  425. S-UP/C-R
  426. This, like in NEWCON, searches back in old input lines. However it is (in my
  427. biased opinion) a MUCH better implementation of this function.
  428. First, if we are not searching yet, the input buffer is copied into the
  429. search buffer. This solves one problem with NEWCON's search, in which you
  430. have to edit the input line to search back to the second matching line.
  431. Then I look back in the next older input lines from that which the input
  432. buffer shows now (so if we have just begun searching, we start with the first
  433. input line), looking for a line which matches the search line.
  434. Different sorts of comparisons are done depending on what the search line
  435. consists of:
  436. First, if all the alphabetic characters (A-Z) in the search line are uppercase
  437. then all comparisons are done on a case insensitive basis, instead of on a
  438. case sensitive basis.
  439. 1) If the search line contains any of the wildcard characters, which are
  440.    *#?(|){}^[], and the arp.library is avialable (and PreParse() says that
  441.    the search line is a wildcard pattern) then only a wildcard comparison
  442.    is tried, and if it is successfull then I stop.
  443. then
  444. 2) If the first characters of the line are exactly those in the search line
  445.    then I stop (NEWCON style search)
  446. and
  447. 3) If there are more than MaxLiteralCmpChars in the search line, then if
  448.    the line passes the fragment comparison then I stop.
  449.  
  450. If no lines are found which match, then the display does not change.
  451.  
  452. Thus if MaxLiteralCmpChars was 3 and we had the two old input lines:
  453.  Dir INC:intuition/
  454.  dir inc:Intuition/
  455. then a search line of
  456.  DIR
  457. would produce a case insensative NEWCON style comparison, and both old input
  458. lines would match, while
  459.  Dir
  460. would be considered case sensative, and only the first old input line would
  461. match.
  462.  dirintui
  463. ,since it has more then 3 characters, also produce a fragment comparison, and
  464. the second line would match (dir inc:Intuition/)
  465.                  dir in    tui
  466.  DIR#?INTUITION
  467. would cause case insensitive NEWCON style comparisons, fragment comparisons
  468. and (if arp.library is available) wildcard comparisons to be tried, and the
  469. case insensitive wildcard comparisons would say that both old lines match.
  470.  
  471.  
  472. The easiest way to describe the fragment comparision is to describe what it
  473. looks for: it looks for fragments of the search line in the line being
  474. tested. These fragments may be as small as one character, and must appear in
  475. the same order in the line being compared as in the search line. This
  476. allows you to type in fragments of the line(s) you seek, and then look back
  477. at those which match by repeatedly pressing S-UP. example:
  478. If you have these three old input lines:
  479.  dir intuition/
  480.  run v include/intuition/intuition.i
  481.  dirintuition/
  482. and you typed
  483.  dirintui
  484. and then pressed S-UP, the third line will be returned, since its first 8
  485. characters match exactly with the search line. Another press of S-UP will
  486. return the first line, because the search line can be broken up into
  487. fragments that can be found, in the same order, in that line: `dir' and
  488. `intui'.
  489.  
  490. This gives you a sort of wildcard comparision without wildcards, since the
  491. search line is treated as having a `*' (or `#?' for the Amiga purists)
  492. between each of its characters.
  493.  
  494. NOTE: any characters are allowed in the search line.
  495.  
  496.             - - - - - - - - - - - - - - - - - -
  497.  
  498. Special keystrokes:
  499.  
  500. RA-F
  501. This frees the oldest block of saved text that can be freed. This overrides
  502. the MaxMemory and MaxBlocks, but no other conditions See
  503. MaximumKiloBytesOfWrite/InputToSave and MaximumNumberOfWrites/InputsToSave
  504. (section III).
  505. This is the only RA-key that repeats at all. Like all other keys, it does not
  506. repeat after it is released.
  507.  
  508. SRA-F
  509. This frees all the blocks of saved text that can be freed. Therefore this
  510. should be used when you wish to free some memory and you dont need what is
  511. going to be freed, like when you are switching to doing something else. This
  512. is equivalent to holding down RA-F until everything is freed.
  513. Use Spot 10 and/or the top line of the window to control just how much is
  514. freed.
  515.  
  516. RA-O:
  517. Opens the window to the full size of the screen, but does not change its
  518. depth arrangement, or, once it was been used and the window is still the
  519. full size of the screen, shrinks the window back down to its previous
  520. size.
  521.  
  522. RA-C:
  523. Opens the configuration window.
  524.  
  525.             - - - - - - - - - - - - - - - - - -
  526.  
  527.