/[emacs]/emacs/lisp/case-table.el
ViewVC logotype

Diff of /emacs/lisp/case-table.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.26.2.4 by fx, Sat Sep 7 23:54:43 2002 UTC revision 1.26.2.5 by handa, Tue Oct 1 01:33:07 2002 UTC
# Line 27  Line 27 
27    
28  ;;; Code:  ;;; Code:
29    
30  (defvar set-case-syntax-set-multibyte nil)  ;; Temporary workaround for loading latin-X.el.  They must bind this
31    ;; variable to a charset to convert code points to characters.
32    (defvar set-case-syntax-charset nil)
33    
34  (defun describe-buffer-case-table ()  (defun describe-buffer-case-table ()
35    "Describe the case table of the current buffer."    "Describe the case table of the current buffer."
# Line 64  Line 66 
66      (set-char-table-extra-slot copy 2 nil)      (set-char-table-extra-slot copy 2 nil)
67      copy))      copy))
68    
69    (defun set-case-syntax-1 (code)
70      (if (and (charsetp set-case-syntax-charset)
71               (< code 256))
72          (decode-char set-case-syntax-charset code)
73        code))
74    
75  (defun set-case-syntax-delims (l r table)  (defun set-case-syntax-delims (l r table)
76    "Make characters L and R a matching pair of non-case-converting delimiters.    "Make characters L and R a matching pair of non-case-converting delimiters.
77  This sets the entries for L and R in TABLE, which is a string  This sets the entries for L and R in TABLE, which is a string
78  that will be used as the downcase part of a case table.  that will be used as the downcase part of a case table.
79  It also modifies `standard-syntax-table' to  It also modifies `standard-syntax-table' to
80  indicate left and right delimiters."  indicate left and right delimiters."
81      (setq l (set-case-syntax-1 l))
82      (setq r (set-case-syntax-1 r))
83    (aset table l l)    (aset table l l)
84    (aset table r r)    (aset table r r)
85    ;; Clear out the extra slots so that they will be    ;; Clear out the extra slots so that they will be
# Line 88  This sets the entries for characters UC Line 98  This sets the entries for characters UC
98  that will be used as the downcase part of a case table.  that will be used as the downcase part of a case table.
99  It also modifies `standard-syntax-table' to give them the syntax of  It also modifies `standard-syntax-table' to give them the syntax of
100  word constituents."  word constituents."
101      (setq uc (set-case-syntax-1 uc))
102      (setq lc (set-case-syntax-1 lc))
103    (aset table uc lc)    (aset table uc lc)
104    (aset table lc lc)    (aset table lc lc)
105    (set-char-table-extra-slot table 0 nil)    (set-char-table-extra-slot table 0 nil)
# Line 102  This sets the entry for character C in T Line 114  This sets the entry for character C in T
114  that will be used as the downcase part of a case table.  that will be used as the downcase part of a case table.
115  It also modifies `standard-syntax-table'.  It also modifies `standard-syntax-table'.
116  SYNTAX should be \" \", \"w\", \".\" or \"_\"."  SYNTAX should be \" \", \"w\", \".\" or \"_\"."
117      (setq c (set-case-syntax-1 c))
118    (aset table c c)    (aset table c c)
119    (set-char-table-extra-slot table 0 nil)    (set-char-table-extra-slot table 0 nil)
120    (set-char-table-extra-slot table 1 nil)    (set-char-table-extra-slot table 1 nil)

Legend:
Removed from v.1.26.2.4  
changed lines
  Added in v.1.26.2.5

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26