unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Yuri Khan <yuri.v.khan@gmail.com>
To: uzibalqa <uzibalqa@proton.me>
Cc: uzibalqa via Users list for the GNU Emacs text editor
	<help-gnu-emacs@gnu.org>
Subject: Re: Changing foreground colours for outline-minor-mode
Date: Mon, 19 Jun 2023 22:53:39 +0700	[thread overview]
Message-ID: <CAP_d_8V7tiHc+Rd7iUg=ALqBOEiugZ2GQaMRZaYP4qxPbKGxSQ@mail.gmail.com> (raw)
In-Reply-To: <aYd_IdDbTPpJNcb2kxgTcUs3RsnAdaTjCHU1qdR15ZNC902LvvSldV4iL7ZJrXYJCzvY72CIObovjU8j_h76nZWINw_pk8ZrICPfj9jIzO0=@proton.me>

On Mon, 19 Jun 2023 at 19:21, uzibalqa <uzibalqa@proton.me> wrote:

> Having changed outline-regexp to accept ";;; H1" ";;; H2", ... as outline headers,
> I also want to change the foreground colours at the different heading levels.
>
> (defvar hglevels
>   '( (";;; H1" . 1) (";;; H2" . 2) (";;; H3" . 3) (";;; H4" . 4)
>      (";;; H5" . 5) (";;; H6" . 6) (";;; H7" . 7) (";;; H8" . 8) ))
>
> (setq outline-heading-alist hglevels)
>
> But I do not see the foreground colours taking effect.

Have you customized the outline-minor-mode-highlight variable? Have
you tried each of its possible values? After changing the variable,
did you re-activate outline-minor-mode?

(Also, what you’re trying to do is misguided, and if you’re doing that
as a library as you’ve hinted in other messages, then you’re harming
your users. For one thing, your modified patterns are suitable only
for languages that treat a semicolon as a comment starter, such as
Lisp; if applied indiscriminately to other languages, users will not
be able to add headings without breaking their language’s syntax.)

(Also, when you think of a possible improvement to a question that
you’ve asked earlier but that hadn’t received a reply, you should post
your improvement as a reply to that past question, not as a new
separate thread. That helps people review all the things you’ve said
in previous versions of the question.)



  reply	other threads:[~2023-06-19 15:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-19 12:20 Changing foreground colours for outline-minor-mode uzibalqa
2023-06-19 15:53 ` Yuri Khan [this message]
2023-06-19 16:06   ` uzibalqa
2023-06-19 16:25     ` Yuri Khan
2023-06-19 16:55       ` uzibalqa

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to='CAP_d_8V7tiHc+Rd7iUg=ALqBOEiugZ2GQaMRZaYP4qxPbKGxSQ@mail.gmail.com' \
    --to=yuri.v.khan@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=uzibalqa@proton.me \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).