views:

789

answers:

7

Hello!

I am looking for a library that would allow me to create presentations as would ppt or latex would allow me to do, but using python! Does such a library exists?

Thanks!

[edit]:Well a simple precision: I don't know latex but from what I understand it's a scripting language with keywords etc that allows to create presentations. What I'm looking for is the same thing but allowing me to write in python as I don't know latex...

+1  A: 

I'm not sure if this is precisely what you're looking for, but OpenOffice has a set of Python bindings that you could use to assemble a presentation ...

Alternatively, you could simply craft a simple HTML template to do PPT style things (Google knows about several) and then fill in the content from Python.

If what you're looking for is more of a way to make a GUI using Python, TkInter is what you want.

BonkaBonka
+1  A: 

Try this: http://cocos2d.org/ See the demos, you'll be amazed.

Fredy Treboux
A: 

If you want to programmatically create presentations, I suggest to learn LaTeX and generate latex documents using some templating engine like Cheetah or Jinja.

I've implemented a report generation module for billing system that way: latex source was generated from template, then pdflatex would be called to create pdf file with report. Worked like a charm.

Or use HTML with PPT styles like BonkaBonka suggests.

You can use Python with ReportLab to generate PDF programmatically, but that would be a real pain, beleive me, I've tried. Hand positioning every line of text is very errorprone and counterproductive activity.

Eugene Morozov
+1  A: 

do you mean something like this? if so, you can find the source for the presentation right there. it's written in reStructuredText and converted to a presentation using the python tool rst2s5.

Autoplectic
+1  A: 

There's always Bruce, The Presentation Tool. It uses reStructuredText input, which is a lot simpler than LaTeX - shouldn't take more than a few minutes to learn.

Nicholas Riley
A: 

You can use slidy, S5, docutils with S5 or docutils stand-alone.

S.Lott
+3  A: 

Latex is more of a declarative / markup language. It lets you define a presentation as a set of data that has certain properties, much like html. Trying to "do the same thing ... but in python" doesn't actually make sense, because the languages are completely different, and designed for different things. It looks like a lot of people have provided links to tools that will allow you to build presentations from python -- that's great -- but I would recommend using a tool designed for presentations from the ground up.

So, that brings us to a list of recommended tools for making presentations:

  • LaTeX, as you mentioned is fantastic.
  • OpenOffice Impress is quite usable, and works well.
  • If you're on a Mac, the Apple presentation tool Keynote is excellent.
  • On either Mac OS X or on Windows, microsoft PowerPoint is widely accepted as the industry standard.
  • Other people here have suggested a number of HTML based tools.

To sum up: you can do this sort of thing in Python, but you really shouldn't, unless you've got a good reason besides knowing the language.

Benson
Well what I was looking for was answered by Autoplectic: "reStructuredText". Until now I've been using powerpoint to do my presentation mostly, but ppt will suffer the ages, not like a good old txt in reStructuredText which is readable even without a "player".Simple, but powerful :-)
attwad
Learn LaTeX. Seriously. Your presentations will rock 20% more. Also, you will get more attention from the opposite sex.
Benson