• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/emacs-92/emacs/lisp/international/

Lines Matching +defs:from +defs:encoding

1 ;;; ogonek.el --- change the encoding of Polish diacritics
38 "Change the encoding of Polish diacritic characters."
42 (defconst ogonek-name-encoding-alist
66 "The constant `ogonek-name-encoding-alist' is a list of (NAME.LIST) pairs.
116 `ogonek-name-encoding-alist'.
122 ogonek-from-encoding iso8859-2
123 ogonek-to-encoding ascii
125 ogonek-prefix-from-encoding iso8859-2
126 ogonek-prefix-to-encoding iso8859-2
132 (setq ogonek-prefix-to-encoding \"iso8859-2\")
181 The library provides functions for changing the encoding of Polish
191 currently used in your text and the target encoding, the one
197 (region-beginning) (region-end) from-code-name to-code-name)
198 (ogonek-recode-buffer from-code-name to-code-name)
204 (region-beginning) (region-end) from-code-name prefix-char)
205 (ogonek-prefixify-buffer from-code-name prefix-char)
216 is stored in the constant `ogonek-name-encoding-alist'.
222 ogonek-from-encoding iso8859-2
223 ogonek-to-encoding ascii
225 ogonek-prefix-from-encoding iso8859-2
226 ogonek-prefix-to-encoding iso8859-2
232 (setq ogonek-prefix-to-encoding \"iso8859-2\")
271 (defvar ogonek-encoding-choices
274 ogonek-name-encoding-alist))
276 (defcustom ogonek-from-encoding "iso8859-2"
278 :type ogonek-encoding-choices
280 (defcustom ogonek-to-encoding "ascii"
282 :type ogonek-encoding-choices
288 (defcustom ogonek-prefix-from-encoding "iso8859-2"
290 :type ogonek-encoding-choices
292 (defcustom ogonek-prefix-to-encoding "iso8859-2"
294 :type ogonek-encoding-choices
299 (defun ogonek-read-encoding (prompt default-name-var)
300 "Read encoding name with completion based on `ogonek-name-encoding-alist'.
303 (let ((encoding
306 ogonek-name-encoding-alist nil t)))
309 (if (string= encoding "") (eval default-name-var) encoding))
331 (defun ogonek-lookup-encoding (encoding)
332 "Pick up an association for ENCODING in `ogonek-name-encoding-alist'.
334 the list `ogonek-name-encoding-alist'"
335 (let ((code-list (assoc encoding ogonek-name-encoding-alist)))
337 (error "! Name `%s' not known in `ogonek-name-encoding-alist'"
338 encoding)
344 "Build a list of pairs from lists XS and YS of the same length."
376 (defun ogonek-recode-region (start end from-encoding to-encoding)
384 (ogonek-read-encoding "From code" 'ogonek-from-encoding)
385 (ogonek-read-encoding "To code" 'ogonek-to-encoding))))
391 (ogonek-lookup-encoding from-encoding)
392 (ogonek-lookup-encoding to-encoding))))))
394 (defun ogonek-recode-buffer (from-encoding to-encoding)
400 (ogonek-read-encoding "From code" 'ogonek-from-encoding)
401 (ogonek-read-encoding "To code" 'ogonek-to-encoding))))
403 (point-min) (point-max) from-encoding to-encoding))
410 (defun ogonek-prefixify-region (start end from-encoding prefix-char)
419 (ogonek-read-encoding "From code" 'ogonek-prefix-from-encoding)
422 ((from-code (ogonek-lookup-encoding from-encoding))
426 (cons prefix-char from-code)
442 (defun ogonek-prefixify-buffer (from-encoding prefix-char)
446 (ogonek-read-encoding "From code" 'ogonek-prefix-from-encoding)
449 (point-min) (point-max) from-encoding prefix-char))
451 (defun ogonek-deprefixify-region (start end prefix-char to-encoding)
453 PREFIX-CHAR followed by a Polish character from the `ogonek-prefix-code'
463 (ogonek-read-encoding
464 "To code" 'ogonek-prefix-to-encoding))))
466 ((from-code ogonek-prefix-code)
467 (to-code (ogonek-lookup-encoding to-encoding))
470 (cons prefix-char from-code)
493 (defun ogonek-deprefixify-buffer (prefix-char to-encoding)
498 (ogonek-read-encoding "To code" 'ogonek-prefix-to-encoding))))
500 (point-min) (point-max) prefix-char to-encoding))