Skip to main content

Easily convert CSV Files to PDF Files using Python!

Project description

CSV TO PDF CONVERTER ( .csv ➜ .pdf )

A Python module that allows you to convert CSV FILES to PDF FILES easily!

Installation

pip install csv2pdf

Examples 📋

# Quick conversion

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf")
# Change Orientation of the PDF File

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", orientation="L")
# Specify Delimiter for the CSV File

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", delimiter="&")
# Change Alignment of the cells

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", align="L")

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", align="R")
# Change Size & Header-Size

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", size=5)

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf", headersize=7)
# Using custom fonts

>>> from csv2pdf import convert
>>> convert("source.csv", "destination.pdf",
            font=r"Fonts\custom-font.tff", headerfont=r"Fonts\custom-header-font.tff")

Use .tff files for specifying font files. Fonts can be downloaded from Google Fonts.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

csv2pdf-0.1.4.tar.gz (3.6 kB view hashes)

Uploaded Source

Built Distribution

csv2pdf-0.1.4-py3-none-any.whl (3.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page