2000-05-28 13:40:48 +00:00
|
|
|
;
|
|
|
|
; Ullrich von Bassewitz, 02.06.1998
|
|
|
|
;
|
|
|
|
; int isgraph (int c);
|
|
|
|
;
|
|
|
|
|
|
|
|
.export _isgraph
|
2001-09-08 14:00:41 +00:00
|
|
|
.include "ctype.inc"
|
2000-05-28 13:40:48 +00:00
|
|
|
|
|
|
|
_isgraph:
|
2000-06-08 18:35:04 +00:00
|
|
|
cpx #$00 ; Char range ok?
|
|
|
|
bne @L1 ; Jump if no
|
2000-05-28 13:40:48 +00:00
|
|
|
tay
|
|
|
|
lda __ctype,y ; Get character classification
|
2001-09-08 14:00:41 +00:00
|
|
|
eor #CT_CTRL_SPACE ; NOT control and NOT space
|
|
|
|
and #CT_CTRL_SPACE ; Mask character bits
|
2000-05-28 13:40:48 +00:00
|
|
|
rts
|
|
|
|
|
2000-06-08 18:35:04 +00:00
|
|
|
@L1: lda #$00 ; Return false
|
|
|
|
tax
|
|
|
|
rts
|
|
|
|
|