home *** CD-ROM | disk | FTP | other *** search
/ C!T ROM 5 / ctrom5b.zip / ctrom5b / PROGRAM / ASM / ALIB30B / MKEY04.ASM < prev    next >
Assembly Source File  |  1994-10-15  |  892b  |  38 lines

  1.     page    66,132
  2. ;******************************** MKEY04.ASM *********************************
  3.  
  4. LIBSEG           segment byte public "LIB"
  5.         assume cs:LIBSEG , ds:nothing
  6.  
  7. ;----------------------------------------------------------------------------
  8. .xlist
  9.     include  mac.inc
  10.     include  common.inc
  11. .list
  12. comment 
  13. ;- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -(MOUSE/KEY)
  14. IS_UPPER - check if key returned by KEY_READ is upper case
  15. ;
  16. ; inputs:    AX = keycode returned by KEY_READ or AH=0, AL=ascii
  17. ;
  18. ; output:   if CF = 1, keycode is not a character from A-Z
  19. ;* * * * * * * * * * * * * *
  20. 
  21.     PUBLIC    IS_UPPER
  22. IS_UPPER        PROC    FAR
  23.     or        ah,ah
  24.     JNZ     isu_exit
  25.     CMP     AL,41h    ; 'A'
  26.     JB      isu_exit
  27.     CMP     AL,5Ah    ; 'Z'
  28.     JA      isu_exit
  29.     CLC
  30.     RETF
  31. isu_exit:
  32.     STC
  33.     RETF
  34. IS_UPPER ENDP
  35.  
  36. LIBSEG    ENDS
  37.     end
  38.