Giter Club home page Giter Club logo

latex-rs's Introduction

LaTeX-rs

Build Status Crates.io Docs.rs latex-rs on Crates.io Build status

An ergonomic library for programatically generating LaTeX documents and reports.

This originally came from a desire to create an alternate renderer for mdbook which saves to PDF. I quickly found that I needed a library for programatically generating LaTeX documents from an AST and because there wasn't anything out there which suited my use case, I made my own.

Getting Started

Most of the types used to construct a Document have examples showing how they can be used and roughly what they'll generate, however for a more in-depth example check out the complex example in the examples/ directory.

This is what your typical "Hello World" would look like:

use latex::{Document, DocumentClass, Element};

let mut doc = Document::new(DocumentClass::Article);
doc.push("Hello World");

Features

The crate is still incomplete, but the following features are available when generating your LaTeX documents:

  • Preamble
  • Sections
  • Paragraphs
  • Align environment and Equations
  • Lists (both numbered and not)
  • Table of contents, title page, and the \clearpage command
  • Figures
  • Tables
  • Appendices
  • Included PDF files
  • \include{...}
  • \input{...}
  • Partial documents
  • References and Bibliography
  • labels, plus \ref{...} for referencing them

Contributing

This crate is still very young so pull requests and issues are welcome! If you there's something you want then create an issue and I'll try to implement it.

latex-rs's People

Contributors

michael-f-bryan avatar ratmice avatar santifa avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.