30 |
|
|
31 |
;;; Code: |
;;; Code: |
32 |
|
|
33 |
(eval-when-compile (defvar dos-codepage)) |
(eval-when-compile |
34 |
|
(defvar dos-codepage) |
35 |
|
(require 'wid-edit)) |
36 |
|
|
37 |
;;; MULE related key bindings and menus. |
;;; MULE related key bindings and menus. |
38 |
|
|
1931 |
(cdr element))) |
(cdr element))) |
1932 |
|
|
1933 |
(defun locale-charset-match-p (charset1 charset2) |
(defun locale-charset-match-p (charset1 charset2) |
1934 |
"Whether charset names CHARSET1 and CHARSET2 are equivalent. |
"Whether charset names (strings) CHARSET1 and CHARSET2 are equivalent. |
1935 |
Matching is done ignoring case and any hyphens and underscores in the |
Matching is done ignoring case and any hyphens and underscores in the |
1936 |
names. E.g. `ISO_8859-1' and `iso88591' both match `iso-8859-1'." |
names. E.g. `ISO_8859-1' and `iso88591' both match `iso-8859-1'." |
1937 |
(setq charset1 (replace-regexp-in-string "[-_]" "" charset1)) |
(setq charset1 (replace-regexp-in-string "[-_]" "" charset1)) |
2053 |
(let ((codeset (langinfo 'codeset)) |
(let ((codeset (langinfo 'codeset)) |
2054 |
(coding-system (car (coding-system-priority-list)))) |
(coding-system (car (coding-system-priority-list)))) |
2055 |
(when codeset |
(when codeset |
2056 |
(unless (locale-charset-match-p (symbol-name coding-system) |
(let ((cs (coding-system-aliases coding-system)) |
2057 |
(langinfo 'codeset)) |
result) |
2058 |
(message "Warning: Default coding system `%s' doesn't agree with |
(while (and cs (not result)) |
2059 |
the system code set `%s' for this locale." coding-system codeset)))))))) |
(setq result |
2060 |
|
(locale-charset-match-p (symbol-name (pop cs)) |
2061 |
|
(langinfo 'codeset)))) |
2062 |
|
(unless result |
2063 |
|
(message "Warning: Default coding system `%s' doesn't agree with |
2064 |
|
the system code set `%s' for this locale." coding-system codeset))))))))) |
2065 |
|
|
2066 |
;;; Character code property |
;;; Character code property |
2067 |
(put 'char-code-property-table 'char-table-extra-slots 0) |
(put 'char-code-property-table 'char-table-extra-slots 0) |