| Title: | What the Package Does (Title Case) |
|---|---|
| Description: | More about what it does (maybe more than one line) Use four spaces when indenting paragraphs within the Description. |
| Authors: | Who wrote it |
| Maintainer: | The package maintainer <[email protected]> |
| License: | What license is it under? |
| Version: | 0.1.0 |
| Built: | 2026-07-24 10:48:53 UTC |
| Source: | https://github.com/skranz/latexsvg |
The javascript code that does the actually work is a minimally adapted version of the code by Jason Sachs. See the following references:
latexsvg(svg = paste0(readLines(file), collapse = "\n"), file = NULL, outfile = if (!is.null(file)) paste0(tools::file_path_sans_ext(file), "_latex.svg"))latexsvg(svg = paste0(readLines(file), collapse = "\n"), file = NULL, outfile = if (!is.null(file)) paste0(tools::file_path_sans_ext(file), "_latex.svg"))
svg |
the code of svg as text |
file |
a file name of the svg if no code is given |
outfile |
if not null the created svg will be written to this file |
https://www.embeddedrelated.com/showarticle/599.php https://bitbucket.org/jason_s/svg_mathjax
The code of the generated svg file
A function that converts a graphic in PDF format to an svg file and saves the svg file in the same directory as the pdf file Needs inkscape and the path to it binary
pdf2svg(file, inkscape.bin, svg.file = paste0(tools::file_path_sans_ext(file), ".svg"))pdf2svg(file, inkscape.bin, svg.file = paste0(tools::file_path_sans_ext(file), ".svg"))
file |
the pdf file |
inkscape.bin |
path and file name of the inkscape binary |
svg.file |
the output svg file; by default the same name as the pdf file but with extension .svg. |