From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pierre de Buyl Subject: Re: Latex export with python source code included. Date: Sun, 31 Jan 2010 20:55:14 +0100 Message-ID: References: <1618521001310240l77b87a59hb81c0c05046a64d2@mail.gmail.com> Mime-Version: 1.0 (Apple Message framework v753.1) Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed Content-Transfer-Encoding: quoted-printable Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NbftO-0005OL-3x for emacs-orgmode@gnu.org; Sun, 31 Jan 2010 14:55:34 -0500 Received: from [199.232.76.173] (port=57663 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NbftM-0005NL-U0 for emacs-orgmode@gnu.org; Sun, 31 Jan 2010 14:55:32 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NbftJ-00073E-4u for emacs-orgmode@gnu.org; Sun, 31 Jan 2010 14:55:32 -0500 Received: from mxin.ulb.ac.be ([164.15.128.112]:61020) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NbftI-00072w-NO for emacs-orgmode@gnu.org; Sun, 31 Jan 2010 14:55:29 -0500 In-Reply-To: <1618521001310240l77b87a59hb81c0c05046a64d2@mail.gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: michael@arpsorensen.dk Cc: emacs-orgmode If your scope is latex only, add #+LaTeX_HEADER: \usepackage{listings} and in the body of the document use #+LaTeX: \lstinputlisting{codefile.py} Pierre Le 31 janv. 10 =E0 11:40, Michael Bernhard Arp S=F8rensen a =E9crit : > Hi all. > > How do I make sure that latex package "listings" is used and how do =20= > I use it to show the content of a python-file? > > I want to include some python code, but it's all ugly when =20 > outputtet to PDF > > Is there a better way to show source code in org? At the moment I'm =20= > using: #+INCLUDE: "matrix-citizen.07.py" src python. Looks bad in =20 > PDF-exports. > > I tried using: > > #+begin_src python > print "Hello World!" > #+end_src > > But then I have to cut and paste ALL my code while I'd rather just =20 > include the code. > > Med venlig hilsen/Kind regards > > Michael B. Arp S=F8rensen > Programmer / BOFH > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode