all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Re: mixed language mode (Python + C)?
       [not found] <aeb0031a-594e-4428-aa46-449442f8b877@i31g2000yqm.googlegroups.com>
@ 2010-07-07 14:42 ` Xah Lee
  2010-07-07 17:09 ` unfrostedpoptart
  1 sibling, 0 replies; 2+ messages in thread
From: Xah Lee @ 2010-07-07 14:42 UTC (permalink / raw)
  To: help-gnu-emacs

On Jul 7, 5:23 am, Tom <tmb...@gmail.com> wrote:
> With tools like Python and Weave, some of my source files now contain
> mixed Python and C code.
>
> Is there some mode or support for having multiple language support in
> the same buffer?  Ideal would be something that actually just switches
> completely transparently, but even something that lets me narrow to a
> Python string and edit that in C mode would be useful.
>
> Of course, if it helps, I could indicate which language something is
> in with comments similar to those found at the top of files.

there were several packages that make this happen, variously named
multi mu ma or something like that. From what i've reead on the wiki
or here, i never attempted to install them because they are too
complex.

the thing is that emacs's syntax coloring system wasn't designed for
multi-langs in a single page, pretty much needed today for html/css/js/
asp/php.

you might check the emacswiki and try those packages.

what i typically do is to assign a key shortcut to switch me to say
html mode, and another for css mode. So, when i want to work on html
section, press f6, and when in js section i press f7, etc.

 Xah


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: mixed language mode (Python + C)?
       [not found] <aeb0031a-594e-4428-aa46-449442f8b877@i31g2000yqm.googlegroups.com>
  2010-07-07 14:42 ` mixed language mode (Python + C)? Xah Lee
@ 2010-07-07 17:09 ` unfrostedpoptart
  1 sibling, 0 replies; 2+ messages in thread
From: unfrostedpoptart @ 2010-07-07 17:09 UTC (permalink / raw)
  To: help-gnu-emacs

On Jul 7, 5:23 am, Tom <tmb...@gmail.com> wrote:
> With tools like Python and Weave, some of my source files now contain
> mixed Python and C code.
>
> Is there some mode or support for having multiple language support in
> the same buffer?  Ideal would be something that actually just switches
> completely transparently, but even something that lets me narrow to a
> Python string and edit that in C mode would be useful.
>
> Of course, if it helps, I could indicate which language something is
> in with comments similar to those found at the top of files.

This would be great. I"m often editing Verilog files that also contain
c pre-processor code.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-07-07 17:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <aeb0031a-594e-4428-aa46-449442f8b877@i31g2000yqm.googlegroups.com>
2010-07-07 14:42 ` mixed language mode (Python + C)? Xah Lee
2010-07-07 17:09 ` unfrostedpoptart

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.