Hello,

James Ryland Miller <james.ryland.mil...@gmail.com> writes:

> I'm having trouble with getting python source=code blocks to export to
> LaTeX properly. I've figured out what's going wrong: the exporter is
> inserting tab characters on lines with 2 or more indentation levels in
> python. If I use org to export to .tex first, and then untabify the
> .tex files, the indent levels are preserved (assuming the tabs
> correctly lined up with the corresponding python in the first place,
> which many times they don't).

Try to set `org-src-preserve-indentation' to a non-nil value (on a very
recent Org) or add a "-i" flag to you source block:

  #+BEGIN_SRC python -n -i
  ...
  #+END_SRC

This should prevent Org from touching indentation within the block.


Regards,

-- 
Nicolas Goaziou

Reply via email to