Quick start

From download to your first PDF

Three steps and about five minutes. Pick the package that matches your stack and the install line and first program appear below — both exactly as they ship in the download.

Choose your stack
Choose a different stack

1. Install Python

shell
pip install lumaspdf
# or: unzip python.zip and import lumaspdf from it

2. Write a PDF

The smallest complete program: create the document, write to it, close it.

python
import lumaspdf

pdf = lumaspdf.CreatePDF('hello.pdf')
lumaspdf.Append(pdf)
lumaspdf.SetFont(pdf, 'Helvetica', 0, 24.0, True, 0)
lumaspdf.WriteFText(pdf, 0, 'Hello from LumasPDF')
lumaspdf.EndPage(pdf)
lumaspdf.CloseFile(pdf)
lumaspdf.DeletePDF(pdf)

3. Remove the watermark when you are ready

Everything above works with no key at all. Output carries an evaluation watermark until a key is applied — nothing else is limited, and there is no time limit on trying it.

Before you deploy this one

This package
Python

A ctypes binding: no compiled module, no build step.

Licence covers

win-x86 win-x64 linux-x64 macos

Requirements
  • bin/win-x64
  • bin/win-x86
  • bin/linux-x64
  • bin/osx
  • 30
  • lumaspdf.py
  • lumasrpt.py

If the first program does not run

Almost every first-run problem is the same one: the process cannot find the engine library, or it found one built for the other bitness. The package page for your stack lists what has to sit where, and the knowledge base has the platform-specific version of that answer.