home *** CD-ROM | disk | FTP | other *** search
- ; BIOSATTR.ASM
- ;
- ; by Leonard Zerman
- ;
- ; Placed in the public domain by Tom Rettig Associates, 10/22/1990.
- ;
- ;-------------------------------------------
- ; Notes...: Get screen attributes from current cursor position
- ; Syntax..: <memvar> = BIOSATTR()
- ; Returns.: Screen attributes as <expN>
- ;------------------------------------------
-
- INCLUDE EXTENDA.INC
-
- CLpublic <BIOSATTR>
-
- CLfunc int BIOSATTR
-
- CLcode
-
- MOV AH,8H ; service to read character/attribute
- XOR BX,BX ; video page
- INT 10H ; read character/attribute at cursor
- MOV AL,AH ; Place attribute in AL
- XOR AH,AH ; Clear AH
- CLret AX ; Return attribute in AX
-
- END
-
-
-