API documentation#

Glowing pancake provides the following public API.

glopan.combine_pdfs(pdffiles: List[str], outfile: str)#

Combine several PDF files to one.

Parameters
  • pdffiles (list) – The names of the PDF files to combine.

  • outfile (str) – The name of the PDF file to write.

glopan.delete_files(files: List[str])#

Delete a list of files.

Parameters

files (list) – A list of files to delete.

glopan.docx_to_pdf(docxfile: str)#

Convert a DOCX file to PDF.

Parameters

docxfile (str) – The name of the DOCX file to convert.

glopan.many_ps_to_pdf(psfiles: List[str])#

Convert several Postscript files to PDF using glopan.ps_to_pdf.

Parameters

psfiles (list) – The Postscript files to convert.

glopan.pdf_convert(pdffile: str, outformat: str, outdpi=600)#

Convert a PDF page to a given format using Inkscape.

Parameters
  • pdffile (str) – The name of the PDF file to convert.

  • outformat (str) – The format to convert to.

Kwargs:

outdpi (int): The resolution of the outfile, if relevant, in DPI.

glopan.pdf_to_emf(pdffile: str)#

Convert a PDF file to EMF using glopan.pdf_convert.

glopan.pdf_to_png(pdffile: str, outdpi=600)#

Convert a PDF file to PNG using glopan.pdf_convert.

glopan.pdf_to_svg(pdffile: str)#

Convert a PDF file to SVG using glopan.pdf_convert.

glopan.ps_to_pdf(psfile: str)#

Convert a Postscript file to PDF.

Parameters

psfile (str) – The name of the Postscript file.

glopan.split_pdf(pdffile: str)#

Split a PDF file in one file per page.

Parameters

pdffile (str) – The name of the PDF file to split.