diff options
| author | Eli Zaretskii | 2022-03-10 09:29:29 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2022-03-10 09:29:29 +0200 |
| commit | a9920473f68ce20fe95f67a4941ff3c1fb274f2a (patch) | |
| tree | a02bd6b369ba73b4ff5395810967ccd32b498e18 /src | |
| parent | d184773c2e2a69bea9b96190c83727b4e7a16542 (diff) | |
| download | emacs-a9920473f68ce20fe95f67a4941ff3c1fb274f2a.tar.gz emacs-a9920473f68ce20fe95f67a4941ff3c1fb274f2a.zip | |
Improve documentation of 'map-charset-chars'
* doc/lispref/nonascii.texi (Character Sets):
* src/charset.c (Fmap_charset_chars): Clarify the codepoint issue
in using 'map-charset-chars'.
Diffstat (limited to 'src')
| -rw-r--r-- | src/charset.c | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/src/charset.c b/src/charset.c index dec9d56df2c..b9e1584083f 100644 --- a/src/charset.c +++ b/src/charset.c | |||
| @@ -793,16 +793,21 @@ map_charset_chars (void (*c_function)(Lisp_Object, Lisp_Object), Lisp_Object fun | |||
| 793 | 793 | ||
| 794 | DEFUN ("map-charset-chars", Fmap_charset_chars, Smap_charset_chars, 2, 5, 0, | 794 | DEFUN ("map-charset-chars", Fmap_charset_chars, Smap_charset_chars, 2, 5, 0, |
| 795 | doc: /* Call FUNCTION for all characters in CHARSET. | 795 | doc: /* Call FUNCTION for all characters in CHARSET. |
| 796 | FUNCTION is called with an argument RANGE and the optional 3rd | 796 | Optional 3rd argument ARG is an additional argument to be passed |
| 797 | argument ARG. | 797 | to FUNCTION, see below. |
| 798 | 798 | Optional 4th and 5th arguments FROM-CODE and TO-CODE specify the | |
| 799 | RANGE is a cons (FROM . TO), where FROM and TO indicate a range of | 799 | range of code points (in CHARSET) of target characters on which to |
| 800 | characters contained in CHARSET. | 800 | map the FUNCTION. Note that these are not character codes, but code |
| 801 | 801 | points of CHARSET; for the difference see `decode-char' and | |
| 802 | The optional 4th and 5th arguments FROM-CODE and TO-CODE specify the | 802 | `list-charset-chars'. If FROM-CODE is nil or imitted, it stands for |
| 803 | range of code points (in CHARSET) of target characters. Note that | 803 | the first code point of CHARSET; if TO-CODE is nil or omitted, it |
| 804 | these are not character codes, but code points in CHARSET; for the | 804 | stands for the last code point of CHARSET. |
| 805 | difference see `decode-char' and `list-charset-chars'. */) | 805 | |
| 806 | FUNCTION will be called with two arguments: RANGE and ARG. | ||
| 807 | RANGE is a cons (FROM . TO), where FROM and TO specify a range of | ||
| 808 | characters that belong to CHARSET on which FUNCTION should do its | ||
| 809 | job. FROM and TO are Emacs character codes, unlike FROM-CODE and | ||
| 810 | TO-CODE, which are CHARSET code points. */) | ||
| 806 | (Lisp_Object function, Lisp_Object charset, Lisp_Object arg, Lisp_Object from_code, Lisp_Object to_code) | 811 | (Lisp_Object function, Lisp_Object charset, Lisp_Object arg, Lisp_Object from_code, Lisp_Object to_code) |
| 807 | { | 812 | { |
| 808 | struct charset *cs; | 813 | struct charset *cs; |