; ; SCAN-BG2.Z80 - 05/01/90 ; ; This file is an overlay for SCAN22.COM that modifies the command ; table and command help screen for BGii compatibility. Note ; that these BGii commands prempt some of SCAN's default WordStar ; commands. If you want both WordStar and BGii compatibility, ; you may have to experiment with the command set to get an ; acceptable mix. ; ; This file can not be used with SCAN21.COM. ; ; Assemble to a HEX file using Z80ASM, ZAS or ASM (rename to ; SCAN-BG2.ASM) and use MLOAD or MYLOAD to overlay the hex file ; on SCAN22.COM: ; ; MLOAD SCAN.COM=SCAN22.COM,SCAN-BG2.HEX ; ; ; Equates ; BS EQU 8 ; Backspace TAB EQU 9 ; Tab LF EQU 10 ; Line feed CR EQU 13 ; Carriage return RETURN EQU 13 ; Carriage return ESC EQU 27 ; Escape SPACE EQU 32 ; Space ; HELP EQU 13B5h ; Start of help screen overlay ; See SCAN22.PAT for basic patching information for SCAN22. ORG 111h ; Wildcard search character ; ; Wildcard String Search Character ; -------------------------------- ; ; Like WordStar, SCAN recognizes a wildcard character in the ; search string, matching any single character in the text. The ; default wildcard character is WordStar's wildcard character ^A ; (01h). This means that you can't search for the ^A (01H) ; character in the text, which is used in some ZCPR3 files to ; turn on video highlighting. You can patch a different wildcard ; character in the location below. Pick a character not usually ; found in the text you normally search. The tilde (~) character ; is one suggestion. ; ; Default Location Purpose ;================================================================ DB 'A'-40h ; 0111h ; Default is WordStar character (^A=01h) ORG 280h ; Start of command table ; ; Command Customization ; --------------------- ; ; SCAN automatically capitalizes command characters when they are ; entered. If entered commands are characters between A and Z, ; they are also made into control characters by subtracting 40h ; from them ('A'-40h = 01h, 'Z'-40h = 1Ah.) Therefore, all ; command letters patched at the locations below must be patched ; as the capital letter - 40h. All other command characters are ; used exactly as entered. ; ; When SCAN gets a command, it tries to find the first match with ; a command in the the command list starting at 280h. If you ; change a command to one that appears later in the list, the ; later use of the command will be automatically preempted, as a ; command match will already have been found. For example, using ; TAB to back up one page (at 283h) will automatically preempt ; its original use to scroll the screen right (at 28Ah). Since a ; command letter may be entered with or without the control key ; being pressed, patching a command to 'E'-40h (^E or 05h) means, ; for example, that entering e, E or ^E gives the same result. ; ; The commands below marked '(alternate)' do not appear in the ; HELP screen command summary. Note also that changed commands ; will not be automatically reflected in the SCAN HELP screen. ; However, the HELP screen may also be patched to match your new ; configuration (see the HELP section, below.) ; ; Commands modified for BGii compatibility are marked ; '(***BGii)', below. Several commands have been changed from ; SCAN's default commands to avoid conflict with other BGii ; commands, or because the original WordStar command may have ; been obscure to non-WordStar users. These commands are marked ; '(***BGii new)'. Some commands have been disabled by setting ; the command byte to 0. You may replace them with your own ; favorite commands. See SCAN.PAT for the original command list. ; ; Default Location Purpose ;================================================================ DB 'U'-40h ; 0280 ; Cancel command DB 'B'-40h ; 0281h ; Top of file (***BGii) DB 'E'-40h ; 0282h ; Bottom of file (***BGii) DB TAB ; 0283h ; Up (back) one page (***BGii) DB '<' ; 0284h ; Up (back) one page DB ',' ; 0285h ; Up (back) one line DB 0 ; 0286h ; Up (back) one line (***disabled) DB 0 ; 0287h ; Up (back) one line (***disabled) DB 0 ; 0288h ; Scroll display left (***disabled) DB 'L'-40h ; 0289h ; Scroll display left (***BGii) DB 0 ; 028Ah ; Scroll display right (***disabled) DB 'R'-40h ; 028Bh ; Scroll display right (***BGii) DB 0 ; 028Ch ; Down (forward) one line (***disabled) DB 0 ; 028Dh ; Down (forward) one line (***disabled) DB SPACE ; 028Eh ; Down (forward) one line (***BGii) DB '.' ; 028Fh ; Down (forward) one line DB '>' ; 0290h ; Down (forward) one page DB RETURN ; 0291h ; Down (forward) one page (***BGii) DB 0 ; 0292h ; Down (forward) one page (***disabled) DB 'C'-40h ; 0293h ; Exit (***BGii) DB 'G'-40h ; 0294h ; Find string (***BGii) DB 'A'-40h ; 0295h ; Find again (***BGii new) DB 'P'-40h ; 0296h ; Printer toggle DB 'V'-40h ; 0297h ; Video mode toggle ORG 02E0h ; ; Return to Left Margin ; --------------------- ; ; This character is the second character in the two-character ; WordStar 'quick' command '^QS'. Since BGii uses 'L' for the ; move left command, this command was changed to '^QL' for ; compatibility. ; ; Default Location Purpose ;================================================================ DB 'L'-40h ; 02E0h ; Return to left margin (***BGii new) ORG HELP ; ; Excerpt from Command Menu Help Screen ; ------------------------------------- ; ; Due to the order of display, the screen segments below may not ; seem to be in the order you may expect to see them. When ; modifying the HELP screen, you must not add or subtract any ; characters. Work within the given quotes only. ; DB ' B -- Start of File',0,7,41 DB ' G -- Find String',0,8,10 DB ' < -- Up One Screen',0,8,42 DB ' A -- Find Again',0,9,10 DB ' , -- Up One Line',0,9,42 DB ' U -- Cancel Find',0,11,10 DB ' L <--L Display R--> R ',0 ORG HELP+0B3h DB ' . -- Down One Line',0,13,42 DB ' P -- Printer',0,14,10 DB ' > -- Down One Screen',0,14,41 DB ' KW -- File Output',0,15,9 DB ' E -- End of File',0,15,41 DB ' V -- Video Mode',0,16,43 DB '/ -- Help/Text',0 ORG HELP+0140h DB ' KR -- Read New File',0,19,8 DB ' K0-9 - Set Marker',0,19,41 DB ' KD, KQ -- EXIT',0,20,8 DB ' Q0-9 - Go to Marker',0,20,41 DB ' ^C, KX -- EXIT',0 ;================================================================ END ; Patch area