all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: emacs-devel@gnu.org
Subject: char properties vs char properties: two different meanings
Date: Wed, 11 Sep 2013 10:18:42 -0700 (PDT)	[thread overview]
Message-ID: <b4084aa4-30c2-440f-87ea-eace2651c219@default> (raw)

Not sure what a good solution might be, but we have a terminology problem:
there are two completely different notions of "character property" used
in Emacs Lisp:

1. A character property is either a text property or an overlay property.
   It is what function `get-char-property' returns.  It is good to have
   a term that covers both.  I use it in doc for functions I have that
   act on either, for instance.

2. A character property is a named attribute of a character...
   See (elisp) `Character Properties'.

#2 was added to our doc in Emacs 23.  It is terminology that comes from
outside Emacs (from Unicode).

Both are useful, each makes sense and is a good name for what it means.
But the two have nothing to do with each other.

Perhaps nothing should be done about the different meanings, and context
alone can be used to indicate which is meant.  Dunno.  Or perhaps someone
has a great suggestion, e.g., an alternative term for #1?   (We certainly
should not try to change #2 for Emacs, in any case.)

If we keep the same name for both meanings then perhaps the doc should at
least point out that the term is used in Emacs in two different ways.

It might also help to change the name of the manual node for #2, so that
someone using `g' to find info about #1 won't be misled.  But since #2
is not limited to Unicode character properties in Emacs I can't think of
a better node name offhand.  I.e., it would not be accurate to name the
node, say, `Unicode Character Properties' (which would help users looking
for #1 avoid this node).

One possibility that occurs to me is to take a suggestion from the function
names.  For #1 we have function `get-char-property'.  For #2 we have
`get-char-code-property'.  So perhaps we could, at least in the node name
for #2, for example, change `Character Properties' to `Character Code
Properties'.

Is "character code property" accurate?  If so, then we could also change
the text to use the same name: "character code property" instead of
"character property". If it is not really accurate then perhaps it would
still be OK (& helpful) to rename the node, but to use the proper
terminology in the explanation (node text).



             reply	other threads:[~2013-09-11 17:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-11 17:18 Drew Adams [this message]
2013-09-11 19:31 ` char properties vs char properties: two different meanings Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b4084aa4-30c2-440f-87ea-eace2651c219@default \
    --to=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.