mirror of
https://github.com/blondie7575/WeeGUI.git
synced 2025-01-25 06:31:26 +00:00
- Added desktop painting
- Fixed WGEraseView corrupting the X register - WGPaintAll now renders contents cleanly
This commit is contained in:
parent
4e1843706e
commit
ae3f4f491e
2
gui.s
2
gui.s
@ -24,7 +24,7 @@ main:
|
||||
;jmp tortureTestPrint
|
||||
;jmp tortureTestRects
|
||||
|
||||
jsr WGClearScreen
|
||||
jsr WGDesktop
|
||||
|
||||
lda #<testView
|
||||
sta PARAM0
|
||||
|
BIN
guidemo.dsk
BIN
guidemo.dsk
Binary file not shown.
37
painting.s
37
painting.s
@ -43,6 +43,43 @@ WGClearScreen_charLoop:
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; WGDesktop
|
||||
; Paints the desktop pattern (assumes 80 cols)
|
||||
; Side effects: Clobbers BASL,BASH
|
||||
;
|
||||
WGDesktop:
|
||||
|
||||
SAVE_AXY
|
||||
SETSWITCH PAGE2OFF
|
||||
ldx #23
|
||||
|
||||
WGDesktop_lineLoop:
|
||||
lda TEXTLINES_L,x ; Compute video memory address of line
|
||||
sta BASL
|
||||
lda TEXTLINES_H,x
|
||||
sta BASH
|
||||
|
||||
ldy #39
|
||||
|
||||
WGDesktop_charLoop:
|
||||
lda #'W'
|
||||
sta (BASL),y
|
||||
SETSWITCH PAGE2ON
|
||||
lda #'V'
|
||||
sta (BASL),y
|
||||
SETSWITCH PAGE2OFF
|
||||
dey
|
||||
bpl WGDesktop_charLoop
|
||||
|
||||
dex
|
||||
bpl WGDesktop_lineLoop
|
||||
|
||||
RESTORE_AXY
|
||||
rts
|
||||
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; WGPlot
|
||||
; Plots a character at current cursor position (assumes 80 cols)
|
||||
|
5
views.s
5
views.s
@ -442,7 +442,7 @@ paintWindowTitle_done:
|
||||
; Erases the current view (including decoration)
|
||||
;
|
||||
WGEraseView:
|
||||
SAVE_AY
|
||||
SAVE_AXY
|
||||
SAVE_ZPP
|
||||
|
||||
LDY_ACTIVEVIEW
|
||||
@ -470,7 +470,7 @@ WGEraseView:
|
||||
|
||||
WGEraseView_done:
|
||||
RESTORE_ZPP
|
||||
RESTORE_AY
|
||||
RESTORE_AXY
|
||||
rts
|
||||
|
||||
|
||||
@ -859,6 +859,7 @@ WGViewPaintAll_loop:
|
||||
lda WG_VIEWRECORDS+2,y ; Last view?
|
||||
beq WGViewPaintAll_done
|
||||
|
||||
jsr WGEraseViewContents
|
||||
jsr WGPaintView
|
||||
inx
|
||||
bra WGViewPaintAll_loop
|
||||
|
Loading…
x
Reference in New Issue
Block a user