unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Bert Geens <bert@lair.be>
Subject: Re: Case insensitive font-lock
Date: Sun, 21 Aug 2005 21:26:40 +0200	[thread overview]
Message-ID: <pan.2005.08.21.19.26.40.145982@lair.be> (raw)
In-Reply-To: mailman.3832.1124126878.20277.help-gnu-emacs@gnu.org

On Mon, 15 Aug 2005 11:08:02 -0600, Kevin Rodgers wrote:

> Bert Geens wrote:
>  > I'm writing a major mode (http://www.lair.be/projects_fvwm-mode.php) for
>  > the Fvwm window manager, now as Fvwm's keywords are case insensitive 
> I was
>  > wondering if there is an easy way to make font lock ignore the casing of
>  > the keywords.
> 
> ,----[ C-h v font-lock-keywords-case-fold-search RET ]
<snip>
> `----

Thanks a lot, i had looked at font-lock-defaults but apparently not hard
enough...

So I tried this:
(set (make-local-variable 'font-lock-defaults) '(fvwm-font-lock-keywords
nil fvwm-keywords-ignore-case))
But that apparently didn't  work, I wonder why?

I now use this, which does work though, but the above solution would be
cleaner imho...

  (if fvwm-keywords-ignore-case
      (set (make-local-variable 'font-lock-defaults) '(fvwm-font-lock-keywords))
    (set (make-local-variable 'font-lock-defaults)
    '(fvwm-font-lock-keywords nil t)))

Cheers

Bert

  parent reply	other threads:[~2005-08-21 19:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-08-14 19:38 Case insensitive font-lock Bert Geens
2005-08-15 17:08 ` Kevin Rodgers
     [not found] ` <mailman.3832.1124126878.20277.help-gnu-emacs@gnu.org>
2005-08-21 19:26   ` Bert Geens [this message]
2005-08-22 19:09     ` Kevin Rodgers
     [not found]     ` <mailman.4675.1124740027.20277.help-gnu-emacs@gnu.org>
2005-08-27 18:23       ` Bert Geens

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=pan.2005.08.21.19.26.40.145982@lair.be \
    --to=bert@lair.be \
    /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).