home *** CD-ROM | disk | FTP | other *** search
/ CP/M / CPM_CDROM.iso / jsage / zsus / z3help / z.lbr / ZDENSTAL.HZP / ZDENSTAL.HLP
Encoding:
Text File  |  1991-11-18  |  21.8 KB  |  424 lines

  1. ;
  2.  
  3.                     
  4.                                ZDENSTAL vs 1.0
  5.  
  6.                         Copyright 1989 Carson Wilson
  7.  
  8.                         A-   User Options           
  9.                         B-   Terminal Installation  
  10.                         C-   Printer Installation   
  11.                         D-   Macro Keys             
  12.                         E-   Restoring Defaults     
  13.                         F-   Patching               
  14. :a
  15.  
  16. User Options:
  17.  
  18. Create BAKup files (Y/N)   - Should  a backup file  be made when  you  edit an
  19.                              existing file?   Choose "Y" to play safe,  "N" to
  20.                              save disk space.
  21.  
  22. Default file mode (W/A/N)  - Which  of  the  three  file  modes  "W", "A", "N" 
  23.                              described in ZDE.DOC  do you want as the default?  
  24.                              (Originally "A".)
  25.  
  26. Auto mode select filetypes - You can  specify  two  filetypes (or masks, using 
  27.                              "?" as  a wildcard) to automatically  set  a file 
  28.                              mode other than  the default.   For example,  you 
  29.                              can declare  all  "ASM" files to be "N" mode,  or 
  30.                              all filetypes "?88" to  be "W",  by default.   If
  31.                              not  used,  fill with some illegal character like
  32.                              ".".
  33.  
  34.  
  35. Default insert on (Y/N)    - Do you want  the INSERT  toggle to  start  out ON 
  36.                              when first entering ZDE?  (Originally No.)
  37.  
  38. Default ruler on (Y/N)     - Do you want the Ruler line  (^OT) to start out ON
  39.                              when first entering ZDE?  (Originally No.)
  40.  
  41. Default HCR display on     - Do  you want  Hard CR  display (^OD) to start out
  42.    (Y/N)                     ON when  entering  a Document  file ("W/A" mode)?  
  43.                              Originally Yes.   (The  default is  always OFF in 
  44.                              "N" mode.)
  45.  
  46. Enable hyphenation (Y/N)   - Do you  want  hyphenation (^OH)  to  start out ON
  47.                              when first entering ZDE?  Originally Yes.
  48.  
  49. Left and Right margin      - Default margin  settings  for  "W/A" modes.   Set 
  50.  columns (1-255)             both  to  1  to  entirely  disable  wordwrap  and 
  51.                              reformatting.
  52.  
  53.  
  54. Scroll overlap (0-255)     - This is  the  number  of  lines  overlap  between 
  55.                              screens when scrolling  with ^R/^C.  The smaller, 
  56.                              the larger the scroll.   Keep  this  smaller than 
  57.                              your screen size!
  58.  
  59. Show system files (Y/N)    - Do you  want  files with the  SYStem attribute to 
  60.                              show in the ZDE directory display?
  61.  
  62. Fixed drives (A-P)         - This lets you specify that up to two CP/M logical
  63.                              drives are nonremovable media (hard or RAM disk),
  64.                              so ZDE won't reset them  before writing  to them, 
  65.                              speeding up some  systems.  Enter two drives from
  66.                              "A" to "P";  to  leave  either blank,  enter "@".  
  67.                              (The default is "@@",  or none; if you have a RAM
  68.                              drive C:, enter "C@".)   Caution: naming a floppy
  69.                              drive here can cause serious  BDOS errors on CP/M 
  70.                              2 systems.
  71.  
  72.  
  73. Ring bell on error (Y/N)   - Do you want your terminal bell to ring when a ZDE
  74.                              error message displays?
  75.  
  76. Enable help menus (Y/N)    - Do you want to  have the  help  menus (^J, ESC-H) 
  77.                              available?  Normally "Y".   If you change this to 
  78.                              "N",  you will have about 1K more free memory for 
  79.                              editing.
  80.  
  81. Alternate video in header  - Do you  want the header,  messages, etc to appear 
  82.    (Y/N)                     in a contrasting video mode (if installed)?
  83.  
  84. Suppress header by default - Do you want header  display  (^OQ)  to  start out 
  85.    (Y/N)                     off?  Normally "N", and the header is displayed.
  86.  
  87. Clock speed in MHz (01-FF) - Set this hex  value  to reflect  CPU clock speed; 
  88.                              most Z80 computers are 4.0 MHz (use 40 here).
  89.  
  90.  
  91. Horizontal scroll delay    - This value affects  the  delay  between scrolling 
  92.    (01-FF)                   the current line and the rest of the screen, when 
  93.                              working  beyond  the right screen edge.   Average 
  94.                              value is 80; adjust up or down as you like.
  95.  
  96. Hard Tab display spacing   - This determines how  any actual Tabs (^I) in your 
  97.                              text will display.   Usually 8,  this can be made 
  98.                              2, 4, 16,  or  any  other  power  of two.   Other 
  99.                              values will produce erratic results.
  100.  
  101. Variable tab stops         - Enter  a  list  of  up  to  8 variable  tab  stop 
  102.                              columns, in  ascending order.   (Column 1  is the 
  103.                              leftmost.)    Fill   unused  values   with  zero.  
  104.                              Originally 6, 11, 16, 21.
  105.  
  106.  
  107.    Next you will  be  asked  whether you  want  to continue to  MODIFY DEFAULT 
  108. CHARACTERS? (Y/N)   Ordinarily you will NOT; however,  if a default assignment 
  109. in ZDE conflicts with some  special application,  you can change these values.  
  110. When entering  control codes (00-1F),  avoid standard ASCII values ^H, ^I, ^J, 
  111. ^L, ^M, ^Z (ASCII 08, 09, 0A, 0C, 0D, 1A).
  112.  
  113. Wildcard character         - Normally ^Z (1A), this is the character that will
  114.                              be used as a wildcard in FIND strings.  Change if 
  115.                              you wish.
  116.  
  117. Block mark character       - Normally ^@ (00),  but if you  need to imbed that 
  118.    (00-1F)                   code in your files for  any reason you can change 
  119.                              this.
  120.  
  121. Print toggles (00-1F)      - These are the  codes  that will  call up the four 
  122.                              toggles defined  in  your  Printer  installation.  
  123.                              Normally ^B,  ^D,  ^S,  ^Y,  corresponding  to WS
  124.                              bold, doublestrike, underline, and ribbon/italic.
  125.  
  126.  
  127.  
  128. Print switches (00-1F)     - These are the  codes  that  will call up the four 
  129.                              switches defined  in  your Printer  installation.  
  130.                              Normally ^Q, ^W, ^E, ^R.
  131. :b
  132.  
  133. Terminal Installation:
  134.  
  135. Terminal ID                - Identify the terminal  you  are  installing.  (16 
  136.                              characters)
  137.  
  138. Viewable screen columns    - Enter the width of  your screen in columns.   The 
  139.    (40-255)                  normal value is 80 for a standard screen.
  140.  
  141. Screen lines (4-255)       - Enter  the  number   of  lines  on  your  screen.  
  142.                              Normally 24 for  a  standard screen.   Must be at 
  143.                              least 4.
  144.  
  145. DELete character (00-7F)   - ZDE always accepts DEL (7F) as  a delete key.  If
  146.                              your keyboard can't generate this you can install
  147.                              an alternate value here (example:  1F  enables ^_
  148.                              on an Osborne 1).   Also, if you prefer to have a 
  149.                              destructive (deleting) Backspace, you can install
  150.                              ^H (08) here.   Otherwise you  can  leave this at 
  151.                              the default value, FF for "not used".
  152.  
  153.  
  154. Arrows up, down, right,    - ZDE always  accepts  Wordstar  arrows ^E, ^X, ^D, 
  155.    left (00-7F)              ^S,  as  well  as  ^H  (backspace)  and  ANSI ESC 
  156.                              sequences.   If your terminal has arrow keys that 
  157.                              generate different values,  you  can install them 
  158.                              as alternates here.  Omit high (parity) bits; ZDE
  159.                              strips  these.   Use  "FF"  for  "not used".   By 
  160.                              default, no alternative  arrow  keys are defined.  
  161.                              To install CP/M ^K, ^J, ^L, as arrow keys,  enter 
  162.                              0B0A0CFF.     (Don't  install  ^H   here.)     If 
  163.                              specified, these keys will no longer function as
  164.                              Wordstar synonyms.
  165.  
  166. Terminal init, deinit      - Enter the codes  you want sent to initialize your 
  167.                              screen on entry into ZDE,  and to deinitialize on
  168.                              exit,  in the form (# of bytes),bytes.   Example: 
  169.                              ^Z is (01)1A.   Minimally,  both  sets  of  codes 
  170.                              should clear the screen.
  171.  
  172.  
  173. Autowrap at line end (Y/N) - Usually Yes,  as most terminals wrap  down to the 
  174.                              next line  when  a  character is  printed  at the 
  175.                              right  edge  of the screen.   If  yours  discards 
  176.                              characters instead, set this to No.
  177.  
  178. Clear to end of line       - Enter the codes  to  clear  to  end  of line,  as
  179.                              (#),bytes.  Example: ESC-T is (02)1B54.   If your
  180.                              terminal can't do this then zero it out (00).
  181.  
  182. Alternate video on/off     - Enter the codes (#),  bytes to turn your favorite
  183.                              video   attribute   (e.g.,   reverse,   dim,   or 
  184.                              underline) on  and off.   This will  be  used for 
  185.                              control  codes  and (optionally) the  header  and 
  186.                              messages.   If your terminal  has  no attributes, 
  187.                              zero these out (00).
  188.  
  189. Use high bit for alt.      - If your terminal needs  the high bit set on chars
  190.     video (Y/N)              to put them  in  alternate video,  zero the above 
  191.                              strings out and say Yes here; otherwise, No.
  192.  
  193.  
  194. Console filter (7D-FF)     - This is the highest ASCII  code that will be sent
  195.                              to  the screen.   Normally 7F;  if  your terminal 
  196.                              can't display codes  7F or  7E  (DEL  and tilde), 
  197.                              lower this to 7E or 7D.   Characters filtered out
  198.                              will display as a "?".
  199.  
  200. Cursor positioning mode    - This tells ZDE how  your terminal  can be made to 
  201.    (S/R/A/N)                 put the  cursor  at any  given  row/column on the 
  202.                              screen:
  203.                              "S"tandard = leadin byte(s), row byte, column 
  204.                                           byte (default).
  205.                              "R"eversed = leadin byte(s), column byte, row 
  206.                                           byte.
  207.                              "A"NSI std = ANSI standard sequences 
  208.                                           "ESC[rr;ccH".
  209.                              "N"one     = no absolute cursor addressing 
  210.                                           supported.
  211.  
  212.  
  213. Cursor positioning         - This is  the actual sequence  used to address the 
  214.    sequence                  cursor.   IF YOU CHOSE "A"  mode  above,  you can 
  215.                              skip  this entirely.   IF YOU CHOSE  "S" or  "R", 
  216.                              then enter the 4-byte sequence for addressing the
  217.                              cursor to the top left:  two lead bytes, then two
  218.                              row/column   offsets.     Most   terminals    use 
  219.                              ESC,=,20h+row,20h+col, or 1B3D2020.   If you have 
  220.                              only one lead byte, enter 00 for the second.   IF 
  221.                              YOU CHOSE "N",  then you  must  enter  two 2-byte 
  222.                              sequences instead: first one  to home the cursor, 
  223.                              then one to move it right.  If either is only one 
  224.                              byte, enter 00 for the second.   Typical  values:
  225.                              home=1Eh, right=0Ch, which would make 1E000C00.
  226.  
  227. Delay after cursor         - Normally 00.  Some slow terminals require a delay
  228.    positioning (00-FF)       here to accomplish  cursor movement;  adjust this 
  229.                              value upwards as necessary.  
  230.  
  231.  
  232. Insert, Delete line        - Sequences that will cause the current cursor line
  233.                              to be deleted,  or  a  new  line  inserted there.  
  234.                              Most  terminals  can  do  this.  Example:  on  an 
  235.                              ADM3-style terminal,  ESC-E or (02)1B45 inserts a 
  236.                              line  before  the  current one,  while  ESC-R  or 
  237.                              (02)1B52 deletes  a line.   For  a few terminals, 
  238.                              you have to specify which line is to be inserted/
  239.                              deleted; in this case,  enter  the  sequences for 
  240.                              line  1  (the  second  screen  line).    If  your 
  241.                              terminal can't do this  at  all,  zero  these out 
  242.                              (00).
  243.  
  244. Ins/del specific to line 1 - Usually No;  set  to  Yes  only  if  the  ins/del 
  245.                              sequences you  installed  above  are  for  line 1 
  246.                              only, rather than general.
  247.  
  248. [NOTE: the installation of arrow keys affects ZDE's command behavior.   If the 
  249. keys ^J, ^K, or ^L are in use as arrow keys,  as in many of the CP/M defaults, 
  250. they will not function as Wordstar synonyms.]
  251. :c
  252.  
  253. Printer Installation:
  254.  
  255. Printer ID                 - Identify the printer you are installing.  (16 
  256.                              characters)
  257.  
  258. Send LF after CR (Y/N)     - Normally Yes.  But with some printers, which 
  259.                              manufacture their own LF on receiving a CR, you 
  260.                              will want No here.
  261.  
  262. Page length (0-255)        - Set the number of text lines to print on a page.
  263.                              (Does not include the top margin or 3 extra lines
  264.                              for a header, if used.)  Setting to 0 disables 
  265.                              pagination entirely.
  266.  
  267. Top margin (0-255)         - Set the number of blank lines, if any, to skip at
  268.                              the top of each page when printing.  (Originally 
  269.                              0, none.)
  270.  
  271.  
  272.  
  273. Left margin (0-255)        - Set the number of blank columns to skip at the 
  274.                              left of each line when printing.  (Originally 0.)
  275.  
  276. Printer initialization     - Enter an optional string of code (#),bytes to 
  277.                              send to the printer before each print job, to set
  278.                              margins, print modes etc.
  279.  
  280. Printer deinit             - Enter another optional string (#),bytes to send 
  281.                              to the printer after each print job, to restore 
  282.                              printer to desired state on exit.
  283.  
  284.  
  285.  
  286. Codes for toggles          - Enter the actual hex codes (#),bytes to send to
  287.                              the printer on encountering each of the four 
  288.                              toggle codes, first to turn a feature on, then 
  289.                              off.  The WordStar conventions are:
  290.  
  291.                              ^B  boldface             ^S  underline
  292.                              ^D  doublestrike         ^Y  ribbon/italic
  293.  
  294.                              but you can use these however you like.
  295.  
  296. Codes for switches         - Enter the actual hex codes (#),bytes to send to
  297.                              the printer on encountering each of the four 
  298.                              switches.  These have no pre-established meaning.
  299.  
  300. [NOTE: The default printer installation is  a basic Teletype (no special codes 
  301. enabled); ZDE assumes only that the printer responds normally to Backspace (if
  302. ^P-H is used), Linefeed, and Formfeed.   You will probably want  to redo this, 
  303. so you will have access to your printer's special features.]
  304. :d
  305.  
  306.  
  307. Macro Keys:
  308.  
  309.    The default macro definitions are  those  attached to the commands ESC-0..9 
  310. when ZDE is first entered.   By changing them you  can configure  ZDE  to suit 
  311. your own specialized writing requirements.  (Any Keys defined with ESC-# while
  312. running ZDE override the defaults.)
  313.  
  314.  
  315.  
  316.    ZDENSTAL gives you a display much like this:
  317.  
  318. MACRO KEYS:  (01C6 bytes free)  <---- note free bytes (500)
  319. <0><>
  320. <1><>                           <---- "<>" flag means empty
  321. <2><>
  322. <3>^[;^C                        <---- normal macro key
  323. <4><>
  324. <5><N>World Wide Widgets Inc.   <---- "<N>" flag means no-rpt key
  325. <6><>
  326. <7><Q>^QR^[B^QC^[T^[C           <---- "<Q>" flag means quiet key
  327. <8><>
  328. <9><>
  329.  
  330.    This is pretty straightforward; you just  select  the number of the Key you 
  331. wish to redefine,  then type in the new definition,  much as you would in ZDE.  
  332. All the same rules apply  (but ZDENSTAL will  accept longer  keys,  up  to 128 
  333. bytes).  If the new definition is too long to fit it will be rejected.
  334. :e
  335.  
  336.  
  337. Restore Defaults:
  338.  
  339.      This option is provided in  the event  that someone has so mucked up your 
  340. copy of ZDE that you can't sort out what's wrong.   This should return  ZDE to 
  341. nearly the  state it  was  distributed in:  all User Options restored to their 
  342. defaults, Terminal Installation set to Generic (or Osborne Exec),  printer set 
  343. to a basic Teletype, no Macro Keys, no User Patch code.
  344. :f
  345.  
  346.  
  347. Patching:  User Patch Area
  348.  
  349.    Entry to ZDE is  via  a JP instruction  at 0100h.   The  current  value  is 
  350. JP 0490h.   Thus, to add a user entry routine,  you can instead JP to your own 
  351. code in the User Patch area,  and finish it  with JP 0490h.   Exit from ZDE is 
  352. via a JP instruction at 010Bh, normally JP 0000h.  To add a user exit routine,
  353. you can instead JP to code in the  Patch  area,  ending  it  with  a warm boot 
  354. (RST 0).
  355.  
  356.    The address of the User Patch area will be given to you by ZDENSTAL.   This
  357. small region in ZDE  can  be  used  to install any  extra patch code you need.
  358. (Example:  if your video in/out routines won't fit into 16 bytes, you can jump
  359. to the User Patch area and  put more  code there.)  This is the ONLY such area 
  360. available, as ZDE uses  all  available  memory  after its own code for editing 
  361. text.  Note: if you find the User Patch area too small, you can also use up to
  362. 32 extra bytes before it.   This is  the Print Switch code area; you must then 
  363. avoid using the four Switch codes.
  364.  
  365.  
  366.    ZDENSTAL also tells you the addresses of the command tables in ZDE/M.   You 
  367. may find this useful if  you need to go in and  change  a ZDE command key that 
  368. conflicts with  your computer's  firmware.   There  are  four  command tables: 
  369. basic, ESC/^K, ^O, and ^Q.   Each is a list of 3-byte entries, with a one byte 
  370. keycode, then a two byte address.   (Examples: you will find the ^T command in 
  371. the basic table;  the ^OX command appears in  the ^O table, as ^X. )  Find the 
  372. problem keycode, and use DDT or another utility to change it.   (You will also 
  373. see the "keycodes" 00 and 80-84h in the tables;  these are used internally for 
  374. arrow keys and other functions.)
  375.  
  376.  
  377.  
  378. Patching:  Using Overlays
  379.  
  380.    If your computer requires special additional code,  and you know how to use
  381. an assembler, you may want to make an overlay to add this code to ZDE.   Write
  382. the overlay file, generate a HEX file with your assembler,  then merge it with
  383. ZDE.COM using MLOAD or a similar utility.  (Be sure the code fits!)
  384.  
  385.  
  386.  
  387.    Example: the following overlay adds special code for the NEC Starlet to the
  388. User Patch area, where it is immediately executed when ZDE is called up.   The 
  389. Starlet has  different terminal  emulations and  key definitions; most of this 
  390. code just ensures that it's in Soroc mode  (which is what ZDENSTAL sets ZDE up 
  391. for), and sets the cursor and DEL key definitions properly.
  392.  
  393.      There is another problem:  the ZDE  case  toggle  command (^^) has  to be 
  394. changed, as it will conflict with one of the Soroc arrow keys.  (On some other 
  395. computers,  you can't  generate ^^ from  the keyboard  at all.)   Note how the 
  396. overlay finds the address of the main command menu (all the menu addresses are
  397. stored at 0112-011Ch in ZDE.COM;  alternatively,  you can get ZDENSTAL to tell 
  398. you what they are), adds the appropriate offset (determine this yourself), and
  399. then changes the command key to something else.   Note the  flags  "*--->" for 
  400. data that may change with versions of ZDE.   You can also add code such as the
  401. following to ZDE.COM using the "a" command to enter assembler  mnemonics in  a 
  402. debugging utility like DDT or (Z)SID.
  403.  
  404.        ;NEC8401 Patch for ZDE 1.00 (Z80 mnemonics)
  405.        org  0100h             ;At beginning of ZDE.COM,
  406.               jp   entry      ; jump to User Patch area
  407. *--->  org  0260h             ;At User Patch area,
  408.        entry: ld   c,08h      ; set screen mode:
  409.               ld   e,81h      ;  Soroc, wrap on, fnkeys off, etc
  410.               rst  10h        ;   call special BIOS
  411.               ld   c,4Eh      ; set cursor keys:
  412.               ld   e,3        ;  to mapped codes
  413.               rst  10h        ;   call special BIOS
  414.               ld   c,4Dh      ; set definable key:
  415.               ld   de,data    ;  using data below
  416.               rst  10h        ;   call special BIOS
  417. *--->         ld   hl,(0112h) ; get address of main command menu
  418. *--->         ld   de,7*3     ;  offset of ^^ (this may change)
  419.               add  hl,de      ;   point to offending ^^ code
  420.               ld   (hl),'\'   ;    change it to a backslash
  421. *--->         jp   0490h      ;Jump to ZDE Start point
  422.        data:  db  4,7Fh,0,0   ;Data to set "DEL" key as DEL (7F)
  423.               end
  424.