Prev: 03405 Up: Map Next: 03503
Used by the routines at NEW and CLEAR.
The address of this routine is found in the parameter table.
In the first instance the whole of the display is 'cleared' - the 'pixels' are all reset and the attribute bytes are set to equal the value in ATTR-P - then the lower part of the display is reformed.
CLS 03435 CALL CL_ALL The whole of the display is 'cleared'.
This entry point is used by the routines at KEY_INPUT, MAIN_EXEC and INPUT.
CLS_LOWER 03438 LD HL,23612 This is TV-FLAG.
03441 RES 5,(HL) Signal 'do not clear the lower screen after keystroke'.
03443 SET 0,(HL) Signal 'lower part'.
03445 CALL TEMPS Use the permanent values, i.e. ATTR-T is copied from BORDCR.
03448 LD B,(IY+49) The lower part of the screen is now 'cleared' with these values (B=DF-SZ).
With the exception of the attribute bytes for lines 22 and 23 the attribute bytes for the lines in the lower part of the display will need to be made equal to ATTR-P.
03454 LD HL,23232 Attribute byte at start of line 22.
03457 LD A,(23693) Fetch ATTR-P.
03460 DEC B The line counter.
03461 JR CLS_3 Jump forward into the loop.
CLS_1 03463 LD C,32 32 characters per line.
CLS_2 03465 DEC HL Go back along the line setting the attribute bytes.
03466 LD (HL),A
03467 DEC C
03468 JR NZ,CLS_2
CLS_3 03470 DJNZ CLS_1 Loop back until finished.
The size of the lower part of the display can now be fixed.
03472 LD (IY+49),2 It will be two lines in size (DF-SZ).
This entry point is used by the routine at CL_ALL.
It now remains for the following 'house keeping' tasks to be performed.
CL_CHAN 03476 LD A,253 Open channel 'K'.
03481 LD HL,(23633) Fetch the address of the current channel (CURCHL) and make the output address PRINT_OUT and the input address KEY_INPUT.
03484 LD DE,2548
03487 AND A
CL_CHAN_A 03488 LD (HL),E
03489 INC HL
03490 LD (HL),D
03491 INC HL
03492 LD DE,4264
03495 CCF First the output address then the input address.
03496 JR C,CL_CHAN_A
03498 LD BC,5921 As the lower part of the display is being handled the 'lower print line' will be line 23.
03501 JR CL_SET Return via CL_SET.
Prev: 03405 Up: Map Next: 03503