> Use list-tables which is a Experimental-cum-ODT-only feature. See the > attachment.
Additional note: List tables are also a feature of the XHTML backend. (add-to-list 'load-path "~/src/org-mode/contrib/lisp") M-x load-library RET org-xhtml RET M-x org-export-as-xhtml-and-open RET See the attached HTML output for what you get.
* Testing
#+begin_list-table
- Say Hello in Perl
#+begin_src perl :results output
# Perl
sub say_hello {
print "Hello, world";
}
say_hello;
#+end_src
- Say Hello in Python
#+begin_src python :results output
# Python
def say_hello():
print("Hello, world")
say_hello()
#+end_src
#+end_list-table
Title: side-by-side
side-by-side
Table of Contents
1 Testing
|
Say Hello in Perl # Perl sub say_hello { print "Hello, world"; } say_hello; |
Say Hello in Python # Python def say_hello(): print("Hello, world") say_hello() |
Date: 2011-12-28 10:54:15 India Standard Time
Org version 7.8.02 with Emacs version 24
Validate XHTML 1.0
>>
>>> hth,
>>> Christian
>>>
>>> ---
>>>
>>> #+title: Side by side code blocks
>>> #+style: <style>pre.src {display: table-cell;}</style>
>>>
>>> How to say hello in two languages:
>>>
>>> #+begin_src perl :results output
>>> # Perl
>>> sub say_hello {
>>> print "Hello, world";
>>> }
>>>
>>> say_hello;
>>> #+end_src
>>> #+begin_src python :results output
>>> # Python
>>> def say_hello():
>>> print("Hello, world")
>>>
>>> say_hello()
>>> #+end_src
>>
>>
--
