emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: text-texi - Node: Text Properties - After first paragraph


From: Drew Adams
Subject: RE: text-texi - Node: Text Properties - After first paragraph
Date: Tue, 4 Jul 2006 09:57:31 -0700

    As users probably first encounter the terminus `face' in this
    context, it might be helpful to give just one sentence here
    concerning the relation between `properties' and `faces'.

    So I conceive properties as the most fundamental category,
    whereas faces are of higher order, a more combined and complex
    one.

    Right or wrong?

I'm no expert on this - here is my understanding -

There is a `face' text property and a `face' overlay property. Its value is
one or more faces or a list of face attributes. So, you could say that a
face is more fundamental than a text property, in that it can be used to
define the value of a text `face' property (or an overlay `face' property,
or even a text `mouse-face' property). However, you need not use a face to
define a text `face' property - you can directly define the text `face'
property using a face attribute list (not associated with any defined face).

Also, text properties are not limited to the `face' property. In this sense,
the notion of text property might be considered more fundamental, or at
least more general, than the notion of face.

It is probably more correct to start with face attributes as the basic
building blocks. They are used to define faces or text `face' property
values or overlay `face' property values. Faces can also be used to define
both kinds of `face' property value.

I don't think it is useful to consider either faces or text properties as
more fundamental than the other. They are both users of face attributes.
When faces are used to define the text `face' property value, they can be
thought of as an intermediary - it is the attributes of the faces that
really define the text property.

In any case, these various critters need to be distinguished clearly in the
doc: faces, text properties (including `face'), and overlay properties
(including `face'). I imagine that they are, but I don't have time now to
check.

If these distinctions are not pointed out somewhere, then they should be.
The notion of text property needs to pointed out in the Emacs manual also,
because it is used in the UI. End users, not just Lisp programmers, need to
be aware of the terminology (face, text property).

I don't see the text you reference, however. In node (elisp) Text Properties
I see no occurrence of either "face" or "Terminus". And I'm not sure we
could (or should try to) convey the relation between faces and text
properties in a single sentence.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]