From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yi Wang Subject: Re: Babel language support for Mathematica Date: Thu, 9 Jan 2014 11:49:24 +0000 Message-ID: References: <87ha9dwisd.fsf@bzg.ath.cx> <87sisxtoer.fsf@bzg.ath.cx> <87bnzltnhu.fsf@bzg.ath.cx> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7b2e46f0749a0b04ef88338d Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60381) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W1E74-0001FR-Pv for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 06:49:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W1E73-0006qg-Jc for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 06:49:26 -0500 Received: from mail-oa0-x236.google.com ([2607:f8b0:4003:c02::236]:33021) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W1E73-0006qZ-AV for emacs-orgmode@gnu.org; Thu, 09 Jan 2014 06:49:25 -0500 Received: by mail-oa0-f54.google.com with SMTP id o6so3302183oag.27 for ; Thu, 09 Jan 2014 03:49:24 -0800 (PST) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Bastien Cc: emacs-orgmode@gnu.org --047d7b2e46f0749a0b04ef88338d Content-Type: text/plain; charset=ISO-8859-1 Now it worked. I added (add-to-list 'org-src-lang-modes '("mathematica" . "mma")). After that font lock and edit source works. Thank @Bastien for the help! On Thu, Jan 9, 2014 at 11:31 AM, Yi Wang wrote: > Ah, now the problem appears. It says "No such language mode: > mathematica-mode". > > So there is a mismatch between the name mathematica (which I used as name > in org-babel extension) and the name mma-mode (which is provided by > mma.el). > > However, as auto-mode-alist suggests (where there is ("\\.m\\'" . > mma-mode), and no entry with mathematica-mode), I still have no idea > why org-edit-special looks for mathematica-mode instead of mma-mode. > > > On Thu, Jan 9, 2014 at 11:15 AM, Bastien wrote: > >> Yi Wang writes: >> >> > (1) If I open a .m file, there is font lock. Thus the problem >> > shouldn't be binding between mma.el and .m files. >> > (2) If I insert a src block of C or python code in org mode, there is >> > font lock. Thus the problem shouldn't be org-src-fontify-natively >> > (and I checked it is indeed t). >> >> What happen if you C-c ' on a .m block? >> >> -- >> Bastien >> > > --047d7b2e46f0749a0b04ef88338d Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Now it worked. I added=A0(add-to-list 'org-src-lang-mo= des '("mathematica" . "mma")). After that font lock= and edit source works. Thank @Bastien for the help!


On Thu, Jan 9, 2014 at 11:31 AM, Yi Wang= <tririverwangyi@gmail.com> wrote:
Ah, now the problem appears. It says "No such languag= e mode: mathematica-mode".

So there is a mismatch b= etween the name mathematica (which I used as name in org-babel extension) a= nd the name mma-mode (which is provided by mma.el).=A0

However, as=A0auto-mode-alist suggests (where there is = ("\\.m\\'" . mma-mode), and no entry with mathematica-mode), = I still have no idea why=A0org-edit-special looks for mathematica-mode inst= ead of mma-mode.

On Thu, Jan 9, 2014 at 11:15 AM, Bastien <= span dir=3D"ltr"><bz= g@altern.org> wrote:
Yi Wang <tririverwangyi@gmail.com> writes:

> (1) If I open a .m file, there is font lock. Thus the problem
> shouldn't be binding between mma.el and .m files.
> (2) If I insert a src block of C or python code in org mode, there is<= br> > font lock. Thus the problem shouldn't be=A0org-src-fontify-nativel= y
> (and I checked it is indeed t).

What happen if you C-c ' on a .m block?

--
=A0Bastien


--047d7b2e46f0749a0b04ef88338d--