home *** CD-ROM | disk | FTP | other *** search
/ Acorn User 1 / AU_CD1.iso / demos / a_to_i / dbedit / !DBEdit / DBEditHelp < prev    next >
Text File  |  1992-09-06  |  17KB  |  451 lines

  1.  
  2. ---------------- BDEdit Online help facility -----------------
  3.  
  4. Help is available on many topics for this editor. To allow
  5. easy navigation around this help file, you may build an index
  6. using the search string <--
  7.  
  8.  
  9. -- Active Index
  10.  
  11. Type in one or two search strings (such as DEF) to build an
  12. active index of all lines containing either or both of the
  13. search strings.
  14.  
  15. Clicking on any line within the index causes the equivalent
  16. line in the associated file to be scrolled on screen.
  17.  
  18. Due to speed constraints (the indexes must be rebuilt every
  19. time the primary program is renumbered), for BASIC files the
  20. search string is tokenised to allow direct matching against
  21. the source. For this reason, if you are indexing strings
  22. that include reserved words you must type the whole word or
  23. a valid shortform using the standard "dot" format (Eg P. for
  24. PRINT).
  25.  
  26. All of the search options shown in the "Options" box off
  27. the "Search" menu may be used to enhance the capabilities of
  28. the function.
  29.  
  30.  
  31. -- Copy Sequence
  32.  
  33. The copy sequence available from the Archimedes command line
  34. and ArmBE is also available in this editor.
  35.  
  36. Press Copy or Ctrl Copy (depending on the setting within the
  37. profile) to invoke the function and the caret will split into
  38. two, with the copy caret in a different colour to show the
  39. new mode.
  40. The Copy key now copies the character from the right of the
  41. copy caret to the right of the line caret. The arrow keys move
  42. the copy caret, and it may also be set into a new window via
  43. clicking with the mouse or using Ctrl F2. The Delete key
  44. deletes the character to the left of the line caret. Copy
  45. sequence mode is ended if the Escape or Enter key is pressed.
  46.  
  47. While in Copy mode, Shift copy copies the current word (or
  48. string if the caret is immediately to the left of a double
  49. quote), and Ctrl Copy copies all text to the end of the line.
  50.  
  51.  
  52. -- CSD
  53.  
  54. The currently selected directory (CSD) may be set in two ways.
  55. The first is to open the menu on a window containing a file
  56. from the required directory and choose the "Set CSD" option
  57. off the "Misc" submenu.
  58. The other is to drag any directory or application-directory
  59. icon onto the DBEdit icon on the bar or to any open DBEdit
  60. window.
  61.  
  62.  
  63. -- Error throwbacks
  64.  
  65. DBEdit supports a facility whereby errors in any running
  66. BASIC program can be captured and displayed. The errors can
  67. occur in multi-tasking or single-tasking programs.
  68.  
  69. To invoke this facility all that has to be done is to have a
  70. copy of the program loaded into the editor. It can then be
  71. run with Ctrl R or with a double click on its filer entry.
  72.  
  73. Any errors that occur in the program will be displayed by the
  74. Wimp as normal, then an Error index will be shown with the
  75. new error.
  76. This index works like normal indexes in that clicking on the
  77. line displays the applicable program line.
  78.  
  79.  
  80. -- Find and Replace
  81.  
  82. There is space for four Find strings which allows multiple
  83. search strings to be retained and reused.
  84. The fourth text will only be found within the current
  85. selection if there is one, and doubles as the search string
  86. to be replaced by the Replace function.
  87. While the caret is on an edit window, all the combinations of
  88. shifted and ctrl'ed F7 and F8 may be used.
  89.  
  90. All of the search options shown in the "Options" box off
  91. the "Search" menu may be used to enhance the capabilites of
  92. the function.
  93.  
  94. Use Ctrl B to return to where the Find was initiated.
  95.  
  96.  
  97. -- Incremental search
  98.  
  99. Incremental search is a simple way of driving the first line
  100. of the Find box, with one major enhancement. Instead of typing
  101. in a whole word then clicking go, simply press F8 (to search
  102. forwards) or F7 (to search back) then start typing the search
  103. string.
  104. DBEdit will immediately start looking for the required string
  105. based on what has been typed so far. As soon as the screen
  106. shows the line wanted, just press escape to return to editing
  107. mode.
  108. As with Copy mode, the caret changes colour to indicate the
  109. current mode of operation.
  110.  
  111. If you accidently type a wrong character, press delete to
  112. remove it from the string typed so far.
  113.  
  114. The Find box echos the characters as you type.
  115.  
  116. Use Ctrl B to return to where the incremental search was
  117. initiated.
  118.  
  119.  
  120. -- Indenting
  121.  
  122. Automatic indenting may be turned on via the Profile box of
  123. the icon bar menu. This lines up new lines and split lines
  124. under the previously typed line.
  125.  
  126. To indent a BASIC selection or program LISTO 7 style, choose
  127. the menu option "Indent" off the "Modify" menu, or press
  128. Ctrl N. If there is a selection, then the lines of the
  129. selection will be reindented based on the first non blank,
  130. non REMed line of the selection.
  131. If there is no selection on this file, the whole program will
  132. be reindented.
  133.  
  134. To suit different programmer indentation styles you may
  135. set zero to nine spaces per indent via the "Profile" box.
  136. This indent distance is also used when TAB or Shift TAB is
  137. pressed if the profile is set appropriately.
  138.  
  139.  
  140. -- Keyboard Commands
  141.  
  142. Arrow keys
  143.  
  144.   ⇦ ⇨ ⇩ ⇧ : Move the caret one character position.
  145. Shift ⇦ ⇨ : Move the caret three positions sideways.
  146. Shift ⇩ ⇧ : Move the caret and scroll the window one page.
  147. Ctrl  ⇦ ⇨ : Move the caret to the end of the line.
  148. Ctrl  ⇩ ⇧ : Move the caret to the end of the file.
  149.  
  150. Control keys
  151.  
  152. Ctrl 1 : Find First using One Key search string 1
  153. Ctrl 2 : Find First using One Key search string 2
  154. Ctrl 3 : Find First using One Key search string 3
  155. Ctrl 4 : Find First using One Key search string 4
  156. Ctrl A : Set the selection to include the caret line.
  157. Ctrl B : Go back to where the last find was initiated
  158. Ctrl C : Copy the selection directly after the caret line.
  159. Ctrl F : Display the Find box.
  160. Ctrl G : Display the statistics box; into which a line
  161.          number can be typed to position the caret.
  162. Ctrl I : Toggle insert mode on and off.
  163. Ctrl J : Join the current line to the next separated by a
  164.          colon.
  165. Ctrl K : Toggle the setting of the "Keep Select" flag.
  166. Ctrl L : Locate a marker previously set by the Ctrl P command.
  167. Ctrl N : Indent the file or current selection.
  168. Ctrl O : Open the Undo box.
  169. Ctrl P : Mark the current position for the Ctrl L locate
  170.          command.
  171. Ctrl Q : Refresh the open indexes.
  172. Ctrl R : Save the program to WimpScrap and run it from there.
  173. Ctrl S : Swap the case of the character following the caret.
  174. Ctrl T : Toggle the input focus window between the back and
  175.          front of the desktop.
  176. Ctrl U : Clear the current line of text.
  177. Ctrl V : Move the current selection following the caret line.
  178. Ctrl W : Split the current view. If the caret is currently on
  179.          a line containing a PROCedure or FuNction call, the
  180.          new view will be positioned to the appropriate DEF
  181.          line.
  182. Ctrl X : Delete the current selection.
  183. Ctrl Z : Clear the current selection.
  184.  
  185. Function Keys
  186.  
  187.       F1 : Display this help document.
  188. Shift F1 : Join the current line to the next separated by a
  189.            colon.
  190. Ctrl  F1 : Split the current line at the caret. The split off
  191.            text will be indented to the same level as the
  192.            current line if Auto Indent is on.
  193. Ctrl  F2 : Step the caret onto the next open view of this file.
  194.       F3 : Pop up the "Save As:" box to save the whole file.
  195.       F4 : Pop up the Find box.
  196. Ctrl  F4 : Split the current view. If the caret is currently
  197.            on a line containing a PROCedure or FuNction call,
  198.            the new view will be positioned to the appropriate
  199.            DEF line.
  200.       F6 : Set the selection to include the caret line.
  201. Shift F6 : Select the current block of code or REMs
  202.       F7 : Initiate an incremental search backwards.
  203. Shift F7 : Find/Replace previous.
  204. Ctrl  F7 : Find first/Replace to the first.
  205.       F8 : Initiate an incremental search forwards.
  206. Shift F8 : Find/Replace next.
  207. Ctrl  F8 : Find last/Replace to the last.
  208.       F11: Delete from the caret to the end of the line.
  209. Shift F11: Delete from the start of the line to the caret.
  210. Ctrl  F11: Clear the current line of text.
  211.  
  212. Shift-Ctrl Fn (where Fn=Function key 0 to 11): Perform a macro.
  213.            Note - Function key 0 is the Print key.
  214.  
  215. Miscellaneous Keys
  216.  
  217. The Enter and Insert key actions may be reversed with a
  218. setting in the profile. In "Edit" mode:
  219. Enter    : Splits the current line at the caret.
  220. Insert   : Inserts a blank line following the caret line
  221.  
  222. The Copy and Ctrl Copy key actions may be reversed with a
  223. setting in the profile. In "Edit" mode:
  224. Copy     : Deletes the character to the right of the caret.
  225.            If the caret is after the last character in the
  226.            line, the following line is wrapped back.
  227. Ctrl Copy: Initiates a copy sequence - see that section for
  228.            more details.
  229.  
  230. Escape   : If no other condition applies (as mentioned
  231.            elsewhere in this document), Escape cancels all
  232.            changes to the current line (undo).
  233. Delete   : Deletes the character immediately to the left of
  234.            the caret. If the caret is in column 1, the current
  235.            line is wrapped back to the end of the previous one.
  236. Tab      : Move the caret to the next indent column or tab
  237.            stop depending on the profile setting.
  238.            If the caret precedes the text on the line, the
  239.            text is moved independently to its next tab stop.
  240. Shift Tab: Move the caret to the previous indent column or
  241.            tab stop.
  242.  
  243.  
  244. -- Macros
  245.  
  246. DBEdit supports keyboard macros via the use of the function
  247. keys as set by *SetMacro Key$n commands. DBEdit allows the
  248. editing of the macros from within the editor, but these
  249. macros are not saved across sessions.
  250.  
  251. It is a simple matter to include the relevant command in the
  252. !BOOT or !RUN file so the editor has permanent macros. Click
  253. on the "Copy" icon within the Set Macro box. This outputs (at
  254. the caret) the command required to set the macro up each
  255. session. The caret positioning characters are not supported
  256. by this function but these can be added afterwards.
  257.  
  258. Shift-Ctrl Print is macro 0, and Shift-Ctrl F1..11 are macros
  259. 1 through 11.
  260.  
  261. To add new macros, or modify the existing ones, open the
  262. "Macro" option of the Icon bar menu. Enter a macro number
  263. from 0 to 11 (or press the equivalent non-shifted function
  264. key) to load the current definition, then change as required.
  265. At any time, click on "Okay" to update the macro, "Play" to
  266. use the macro, or "Cancel" to restore the previous definition.
  267.  
  268.  
  269. -- Markers
  270.  
  271. Ctrl P can be used to set two markers within the file. Each
  272. time a marker is set, it replaces the marker not used last
  273. time.
  274.  
  275. Ctrl L is used to find the markers. Press once to go to the
  276. oldest marker, then press again to toggle to the other one.
  277. The toggle action continues until a new marker is set.
  278.  
  279.  
  280. -- One Key searches
  281.  
  282. One Key searches are a very neat way to find unique strings
  283. within the source. Using the "current word" wildcard allows
  284. a search string to be found that includes the word that the
  285. caret is on. One Key searches find the first occurence of the
  286. string within the file.
  287.  
  288. The two default search strings provided allow the finding of:
  289. 1. The PROCedure/FuNction definition called at the caret.
  290. 2. The assembly label as referenced by the word where the
  291.    caret is.
  292.  
  293. Note that the "current word" wildcard may only be used in
  294. One Key search strings. The wildcards available for the other
  295. find functions are also available to the One Key search
  296. strings.
  297.  
  298. Use Ctrl B to return to where the One Key search was
  299. initiated.
  300.  
  301.  
  302. -- Selections
  303.  
  304. The standard Wimp selection functions are available both from
  305. the menu and from the keyboard. Included is the ability to
  306. move or copy a selection from one window to another (even if
  307. the windows contain different files).
  308.  
  309. As this editor has been written primarily for BASIC, a line
  310. based interpreter, it allows selections on a line basis only.
  311. This makes for very fast selection of code to be moved or
  312. copied about.
  313.  
  314. The selection may be retained or released after a Copy or
  315. Move action depending on the setting of the "Keep Select"
  316. flag in the profile box.
  317. This flag may also be toggled by pressing Ctrl K.
  318.  
  319. One extra feature of the keyboard shortcuts, not normally
  320. available in Wimp editors is the use of F6 or Ctrl A to mark
  321. the current line, and if a selection already exists, it is
  322. extended, or reduced to encompass the current line. In effect,
  323. these keys mimic the action of the Adjust mouse button.
  324.  
  325. It is also possible to select whole blocks of code with one
  326. keystroke.
  327. Any BASIC construction is selected simply by putting the
  328. caret on the first line of the block and pressing Shift F6.
  329. The quick selections include all the standard blocks such as:
  330. IF...ELSE...ENDIF, REPEAT...UNTIL, DEF PROC...ENDPROC etc
  331.  
  332.  
  333. -- Undo
  334.  
  335. Undo is invoked from the "Misc" submenu or via Ctrl O. Each
  336. line change that occurs within DBEdit is saved within the Undo
  337. stack and can be independently restored. Whenever the Undo
  338. box is opened, the before image of the most recently changed
  339. line is shown, and the changed version is highlighted within
  340. the edit window. Click on Undo to put the before image back
  341. into the code. There is one undo stack per file.
  342.  
  343. As the Undo position is a line offset, there may be occasions
  344. when the caret is not correctly positioned to restore to
  345. the right line. Therefore, while the Undo box is displayed
  346. you may use any caret positioning keystrokes before restoring.
  347. Note that this also allows you to replace any file line with
  348. one from the undo buffer.
  349.  
  350. Next and Previous can be selected to cycle through the old
  351. versions of lines currently held in the Undo stack.
  352.  
  353.  
  354. -- Undelete
  355.  
  356. Undelete is also invoked from the "Misc" submenu. This
  357. function allows you to restore the most recently deleted
  358. selection. Upon choosing the option, an Undelete box will
  359. be displayed and the caret will be positioned to the line
  360. where DBEdit assumes you wish to restore to. Select Insert to
  361. restore the text, or Cancel to exit the Undelete function.
  362.  
  363. As the Undelete position is a line offset, the caret may not
  364. always be correctly positioned to restore to the right line.
  365. Therefore, while the Undelete box is displayed you may use
  366. any caret positioning keystrokes before restoring.
  367. This also allows you to do "cut and paste" editing.
  368.  
  369. The size of the "Undelete" buffer can be set via the system
  370. variable DBEditDel$Buff. Undelete is turned off if this
  371. variable has a value of zero.
  372.  
  373.  
  374. -- WildCards for Finds
  375.  
  376. DBEdit supports four wildcards which may be used in search
  377. strings and for the Index function. The actual character that
  378. represents the wildcard function may be set at any time (and
  379. saved permanently with the profile), but there are defaults
  380. as shown below.
  381.  
  382. [?] "Match any one character"
  383.  
  384. This wildcard may be used to match exactly one character
  385. within the file.
  386.  
  387. [*] "Match 0..many chars"
  388.  
  389. This wildcard matches any number of characters on the current
  390. line in the text. Its main use is to find two specific strings
  391. anywhere on the same line.
  392. The second use of this character is for including the "rest
  393. of the line" in a replace operation. Matching REM* will mean
  394. the replace wildcard |1 will contain the rest of the line.
  395. See that wildcard for further details.
  396.  
  397. [$] "Match 0..many spaces"
  398.  
  399. This wildcard allows fuzzy matching of sequential strings
  400. where no, one, or multiple spaces may separate the parts. To
  401. select matches with 1..many spaces, use " $".
  402.  
  403. [<] "Match start of line"
  404.  
  405. This wildcard makes it easy to test for strings at the start
  406. of the line.
  407. The wildcard must be the first character of the search string
  408. or it will be treated as a normal character (unlike the other
  409. wildcards).
  410.  
  411. You can use this wildcard with a replacement string of REM to
  412. prevent a selected block of code being actioned, and <REM
  413. replaced with nothing to remove the REMs again.
  414.  
  415.  
  416. -- Wildcards for One Key
  417.  
  418. One Key search strings may include any of those available for
  419. Finds, plus the following:
  420.  
  421. [&] "Current word"
  422.  
  423. This wildcard is replaced by the word containing the caret
  424. before the search commences.
  425.  
  426.  
  427. -- Wildcards for Replaces
  428.  
  429. There are two wildcards available for use within the replace
  430. string. These allow all or parts of the found string to be
  431. put back into the resultant line during the replace operation.
  432.  
  433. [&] "Found string"
  434.  
  435. Use this wildcard when you wish to append new characters to
  436. existing text. It represents the entire string within the
  437. current line that matched the search string (including text
  438. that matched any wildcards).
  439.  
  440. [|] "Ambiguous part (n)"
  441.  
  442. This wildcard gives the powerful ability to pick and choose
  443. parts of the found string. The ambiguous sections of the
  444. found string are all available (ie those that matched any of
  445. the Find wildcards ?, *, or $).
  446. Ambiguous sections 1 to 9 can be recovered.
  447.  
  448.  
  449. --------------------------   END   ---------------------------
  450.  
  451.