Créer un fichier PDF avec Python

Résolu
angy21 Messages postés 39 Date d'inscription   Statut Membre Dernière intervention   -  
sebsauvage Messages postés 32893 Date d'inscription   Statut Modérateur Dernière intervention   -
Bonjour,

Pouvez-vous svp me dire si il est possible grace à Python de créer un fichier au format PDF a partir d'un fichier TXT ?

Si oui, pouvez-vous m'éclairer un peu plus ?

Merci par avance pour votre aide.
A voir également:

14 réponses

sebsauvage Messages postés 32893 Date d'inscription   Statut Modérateur Dernière intervention   15 662
 
Pouvez-vous svp me dire si il est possible grace à Python de créer un fichier au format PDF a partir d'un fichier TXT ?

Oui !

Il existe plusieurs librairie.
Par exemple celle de ReportLab:
http://www.reportlab.org/rl_toolkit.html

Voici un exemple pour créer un PDF avec Python:
http://vsbabu.org/mt/archives/2002/09/19/reportlab_python_pdf.html

Facile, non ?

Voir également l'article chez IBM:
http://www-106.ibm.com/developerworks/linux/library/l-sc6.html?loc=dwmain
2