![]() |
Routines |
| Prev: 61651 | Up: Map | Next: 61760 |
|
Used by the routine at InputLine.
Reached from InputLine_Enter when ENTER is pressed. Token walks and vocabulary lookup are separate jump-table entries (AdvanceInputPointer, SearchVocabulary_Commands and neighbours).
|
||||
| SubmitInputLine | 61670 | LD A,32 | Write a space to *PrintState_Character. | |
| 61672 | LD (23545),A | |||
| 61675 | LD B,64 | B=64. | ||
| 61677 | SUB A | Write 0 to *PrintState_Flags, *PrintState and *PrintState_Column. | ||
| 61678 | LD (23542),A | |||
| 61681 | LD (23541),A | |||
| 61684 | LD (23543),A | |||
| 61687 | LD A,22 | Write 22 to *PrintState_Row. | ||
| 61689 | LD (23544),A | |||
|
Clear the input rows.
|
||||
| SubmitInputLine_ClearLoop | 61692 | CALL PrintCharacter | Call PrintCharacter until the count is done. | |
| 61695 | DJNZ SubmitInputLine_ClearLoop | |||
| 61697 | SUB A | Write 0 to *PrintState_Column. | ||
| 61698 | LD (23543),A | |||
| 61701 | CALL ScrollAdjust | Call ScrollAdjust. | ||
|
Print a ">" prompt on the lower screen.
|
||||
| 61704 | LD A,(23689) | Write the prompt row to *PrintState_Row. | ||
| 61707 | LD B,A | |||
| 61708 | LD A,24 | |||
| 61710 | SUB B | |||
| 61711 | LD (23544),A | |||
| 61714 | LD A,7 | Write 7 to *PrintState. | ||
| 61716 | LD (23541),A | |||
| 61719 | LD A,62 | Write > to *PrintState_Character. |
||
| 61721 | LD (23545),A | |||
| 61724 | CALL PrintCharacter | Call PrintCharacter. | ||
|
Echo the submitted line.
|
||||
| 61727 | LD A,5 | Write 5 to *PrintState. | ||
| 61729 | LD (23541),A | |||
| 61732 | LD HL,23470 | Point HL at InputBuffer. | ||
| SubmitInputLine_Echo | 61735 | LD A,(HL) | Fetch the next character. | |
| 61736 | CP 13 | Jump to SubmitInputLine_ScrollBack if it is ENTER. | ||
| 61738 | JR Z,SubmitInputLine_ScrollBack | |||
| 61740 | INC HL | Write this character to *PrintState_Character. | ||
| 61741 | LD (23545),A | |||
| 61744 | CALL PrintCharacter | Call PrintCharacter. | ||
| 61747 | JR SubmitInputLine_Echo | Jump to SubmitInputLine_Echo. | ||
|
Scroll the lower screen back two rows.
|
||||
| SubmitInputLine_ScrollBack | 61749 | LD A,(23689) | Subtract 2 from the line byte of S_POSN. | |
| 61752 | SUB 2 | |||
| 61754 | LD (23689),A | |||
| 61757 | JP ScrollAdjust | Jump to ScrollAdjust. | ||
| Prev: 61651 | Up: Map | Next: 61760 |