Mercurial > hg > xemacs-beta
comparison lisp/disp-table.el @ 5113:b2dcf6a6d8ab
some changes to doc strings/comments in disp-table.el
-------------------- ChangeLog entries follow: --------------------
lisp/ChangeLog addition:
2010-03-07 Ben Wing <ben@xemacs.org>
* disp-table.el:
* disp-table.el (standard-display-g1):
* disp-table.el (standard-display-graphic):
Fix up docs; add comments about authorship.
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Sun, 07 Mar 2010 06:43:19 -0600 |
parents | 1f0aa40cafe0 |
children | e84ee15ca495 |
comparison
equal
deleted
inserted
replaced
5112:ba80cff33640 | 5113:b2dcf6a6d8ab |
---|---|
1 ;;; disp-table.el --- functions for dealing with char tables. | 1 ;;; disp-table.el --- functions for dealing with char tables. |
2 | 2 |
3 ;; Copyright (C) 1987, 1994, 1997, 2007 Free Software Foundation, Inc. | 3 ;; Copyright (C) 1987, 1994, 1997, 2007 Free Software Foundation, Inc. |
4 ;; Copyright (C) 1995 Sun Microsystems. | 4 ;; Copyright (C) 1995 Sun Microsystems. |
5 | 5 ;; Copyright (C) 2005 Ben Wing. |
6 ;; Author: Howard Gayle | 6 |
7 ;; Maintainer: XEmacs Development Team | 7 ;; Maintainer: XEmacs Development Team |
8 ;; Keywords: i18n, internal | 8 ;; Keywords: i18n, internal |
9 | 9 |
10 ;; This file is part of XEmacs. | 10 ;; This file is part of XEmacs. |
11 | 11 |
27 ;;; Synched up with: Not synched with FSF. | 27 ;;; Synched up with: Not synched with FSF. |
28 | 28 |
29 ;;; Commentary: | 29 ;;; Commentary: |
30 | 30 |
31 ;; Rewritten for XEmacs July 1995, Ben Wing. | 31 ;; Rewritten for XEmacs July 1995, Ben Wing. |
32 | 32 ;; November 1998?, display tables generalized to char/range tables, Hrvoje |
33 ;; Niksic. | |
34 ;; July 2007, rewrite this file to handle generalized display tables, | |
35 ;; Aidan Kehoe. | |
33 | 36 |
34 ;;; Code: | 37 ;;; Code: |
35 | 38 |
36 ;;;###autoload | 39 ;;;###autoload |
37 (defun make-display-table () | 40 (defun make-display-table () |
114 ;; #### we need a generic frob-specifier function. | 117 ;; #### we need a generic frob-specifier function. |
115 ;; #### this also needs to be redone like frob-face-property. | 118 ;; #### this also needs to be redone like frob-face-property. |
116 | 119 |
117 ;; Let me say one more time how much dynamic scoping sucks. | 120 ;; Let me say one more time how much dynamic scoping sucks. |
118 | 121 |
122 ;; #### Need more thinking about basic primitives for modifying a specifier. | |
123 ;; cf `modify-specifier-instances'. | |
124 | |
119 ;;;###autoload | 125 ;;;###autoload |
120 (defun frob-display-table (fdt-function fdt-locale &optional tag-set) | 126 (defun frob-display-table (fdt-function fdt-locale &optional tag-set) |
121 (or fdt-locale (setq fdt-locale 'global)) | 127 (or fdt-locale (setq fdt-locale 'global)) |
122 (or (specifier-spec-list current-display-table fdt-locale tag-set) | 128 (or (specifier-spec-list current-display-table fdt-locale tag-set) |
123 (add-spec-to-specifier current-display-table (make-display-table) | 129 (add-spec-to-specifier current-display-table (make-display-table) |
182 locale)) | 188 locale)) |
183 | 189 |
184 ;;;###autoload | 190 ;;;###autoload |
185 (defun standard-display-g1 (c sc &optional locale) | 191 (defun standard-display-g1 (c sc &optional locale) |
186 "Display character C as character SC in the g1 character set. | 192 "Display character C as character SC in the g1 character set. |
187 This function assumes that your terminal uses the SO/SI characters; | 193 This only has an effect on TTY devices and assumes that your terminal uses |
188 it is meaningless for an X frame." | 194 the SO/SI characters." |
189 (frob-display-table | 195 (frob-display-table |
190 (lambda (x) | 196 (lambda (x) |
191 (put-char-table c (concat "\016" (char-to-string sc) "\017") x)) | 197 (put-char-table c (concat "\016" (char-to-string sc) "\017") x)) |
192 locale '(tty))) | 198 locale '(tty))) |
193 | 199 |
194 ;;;###autoload | 200 ;;;###autoload |
195 (defun standard-display-graphic (c gc &optional locale) | 201 (defun standard-display-graphic (c gc &optional locale) |
196 "Display character C as character GC in graphics character set. | 202 "Display character C as character GC in graphics character set. |
197 This function assumes VT100-compatible escapes; it is meaningless for an | 203 This only has an effect on TTY devices and assumes VT100-compatible escapes." |
198 X frame." | |
199 (frob-display-table | 204 (frob-display-table |
200 (lambda (x) | 205 (lambda (x) |
201 (put-char-table c (concat "\e(0" (char-to-string gc) "\e(B") x)) | 206 (put-char-table c (concat "\e(0" (char-to-string gc) "\e(B") x)) |
202 locale '(tty))) | 207 locale '(tty))) |
203 | 208 |