View Single Post
Old 02-19-2007, 12:44 AM   #1
Falstaff
Member
Falstaff has a complete set of Star Wars action figures.Falstaff has a complete set of Star Wars action figures.Falstaff has a complete set of Star Wars action figures.
 
Posts: 21
Karma: 289
Join Date: Dec 2006
Device: Sony eReader
Create LRS and LRF files from Python with pylrs

I have just uploaded a Python package that I created called pylrs. It is available from the main page of http://www.falstaffshouse.com.

The package can create both lrs anf lrf files. The lrf files are created directly, without the use of a compiler. An example of creating an lrf file using the package is:

Code:
from pylrs.pylrs import *

b = Book()
b.Page().TextBlock().Paragraph("Hello, World!")
b.renderLrf("hello.lrf")
This will create an lrf file with a single page containing the line "Hello, World!"

There are several example programs included in the distribution that illustrate the various features. I created the package in order to format the plays of Shakespeare, which are also available from the same web page.

The source code is included in the distribution.

The package is optimistically versioned 1.0, but it's never been used by anyone but me, so assume it's an early alpha version at best.

The software has only been tested on Windows XP, Python 2.4 and 2.5, and the PRS-500.

Last edited by Falstaff; 02-19-2007 at 12:49 AM.
Falstaff is offline   Reply With Quote