[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: tutorial on faces ?
From: |
Drew Adams |
Subject: |
RE: tutorial on faces ? |
Date: |
Wed, 6 Feb 2019 08:45:20 -0800 (PST) |
> Well, I'm tweaking poker.el at the moment and I'm looking for ways to
> apply style to some parts of the messages.
>
> Honestly, the elisp manual gives me no idea how to do that...
OK, good. But what do you mean by "style"?
Do you mean that you want to apply a face to some
parts of some messages?
If so:
1. Do you want to apply the face to the buffer
_positions_ of those msg parts, as an _overlay_
property, or do you want to apply it to the
_characters_ of those msg parts, as a _text_
property?
2. Are those message parts recognizable/definable
in a regular way, i.e., as something that you
can define using one or more regexps? And do
you want the face highlighting to be
automatically reapplied to those parts when
the same text is visited anew (in the same
mode), e.g. in a new Emacs session or after
reverting the buffer?
If the answer is yes then look at using
`font-lock-mode' to define and highlight those
parts. If the answer is no then maybe look
at using ad hoc highlighting, such as you get
with library `highlight.el':
https://www.emacswiki.org/emacs/HighlightLibrary
Knowing the answers to these, and perhaps other,
questions might help you direct your search for
tutorials (e.g. whether to look for tutorials
that involve font-lock highlighting).
The more you can specify about what you're
interested in, the more helpful people and search
can be.
- tutorial on faces ?, Jean-Christophe Helary, 2019/02/06
- RE: tutorial on faces ?, Drew Adams, 2019/02/06
- Re: tutorial on faces ?, Jean-Christophe Helary, 2019/02/06
- RE: tutorial on faces ?,
Drew Adams <=
- Re: tutorial on faces ?, Jean-Christophe Helary, 2019/02/07
- RE: tutorial on faces ?, Drew Adams, 2019/02/07
- Re: tutorial on faces ?, Jean-Christophe Helary, 2019/02/07
- RE: tutorial on faces ?, Drew Adams, 2019/02/07
- Re: tutorial on faces ?, Jean-Christophe Helary, 2019/02/07
- RE: tutorial on faces ?, Drew Adams, 2019/02/07