#pdf

pdfpdf

A Pretty Darn Fast library for creating PDF files. Currently, only simple vector graphics and simple text are supported

2 unstable releases

Uses old Rust 2015

0.2.0 Oct 11, 2017
0.1.0 Aug 14, 2017

#376 in Visualization

MIT/Apache

220KB
4.5K SLoC

pdfpdf

A blazing fast pure rust library for generating PDF files.

Originally based on pdf-canvas


lib.rs:

A Pretty Darn Fast library for creating PDF files. Currently, only simple vector graphics and simple text are supported.

Example

use pdfpdf::{Color, Pdf};

Pdf::new()
    .add_page(180.0, 240.0)
    .set_color(&Color::rgb(0, 0, 248))
    .draw_circle(90.0, 120.0, 50.0)
    .write_to("example.pdf")
    .expect("Failed to write to file");

To use this library you need to add it as a dependency in your Cargo.toml:

[dependencies]
pdfpdf = "0.2"

More working examples can be found in [here] (https://github.com/saethlin/pdfpdf/tree/master/examples).

Dependencies

~620KB
~11K SLoC