Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: awanderin Newsgroups: comp.sys.apple2.programmer Subject: Re: Text windows in Apple Pascal? Date: Fri, 27 Dec 2019 23:17:16 -0700 Organization: A noiseless patient Spider Lines: 49 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: reader02.eternal-september.org; posting-host="14e4a874684d25e54990a4da79a78207"; logging-data="26252"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+GE0Bcp2wL/S44XvSvmQZOTIb1OljI8P8=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) Cancel-Lock: sha1:yiXdIjDz96XVlOdT/YnfdxQQ8dI= sha1:UXg3WhLQaAyVMi03/tMOnxRpoIA= Xref: csiph.com comp.sys.apple2.programmer:5346 Paul MacMillan writes: > Hi, is there an easy way to get text window functionality in Apple > Pascal, similar to POKE 32 (etc.) in Applesoft? I tried POKEing but > the builtin WRITE/WRITELN seems to not care what I have poked. I am > not adverse to a little assembly language (especially with the very > capable Apple Pascal Assembler) but don't want to re-invent the wheel > if its already available. > > Thanks, > Paul The Apple Pascal Language Reference Manual describes a gotoxy(x, y) function that positions the text cursor at the chosen column (x) and row (y) position. There are no facilities that I know of to control the text-window within Pascal. The output functions do support a bunch of control characters, as described in the Apple IIe Technical Reference Manual, page 68-69: ctrl hex use ---- --- ---- E 05 turn on cursor display F 06 turn off cursor display G 07 sound bell (beep) H 08 move cursor left one column, wraps around to end of previous line J 0a move cursor down one row, scrolls if required K 0b clear from cursor position to end of screen L 0c clear screen and put cursor at top left M 0d move cursor to leftmost position N 0e set normal video O 0f set inverse video V 16 scroll display down one line, cursor stays where it is W 17 scroll display up one line, cursor stays where it is Y 19 move cursor to upper-left of screen without clearing Z 1a clear line the cursor is on \ 1c move cursor one space to right, wraps around to next line below ] 1d clear from cursor to end of line ^ 1e GOTOxy; initiates GOTOxy sequence; next two characters printed are x+32 and y+32, respectively _ 1f move cursor up one line if not at top of screen -- -- Jerry awanderin at gmail dot com