aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero <[email protected]>2002-11-05 10:42:25 +0000
committerJuanma Barranquero <[email protected]>2002-11-05 10:42:25 +0000
commit2e729bfaa60159556e81ceca36548f9206f2fe26 (patch)
treeaac19585bc9a70766bcac57011d22d97e28e9157
parente8bee05279989008eabfc7f64a4d01f2a68de8bf (diff)
(coding-system-eol-type-mnemonic): Move from mule-util.el.
-rw-r--r--lisp/international/mule.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/international/mule.el b/lisp/international/mule.el
index 0719a2b2ec..f325c60b80 100644
--- a/lisp/international/mule.el
+++ b/lisp/international/mule.el
@@ -513,6 +513,18 @@ detected automatically. Nth element of the vector is the subsidiary
coding system whose eol-type is N."
(get coding-system 'eol-type))
+(defun coding-system-eol-type-mnemonic (coding-system)
+ "Return the string indicating end-of-line format of CODING-SYSTEM."
+ (let* ((eol-type (coding-system-eol-type coding-system))
+ (val (cond ((vectorp eol-type) eol-mnemonic-undecided)
+ ((eq eol-type 0) eol-mnemonic-unix)
+ ((eq eol-type 1) eol-mnemonic-dos)
+ ((eq eol-type 2) eol-mnemonic-mac)
+ (t "-"))))
+ (if (stringp val)
+ val
+ (char-to-string val))))
+
(defun coding-system-lessp (x y)
(cond ((eq x 'no-conversion) t)
((eq y 'no-conversion) nil)