1
0
mirror of https://github.com/cc65/cc65.git synced 2024-09-28 10:55:43 +00:00

fix some style issues

This commit is contained in:
mrdudz 2015-10-12 15:54:08 +02:00
parent 21732e3c5b
commit a2b514a7cf
3 changed files with 21 additions and 21 deletions

View File

@ -14,18 +14,18 @@
.include "soft80.inc"
soft80_textcolor:
ldx soft80_internal_textcolor ; get old value
sta soft80_internal_textcolor ; set new value
ldx soft80_internal_textcolor ; get old value
sta soft80_internal_textcolor ; set new value
jsr mkcharcolor
txa ; get old value
txa ; get old value
rts
soft80_bgcolor:
ldx soft80_internal_bgcolor ; get old value
stx tmp2 ; save old value
sta soft80_internal_bgcolor ; set new value
ldx soft80_internal_bgcolor ; get old value
stx tmp2 ; save old value
sta soft80_internal_bgcolor ; set new value
jsr mkcharcolor
@ -40,9 +40,9 @@ lp1:
.scope
lda soft80_colram+(page*250),x
and #$0f
cmp tmp2 ; old bg color
cmp tmp2 ; old bg color
bne @sk1
lda soft80_internal_bgcolor ; new bg color
lda soft80_internal_bgcolor ; new bg color
sta soft80_colram+(page*250),x
@sk1:
.endscope
@ -54,7 +54,7 @@ lp1:
sei
ldy $01
lda #$34 ; disable I/O
lda #$34 ; disable I/O
sta $01
; if the old bg color is equal to text color in this cell, then also
@ -66,11 +66,11 @@ lp2:
.scope
lda soft80_vram+(page*250),x
and #$0f
cmp tmp2 ; old bg color
cmp tmp2 ; old bg color
bne @sk2
lda soft80_internal_bgcolor ; new bg color
lda soft80_internal_bgcolor ; new bg color
@sk2:
ora tmp1 ; new bg color (high nibble)
ora tmp1 ; new bg color (high nibble)
sta soft80_vram+(page*250),x
.endscope
.endrepeat
@ -78,10 +78,10 @@ lp2:
inx
bne lp2
sty $01 ; enable I/O
sty $01 ; enable I/O
cli
lda tmp2 ; get old value
lda tmp2 ; get old value
rts
mkcharcolor:
@ -90,9 +90,9 @@ mkcharcolor:
asl a
asl a
asl a
sta tmp1 ; remember new bg color (high nibble)
sta tmp1 ; remember new bg color (high nibble)
ora soft80_internal_textcolor
sta CHARCOLOR ; text/bg combo for new chars
sta CHARCOLOR ; text/bg combo for new chars
rts
;-------------------------------------------------------------------------------

View File

@ -70,11 +70,11 @@ soft80_init:
sta $01
cli
lda 646 ; use current textcolor
lda 646 ; use current textcolor
and #$0f
sta soft80_internal_textcolor
lda VIC_BG_COLOR0 ; use current bgcolor
lda VIC_BG_COLOR0 ; use current bgcolor
and #$0f
sta soft80_internal_bgcolor
asl a

View File

@ -40,18 +40,18 @@ soft80_kclrscr:
.if SOFT80COLORVOODOO = 1
lda soft80_internal_bgcolor
jsr clear ; clear color ram
jsr clear ; clear color ram
.endif
sei
ldy $01
lda #$34 ; enable RAM under I/O
lda #$34 ; enable RAM under I/O
sta $01
lda CHARCOLOR
and #$f0
ora soft80_internal_bgcolor
jsr clear ; clear vram
jsr clear ; clear vram
sty $01
cli