unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: brakjoller@hotmail.com (Barman Brakjoller)
Subject: Re: How do I setup an extremely simple font-lock mode?
Date: 23 May 2003 06:50:30 -0700	[thread overview]
Message-ID: <1c58a7c3.0305230550.3352edcb@posting.google.com> (raw)
In-Reply-To: mailman.6601.1053636524.21513.help-gnu-emacs@gnu.org

> I want to setup a very simple mode for colorizing a log file.  All I 
> need to do is highlight any lines with the string ERROR on them.  I've 
> tried reading the documentation for font-lock but it's not clear how to 
> do this.

Maybe this is not exacly what you asked for,  but to me it seems as if
it will solve your problem. From the NEWS file, section Emacs 21.1
changes:

  *** The new package hi-lock.el provides commands to highlight
matches
  of interactively entered regexps.  For example,

   M-x highlight-regexp RET clearly RET RET

  will highlight all occurrences of `clearly' using a yellow
background
  face.  New occurrences of `clearly' will be highlighted as they are
  typed.  `M-x unhighlight-regexp RET' will remove the highlighting.
  Any existing face can be used for highlighting and a set of
  appropriate faces is provided.  The regexps can be written into the
  current buffer in a form that will be recognized the next time the
  corresponding file is read.  There are commands to highlight matches
  to phrases and to highlight entire lines containing a match.

Hope it works for you!

  parent reply	other threads:[~2003-05-23 13:50 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.6601.1053636524.21513.help-gnu-emacs@gnu.org>
2003-05-22 23:58 ` How do I setup an extremely simple font-lock mode? Alex Schroeder
2003-05-23 13:50 ` Barman Brakjoller [this message]
2003-05-23 15:02 ` kgold
2003-05-23 15:24   ` Bryan W. Lepore
     [not found] <mailman.6614.1053651042.21513.help-gnu-emacs@gnu.org>
2003-05-23 15:03 ` Stefan Monnier
2003-05-23 15:05   ` Stefan Monnier
2003-05-22 20:47 Matt Noel
2003-05-22 21:11 ` myrkraverk
2003-05-23  0:48   ` Matt Noel

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=1c58a7c3.0305230550.3352edcb@posting.google.com \
    --to=brakjoller@hotmail.com \
    /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).