home *** CD-ROM | disk | FTP | other *** search
Wrap
(provide (quote terminal)) (require (quote ehelp)) (defvar terminal-escape-char 30 "\ *All characters except for this are passed verbatim through the terminal-emulator. This character acts as a prefix for commands to the emulator program itself. Type this character twice to send it through the emulator. Type ? after typing it for a list of possible commands. This variable is local to each terminal-emulator buffer.") (defvar terminal-scrolling t "\ *If non-nil, the terminal-emulator will `scroll' when output occurs past the bottom of the screen. If nil, output will `wrap' to the top of the screen. This variable is local to each terminal-emulator buffer.") (defvar terminal-more-processing t "\ *If non-nil, do more-processing. This variable is local to each terminal-emulator buffer.") (defvar terminal-redisplay-interval 5000 "\ *Maximum number of characters which will be processed by the terminal-emulator before a screen redisplay is forced. Set this to a large value for greater throughput, set it smaller for more frequent updates but overall slower performance.") (defvar terminal-more-break-insertion "*** More break -- Press space to continue ***") (defvar terminal-escape-map nil) (defvar terminal-map nil) (defvar terminal-more-break-map nil) (if terminal-map nil (let ((map (make-keymap))) (fillarray map (quote te-pass-through)) (setq terminal-map map))) (if terminal-escape-map nil (let ((map (make-keymap))) (fillarray map (quote undefined)) (let ((s "0")) (while (<= (aref s 0) 57) (define-key map s (quote digit-argument)) (aset s 0 (1+ (aref s 0))))) (define-key map "b" (quote switch-to-buffer)) (define-key map "o" (quote other-window)) (define-key map "e" (quote te-set-escape-char)) (define-key map "" (quote redraw-display)) (define-key map "" (quote te-flush-pending-output)) (define-key map "m" (quote te-toggle-more-processing)) (define-key map "x" (quote te-escape-extended-command)) (define-key map "?" (quote te-escape-help)) (define-key map (char-to-string help-char) (quote te-escape-help)) (setq terminal-escape-map map))) (defvar te-escape-command-alist nil) (if te-escape-command-alist nil (setq te-escape-command-alist (quote (("Set Escape Character" . te-set-escape-char) ("Refresh" . redraw-display) ("Record Output" . te-set-output-log) ("Photo" . te-set-output-log) ("Tofu" . te-tofu) ("Stuff Input" . te-stuff-string) ("Flush Pending Output" . te-flush-pending-output) ("Enable More Processing" . te-enable-more-processing) ("Disable More Processing" . te-disable-more-processing) ("Scroll at end of page" . te-do-scrolling) ("Wrap at end of page" . te-do-wrapping) ("Switch To Buffer" . switch-to-buffer) ("Other Window" . other-window) ("Kill Buffer" . kill-buffer) ("Help" . te-escape-help) ("Set Redisplay Interval" . te-set-redisplay-interval))))) (if terminal-more-break-map nil (let ((map (make-keymap))) (fillarray map (quote te-more-break-unread)) (define-key map (char-to-string help-char) (quote te-more-break-help)) (define-key map " " (quote te-more-break-resume)) (define-key map "" (quote redraw-display)) (define-key map "" (quote te-more-break-flush-pending-output)) (define-key map "" (quote te-more-break-advance-one-line)) (setq terminal-more-break-map map))) (defun te-escape nil (interactive) (byte-code "ÇÇÈ É ÊË!Ì!Í\" ÎÏÐ!\"# Ñ!)ÒÓ!ÔÕÖ\"\"C ×Ø )O Ù\"
O Ú!+" [s local global terminal-escape-map prefix-arg terminal-escape-char last-command-char nil current-local-map current-global-map ((byte-code "Â!Ã !" [global local use-global-map use-local-map] 3)) use-global-map use-local-map read-key-sequence format "Emacs Terminal escape> %d " prefix-numeric-value "Emacs Terminal escape> " message "" string= make-string 1 -259 te-pass-through lookup-key call-interactively] 14)) (defun te-escape-help nil "\ Provide help on commands available after terminal-escape-char is typed." (interactive) (byte-code "ÂÃÄ!Å !ÆÇ!)" [char terminal-escape-char nil message "Terminal emulator escape help..." single-key-description with-electric-help (lambda nil (byte-code "ÇÈÉ%!ÇÊË!!ÇÈÌÍÎ Â#Î#!ÏÐ!+ ÐÑ!Ò\"1 ÓÑ!Ô\"
o Õ@A!? Ö×Ø\"
O ÙÚÙ!OÇÛ!Ç@@!ÇÜ!Ç!ÝÞ!)A2 )Æ" [char terminal-escape-map t l te-escape-command-alist doc nil princ format "Terminal-emulator escape, invoked by \"%s\" Type \"%s\" twice to send a single \"%s\" through. Other chars following \"%s\" are interpreted as follows: " substitute-command-keys "\\{terminal-escape-map} " " Subcommands of \"%s\" (%s) " where-is-internal te-escape-extended-command fboundp sortcar copy-sequence string< sort (lambda (a b) (byte-code "Â@ @\"" [a b string<] 3)) documentation "Not documented" string-match " " 0 match-beginning " \"" "\": " write-char 10] 23))] 4)) (defun te-escape-extended-command nil (interactive) (byte-code "ÄÂÅÆÄÂ$)
ÇÈ)" [c completion-ignore-case t te-escape-command-alist nil completing-read "terminal command: " foo (byte-code "Ã!
* ÄÃ @@!\"\" ÅÆÇ @A!\"&