From: Meekohi <meekohi@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Special font for lines with suffix
Date: Mon, 28 Dec 2009 11:53:11 -0800 (PST) [thread overview]
Message-ID: <21db7314-b3eb-4424-8863-d3f4e4e861f1@c3g2000yqd.googlegroups.com> (raw)
In-Reply-To: 87637r1g3j.fsf@hubble.informatimago.com
On Dec 28, 6:40 am, p...@informatimago.com (Pascal J. Bourguignon)
wrote:
> Meekohi <meek...@gmail.com> writes:
> > When debugging code, I tend to put in hacks, and then I forget to take
> > them out later. What I'd like is to be able to end a line with "//!"
> > or something similar and have emacs increase the font-size (or
> > something similar) to make it stand out visually. I don't know how to
> > get started. Any advice or recommendations on how to accomplish this?
>
> I would try:
>
> (font-lock-add-keywords nil '("^.*//!.*" 0 font-lock-warning-face prepend))
>
> --
> __Pascal Bourguignon__ http://www.informatimago.com/
Hi Pascal thanks so much that is perfect :) For any interested users
that come along later, I ended up specifically using:
(add-hook 'c++-mode-hook (lambda () (font-lock-add-keywords nil
'(("//!.*" 0 font-lock-warning-face t)))))
because highlighting the whole line turned out to be very distracting.
prev parent reply other threads:[~2009-12-28 19:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-28 2:25 Special font for lines with suffix Meekohi
2009-12-28 11:40 ` Pascal J. Bourguignon
2009-12-28 19:53 ` Meekohi [this message]
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=21db7314-b3eb-4424-8863-d3f4e4e861f1@c3g2000yqd.googlegroups.com \
--to=meekohi@gmail.com \
--cc=help-gnu-emacs@gnu.org \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.