Prev: 04264 Up: Map Next: 04496
04381: THE 'LOWER SCREEN COPYING' SUBROUTINE
Used by the routines at KEY_INPUT and INPUT.
This subroutine is called whenever the line in the editing area or the INPUT area is to be printed in the lower part of the screen.
ED_COPY 04381 CALL TEMPS Use the permanent colours.
04384 RES 3,(IY+2) Signal that the 'mode is to be considered unchanged' (reset bit 3 of TV-FLAG) and the 'lower screen does not need clearing' (reset bit 5).
04388 RES 5,(IY+2)
04392 LD HL,(23690) Save the current value of S-POSNL.
04395 PUSH HL
04396 LD HL,(23613) Keep the current value of ERR-SP.
04399 PUSH HL
04400 LD HL,4455 This is ED_FULL.
04403 PUSH HL Push this address on to the machine stack to make ED_FULL the entry point following an error (see ERR-SP).
04404 LD (23613),SP
04408 LD HL,(23682) Push the value of ECHO-E on to the stack.
04411 PUSH HL
04412 SCF Make HL point to the start of the space and DE the end.
04413 CALL SET_DE
04416 EX DE,HL
04417 CALL OUT_LINE2 Now print the line.
04420 EX DE,HL Exchange the pointers and print the cursor.
04421 CALL OUT_CURS
04424 LD HL,(23690) Next fetch the current value of S-POSNL and exchange it with ECHO-E.
04427 EX (SP),HL
04428 EX DE,HL Pass ECHO-E to DE.
04429 CALL TEMPS Again fetch the permanent colours.
The remainder of any line that has been started is now completed with spaces printed with the 'permanent' PAPER colour.
ED_BLANK 04432 LD A,(23691) Fetch the current line number from S-POSNL and subtract the old line number.
04435 SUB D
04436 JR C,ED_C_DONE Jump forward if no 'blanking' of lines required.
04438 JR NZ,ED_SPACES Jump forward if not on the same line.
04440 LD A,E Fetch the old column number and subtract the new column number (at S-POSNL).
04441 SUB (IY+80)
04444 JR NC,ED_C_DONE Jump if no spaces required.
ED_SPACES 04446 LD A," " A 'space'.
04448 PUSH DE Save the old values.
04449 CALL PRINT_OUT Print it.
04452 POP DE Fetch the old values.
04453 JR ED_BLANK Back again.
New deal with any errors.
ED_FULL 04455 LD D,0 Give out a 'rasp' (see RASP).
04457 LD E,(IY-2)
04460 LD HL,6800
04463 CALL BEEPER
04466 LD (IY+0),255 Cancel the error number (ERR-NR).
04470 LD DE,(23690) Fetch the current value of S-POSNL and jump forward.
04474 JR ED_C_END
The normal exit upon completion of the copying over of the edit or the INPUT line.
ED_C_DONE 04476 POP DE The new position value.
04477 POP HL The 'error address'.
But come here after an error.
ED_C_END 04478 POP HL The old value of ERR-SP is restored.
04479 LD (23613),HL
04482 POP BC Fetch the old value of S-POSNL.
04483 PUSH DE Save the new position values.
04484 CALL CL_SET Set the system variables.
04487 POP HL The old value of S-POSNL goes into ECHO-E.
04488 LD (23682),HL
04491 LD (IY+38),0 X-PTR is cleared in a suitable manner and the return made.
04495 RET
Prev: 04264 Up: Map Next: 04496