knitr (version 0.9)

eclipse_theme: Download and convert a theme from eclipsecolorthemes.org to CSS

Description

This function uses the XML package to parse the theme as an XML file, then converts to a CSS file using a brew template in the knitr package. The CSS file can be further parsed with knit_theme$get(), and the result will be ready for knit_theme$set() to set the highlighting theme.

Usage

eclipse_theme(id)

Arguments

id
id of theme to save as CSS

Value

  • Path to the CSS file converted from the website.

References

http://www.eclipsecolorthemes.org/

See Also

knit_theme

Examples

Run this code
## http://www.eclipsecolorthemes.org/?view=theme&id=1
opts_knit$set(out.format = "latex")
(css = eclipse_theme(1))
thm = knit_theme$get(css)
knit_theme$set(thm)

Run the code above in your browser using DataCamp Workspace