;                   Mouse Driver for QEdit
;                 Written for Microsoft Mouse
;                    by JP Stromberg 1987
;
;          Use Makemenu.exe to convert to q.mnu


BEGIN LB,RB,BB,LM,RM,UM,DM

;--------------------- KEYS --------------------
LB: EXECUTE MAIN                         ; Execute Main Menu
HELP: TYPE 11,"E","q.hlp",enter          ; load help file
RB: EXECUTE SCROL                        ; Execute scroll menu
BB:  TYPE 27                             ; Both buttons,Esc
LM:  TYPE 0,75                           ; Mouse left
RM:  TYPE 0,77                           ; Mouse right
UM:  TYPE 0,72                           ; Mouse up
DM:  TYPE 0,80                           ; Mouse down
PGUP: TYPE 0,73                          ; Page up
PGDN: TYPE 0,81                          ; Page down
ENDD: TYPE 0,117                         ; control end
END:  TYPE 0,79                          ; end key
HOME: TYPE 0,71                          ; home key
F1:  TYPE 0,59                           ; F1 key
F2:  TYPE 0,60                           ; F2 key
F3:  TYPE 0,61                           ; F3 key
F5:  TYPE 0,63                           ; F5 key
F9:  TYPE 0,67                           ; F9 key
HOM: TYPE 0,119                          ; control home
KE: TYPE 11,"E"                          ; cntrl KE
KN: type 11,"N"
KF: type 11,"F"
KS: type 11,"S"
AC: type 0,46                            ; alt c
AL: type 0,38                            ; alt l
AM: type 0,50                            ; alt m
AU: type 0,22                            ; alt u
QA: type 17,"A"                          ; cntrl QA
QC: type 17,"C"
QF: type 17,"F"
CL: type 12                              ; cntrl l
CPD: type 0,118
CPU: type 0,132
KD: type 11,"D"
KDS: type 11,"D",enter
KDA: EXECUTE KD , SM
SM: match 1,1,,"Save Changes",N,NUL
N: type "N"
NUL: nothing
KQ: type 11,"Q"
AX: type 0,45
TL: type 0,15

;-------------------- MAIN MENU -------------------
MAIN: Menu "Main Menu", 5,50
      Option "Cursor movements   ", CM
      Option "Block commands     ", BLK
      Option "File commands      ", FILE
      Option "Scroll             ", SCROL
      Option "Find and replace   ", FAR
      Option "Exit Menu          ", EXIT
      Option "Help               ", HELP
      Option "Cancel             "
      Mend

;-----------------CURSOR MENU -------------------------
CM: Menu "Cursor movements", 5,50
    Option "Top of screen      ",HOM
    Option "Bottom of screen   ",ENDD
    Option "Beginning of line  ",HOME
    Option "End of line        ",END
    Option "Tab left           ",TL
    Option "Main menu          ",MAIN
    Option "Cancel             "
    Mend

;-----------------FILE MENU -----------------------
FILE: Menu "File Menu ", 5,50
      Option "Edit file        ",KE
      Option "Change file name ",KF
      Option "Save file        ",KS
      Option "Next file        ",KN
      Option "Main menu        ",MAIN
      Option "Cancel           "
      Mend

;-----------------BLOCK MENU ----------------------
BLK:  Menu "Block Menu ", 6,50
      Option "Mark line        ",AL
      Option "Unmark block     ",AU
      Option "Move block       ",AM
      Option "Copy block       ",AC
      Option "Main menu        ",MAIN
      Option "Cancel           "

      Mend

;-----------------FIND AND REPLACE MENU-----------
FAR:  Menu "Find and Replace ", 7,50
      Option "Find text        ",QF
      Option "Repeat last F/R  ",CL
      Option "Replace          ",QA
      Option "Main menu        ",MAIN
      Option "Cancel           "
      Mend

;-----------------SCROLL MENU ---------------------
SCROL: Menu "Scroll menu ", 8,50
       Option "Bottom of file  ",CPD
       Option "Top of file     ",CPU
       Option "Page up         ",PGUP
       Option "Page down       ",PGDN
       Option "Main menu       ",MAIN
       Option "Cancel          "
       Mend

;---------------- EXIT MENU ----------------------


EXIT: Menu "Exit Menu", 5,40
      Option "Exit file, save changes    ",KDS
      Option "Exit file, abandon changes ",KDA
      Option "Quit to system             ",KQ
      Option "Global exit, all files     ",AX
      Option "Main menu                  ",MAIN
      Option "Cancel                     "
      Mend



