Skip to content

Commit

Permalink
Fix for missing rsvg
Browse files Browse the repository at this point in the history
  • Loading branch information
jeroen committed Oct 15, 2020
1 parent 3e26f06 commit 569f593
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion R/edit.R
Original file line number Diff line number Diff line change
Expand Up @@ -95,14 +95,15 @@ For better results use image_read_svg() which uses the rsvg package.", call. = F

#' @export
#' @rdname editing
#' @examples if(require(rsvg))
#' @examples if(require(rsvg)){
#' tiger <- image_read_svg("http://jeroen.github.io/images/tiger.svg")
#' svgtxt <- '<?xml version="1.0" encoding="UTF-8"?>
#' <svg width="400" height="400" viewBox="0 0 400 400" fill="none">
#' <circle fill="steelblue" cx="200" cy="200" r="100" />
#' <circle fill="yellow" cx="200" cy="200" r="90" />
#' </svg>'
#' circles <- image_read_svg(svgtxt)
#' }
image_read_svg <- function(path, width = NULL, height = NULL){
path <- vapply(path, replace_url, character(1))
images <- lapply(path, function(x){
Expand Down
3 changes: 2 additions & 1 deletion man/editing.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 569f593

Please sign in to comment.