;; -*- mode: emacs-lisp; coding: hebrew-iso-8bit-unix -*- ;; graphics.el --- define graphic keys for FSE like Emacs ;; Copyright (C) 1992-2000 Ehud karni ;; This file is NOT part of GNU Emacs, distribution conditions below. ;; ;; EHUD KARNI éðø÷ ãåäà ;; Ben Gurion st' 14 ïåéøåâ ïá 'çø ;; Kfar - Sava 44 257 àáñ - øôë ;; =================================== ;; 972-(0)9-7659599 ;; =================================== ;; RCS: $Id: graphics.el,v 1.102 2000/03/05 13:33:16 ehud Exp $ ;; ;; LOG: $Log: graphics.el,v $ ;; Revision 1.102 2000/03/05 13:33:16 ehud ;; Comment headers changes (NOT GNU) ==ONLY== ;; ;; Revision 1.101 1996/02/19 10:53:34 ehud ;; Emacs 19.30 version (with changes for X windows) ;; ;; Revision 1.100 1995/01/19 17:23:54 ehud ;; SW initial version control for all el's ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation; either version 2 of the License, or ;; (at your option) any later version. ;; ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; ;; You should have received a copy of the GNU General Public License ;; along with this program; if not, write to the Free Software ;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA (defconst graphic-char-strng "\020³\100\000ijÀÁÙÃÅ´Ú¿Ä\040³\000\000ͳÔÏ¾ÆØµÕѸÍ\060º\020\000ͺÈʼÌιÉË»Í\100º\040\000ĺÓнÇ×¶ÖÒ·Ä\000Û\060\000ÜÛÛÜÛÝþÞÛßÛÜ" " Graphic characters (5 sets) use shift numric key-pad for entering 7 É 8 Ë 9 » shift pad - (minus) Í shift 4 Ì 5 Î 6 ¹ shift pad + (plus) º keypad 1 È 2 Ê 3 ¼ use pad -/+ to change graphic set ") (defvar graphic-set-no 0 "Graphic characters set number (0 to 4*16)") ;; moved to ekemacs ;; (or (eq system-type 'ms-dos) ;dont do for dos ;; (null xterm-on) ;dont do for non-x systems ;; (let ((1st 180) ;do ONLY for real X windows ;; (lst 223) ;; (rplc '((155 254) (124 189) (166 186) (124 179) (45 196) (61 205) (43 197 206 215 216))) ;; crp) ;sub list ;; (while (< 1st lst) ;; (aset standard-display-table 1st (vector 155)) ;; (setq 1st (1+ 1st))) ;; (while rplc ;; (setq crp (car rplc)) ;; (setq rplc (cdr rplc)) ;; (setq lst (car crp)) ;; (setq crp (cdr crp)) ;; (while crp ;; (setq 1st (car crp)) ;; (setq crp (cdr crp)) ;; (aset standard-display-table 1st (vector lst)))))) (defun graphic-insert () " Write graphic characters (5 sets). Use shift numric key-pad for entering graphic characters: 7 É 8 Ë 9 » shift pad - (minus) Í shift 4 Ì 5 Î 6 ¹ shift pad + (plus) º keypad 1 È 2 Ê 3 ¼ use pad -/+ to change graphic set" (interactive) (setq last-input-ehud (- (read-char) ?+)) (if (or (< last-input-ehud 0) (> last-input-ehud 15)) (setq last-input-ehud ? ) (setq last-input-ehud (aref graphic-char-strng (+ graphic-set-no last-input-ehud))) (if (< last-input-ehud 65) (progn (setq graphic-set-no last-input-ehud) (setq executing-kbd-macro nil) (setq graphic-string (format " %c%cG%c%c" (aref graphic-char-strng (+ graphic-set-no 9)) (aref graphic-char-strng (+ graphic-set-no 4)) (aref graphic-char-strng (+ graphic-set-no 4)) (aref graphic-char-strng (+ graphic-set-no 11)))) (force-mode-line-update) (message "%s%c%c%c%c%c" "Graphic set is " (aref graphic-char-strng (+ graphic-set-no 9)) (aref graphic-char-strng (+ graphic-set-no 4)) (aref graphic-char-strng (+ graphic-set-no 10)) (aref graphic-char-strng (+ graphic-set-no 4)) (aref graphic-char-strng (+ graphic-set-no 11)))) (self-insert-ehud-one)))) ;;================================= end of graphics.el ==================================