Description Usage Arguments Details Value Author(s) References Examples
This reads a CSS document into R. The document can be the name of a file or as the text/content of a CSS.
1 |
src |
the name of the CSS file or the CSS content |
asText |
a logical value indicating whether |
This uses libcroco to parse the CSS
An object of class CSSStyleSheet
Duncan Temple Lang
libcroco at http://www.freespiders.org/projects/libcroco
Cascading Style Sheets http://www.w3.org/Style/CSS/
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | f = system.file("samples", "eg.css", package = "RCSS")
css = readCSS(f)
if(require(RCurl)) {
txt = getURL("http://www.omegahat.org/OmegaTech.css")
css = readCSS(txt, TRUE)
css = readCSS(I(txt))
}
if(require(XML)) {
f = system.file("samples", "bob.svg", package = "RCSS")
doc = xmlParse(f)
node = getNodeSet(doc, "//x:style[@type='text/css']", "x")[[1]]
css = readCSS(I(xmlValue(node)))
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.