Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: [WT] Perl mode in mixed emacs buffer

by mugwumpjism (Hermit)
on Jul 19, 2005 at 04:19 UTC ( [id://475960]=note: print w/replies, xml ) Need Help??


in reply to [WT] Perl mode in mixed emacs buffer

You probably want mmm-mode

Install and load the mmm-mode library, then use the mmm-ify-by-regexp command to turn it on for a buffer. Set to a hotkey or something if you want to be able to do it quickly after you load a file.

Eg, one I used for Parse::ePerl:

(mmm-ify-by-regexp 'cperl-mode "<[\?]" 0 "[\?][\>]" 0 2)
$h=$ENV{HOME};my@q=split/\n\n/,`cat $h/.quotes`;$s="$h/." ."signature";$t=`cat $s`;print$t,"\n",$q[rand($#q)],"\n";

Replies are listed 'Best First'.
Re^2: [WT] Perl mode in mixed emacs buffer
by monarch (Priest) on Jul 19, 2005 at 06:08 UTC
    I second the mmm-mode. It works for Perl-mason as well as javascript embedded in HTML.

    Take time to read the documentation, though, cause there's a lot you can do with mmm-mode but, as with all things Emacs, can take a fair bit of learning to take full control of..

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://475960]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (3)
As of 2024-03-29 06:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found