[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Graying out the code in "#if 0/#endif" brace?

From: Zhou Ping
Subject: Re: Graying out the code in "#if 0/#endif" brace?
Date: Wed, 23 Jun 2004 10:00:29 +0800

Thank you! I'm not familiar with emacs/LISP programming, do you know any sample code for reference?

Best regards,
Zhou Ping.

= = = Original message = = =

"ZP" == Zhou Ping <address@hidden> writes:

ZP> Hello all,
ZP> I noticed that vim can use different color on the code enclosed in an "#if ZP> 0/#endif" directive brace. This is very useful for code editing or reading. ZP> I wonder if emacs has this kind of feature? If so, how can I add/enable it?
ZP> Thanks.

I don't think emacs has this but it's possible to add it, even if I have
some trouble doing something like in another mode I mantain.

The trick is to define #if[ ^I]+0 as a syntactic keyword and write a piece
of code that skips everithyng up to the #endif...

/\            ___
/___/\__|_|\_|__|___Gian Uberto Lauri_____________________
 //--\ | | \|  |   Integralista GNUslamico e fancazzista

Sent by ePrompter, the premier email notification software.
Free download at

Protect your PC - get VirusScan Online

reply via email to

[Prev in Thread] Current Thread [Next in Thread]