LISTING FOR >udd>sm>ds>w>ml>tek4025.ctl COMPILED BY Multics LISP Compiler, Version 2.13c, July 11, 1983 ON 05/04/00 1651.9 mdt Thu IN BEHALF OF Schroth.SysMaint.m ;;; *********************************************************** ;;; * * ;;; * Copyright, (C) Honeywell Information Systems Inc., 1982 * ;;; * * ;;; * Copyright (c) 1978 by Massachusetts Institute of * ;;; * Technology and Honeywell Information Systems, Inc. * ;;; * * ;;; *********************************************************** ;;; ;;; -*-LISP-*- ;;; ;;; Tektronix 4025 control package ;;; Snarfed from VIP7800 package, ;;; In turn ripped off from VIP7200ctl ;;; ;;; Roy A. Leban, January 15, 1979. ;;; ;;; Notes on current problems with this implementation: ;;; 1) It is possible to have screens > 33 lines. This is not done. ;;; 2) User setable command character desirable. (declare (special X Y screenheight screenlinelen tty-type)) (declare (special idel-lines-availablep idel-chars-availablep)) (declare (special ctl-close-necessaryp)) ; Initialize terminal and terminal control package. (defun DCTL-init () (setq idel-lines-availablep t idel-chars-availablep t) (setq screenheight 33. screenlinelen 79.) (setq tty-type 'tek4025)(setq ctl-close-necessaryp t) (Rtyo 37)(Rprinc "wor 33")(Rtyo 15) ;Work space of 33 lines (Rtyo 37)(Rprinc "wor")(Rtyo 15) ;Go to top of work space. (setq X 0 Y 33)) ; Move terminal's cursor to desired position. (defun DCTL-position-cursor (x y) (cond ((and (= x X)(= y Y)) nil) ((and (= x 0)(= y 0)) (Rtyo 37)(Rprinc "jum")(Rtyo 15) (setq X 0 Y 0)) ((= x 0) ; column 1 of a line. (Rtyo 37)(Rprinc "jum ") (DCTL-4025-outnum (+ y 1)) (Rtyo 15) (setq X x Y y)) ((and (= x X)(> Y y)) ; same column- up. (Rtyo 37)(Rprinc "up ") (DCTL-4025-outnum (- Y y)) (Rtyo 15) (setq Y y)) ((and (= x X)(< Y y)) ; same column- down. (Rtyo 37)(Rprinc "dow ") (DCTL-4025-outnum (- y Y)) (Rtyo 15) (setq Y y)) ((and (= y Y)(> X x)) ; same line- left. (Rtyo 37)(Rprinc "lef ") (DCTL-4025-outnum (- X x)) (Rtyo 15) (setq X x)) ((and (= y Y)(< X x)) ; same line- right. (Rtyo 37)(Rprinc "rig ") (DCTL-4025-outnum (- x X)) (Rtyo 15) (setq X x)) ;;else do a jump with both line and column. (t (setq X x Y y) (Rtyo 37)(Rprinc "jum ") (DCTL-4025-outnum (+ y 1)) (Rprinc ",") (DCTL-4025-outnum (+ x 1)) (Rtyo 15)))) ; Output string. (defun DCTL-display-char-string (string) (setq X (+ X (stringlength string))) (Rprinc string)) ; Clear to end of screen. (defun DCTL-clear-rest-of-screen () (Rtyo 37)(Rprinc "dli 33") ; max of 33 lines left in buffer. (Rtyo 15)) ; Clear to end of line. (defun DCTL-kill-line () (Rtyo 37)(Rprinc "dch 80") ; max of 80 chars left in line. (Rtyo 15)) (defun DCTL-insert-lines (n) (Rtyo 37)(Rprinc "ili ") ; Note the inherent problem with this. (DCTL-4025-outnum n) ; ili causes lines at the bottom to (Rtyo 15)) ; roll of the screen but not out of ; the terminal. (defun DCTL-delete-lines (n) (Rtyo 37)(Rprinc "dli ") ; first delete the lines, (DCTL-4025-outnum n) (Rtyo 15) (DCTL-insert-lines n)) ; then rejustify with inserts. (defun DCTL-insert-char-string (str) (Rtyo 37)(Rprinc "ich")(Rtyo 15) (Rprinc str) ; should automatically revert out. if not "!wor" (setq X (+ X (stringlength str)))) (defun DCTL-delete-chars (n) (Rtyo 37)(Rprinc "dch ") (DCTL-4025-outnum n) (Rtyo 15)) (defun DCTL-4025-outnum (n) (cond ((> n 9.) (Rtyo (+ 60 (// n 10.))) (setq n (- n (* 10. (// n 10.)))))) (Rtyo (+ 60 n))) (defun DCTL-close-screen () (Rtyo 37)(Rprinc "wor 0")(Rtyo 15)) Functions Defined Name Offset Offset Name DCTL-4025-outnum 640 0 DCTL-init DCTL-clear-rest-of-screen 430 66 DCTL-position-cursor DCTL-close-screen 672 414 DCTL-display-char-string DCTL-delete-chars 612 430 DCTL-clear-rest-of-screen DCTL-delete-lines 522 452 DCTL-kill-line DCTL-display-char-string 414 474 DCTL-insert-lines DCTL-init 0 522 DCTL-delete-lines DCTL-insert-char-string 554 554 DCTL-insert-char-string DCTL-insert-lines 474 612 DCTL-delete-chars DCTL-kill-line 452 640 DCTL-4025-outnum DCTL-position-cursor 66 672 DCTL-close-screen Functions Referenced DCTL-4025-outnum Rprinc stringlength DCTL-insert-lines Rtyo ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group BULL including BULL HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell BULL Inc., Groupe BULL and BULL HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, BULL or BULL HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by BULL HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved