all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Tassilo Horn <tassilo@member.fsf.org>
To: help-gnu-emacs@gnu.org
Subject: Re: org-mode source blocks
Date: Tue, 21 Dec 2010 17:36:20 +0100	[thread overview]
Message-ID: <87pqsvw0aj.fsf@member.fsf.org> (raw)
In-Reply-To: 87hbe779hl.fsf@gmail.com

marcowahl@gmail.com (Marco (m) Wahl) writes:

>> #+ srcname trait_demo.cpp
>> #+ begin_src c++
>> : using namespace std;
>> : int main( void )
>> : {
>> :   string tmp;
>> :   while(cin >> tmp)
>> :     {
>> :       cout << "from pipe: " << tmp << endl;
>> :     }
>> :
>> :
>> :   return 0;
>> : }
>> #+ end_src
>>
>> 4. C-c ' ;;then emacs lauch a buffer to edit the source code.
>> 5. But the mode is "Picture" not c++ mode. Why?
>>
>> I tried other language like python, it also launch a Picture-mode.
>> I would like to know. what's wrong?  My emacs version is 23.2.1 on
>> windows xp.
>>
>> Any body can help? thanks!
>
> Hi Hill,
>
> just remove the space after the "#+" in the lines starting with "#+".
> E.g. use "#+begin_src c++" instead of "#+ begin_src c++".

And I'm pretty sure that the code between the #+begin_src/end_src
markers should be put as-is, i.e., without leading :.

Bye,
Tassilo




  reply	other threads:[~2010-12-21 16:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-21  8:09 org-mode source blocks Hill
2010-12-21  9:36 ` Marco (m) Wahl
2010-12-21 16:36   ` Tassilo Horn [this message]
2010-12-21 16:51     ` Bastien
     [not found] <mailman.2.1292949627.3175.help-gnu-emacs@gnu.org>
2010-12-22  1:31 ` Hill
2010-12-22  6:35   ` Suvayu Ali

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=87pqsvw0aj.fsf@member.fsf.org \
    --to=tassilo@member.fsf.org \
    --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.