R Under development (unstable) (2025-12-16 r89184 ucrt) -- "Unsuffered Consequences" Copyright (C) 2025 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > message("*** favicon() ...") *** favicon() ... > > library("R.devices") R.devices v2.17.3 successfully loaded. See ?R.devices for help. > > message("- toFavicon() ...") - toFavicon() ... > > dataURI <- toFavicon({ + plot(NA, xlim=c(0,1), ylim=c(0,6), axes=FALSE, xaxs="i", yaxs="i") + col <- rev(c("#FF0000", "#FF8000", "#FFFF00", "#008000", "#0000FF", "#A000C0")) + for (kk in 1:6) rect(0,kk-1,1,kk, col=col[kk], border=NA) + points(1/2,6/2, pch=21, cex=21, lwd=80, col="#FFFFFF") + }) Warning message: In par(parT) : argument 1 does not name a graphical parameter > print(dataURI) [1] "\n" > > pathname <- toFavicon({ + plot(NA, xlim=c(0,1), ylim=c(0,6), axes=FALSE, xaxs="i", yaxs="i") + col <- rev(c("#FF0000", "#FF8000", "#FFFF00", "#008000", "#0000FF", "#A000C0")) + for (kk in 1:6) rect(0,kk-1,1,kk, col=col[kk], border=NA) + points(1/2,6/2, pch=21, cex=21, lwd=80, col="#FFFFFF") + }, field="pathname") Warning message: In par(parT) : argument 1 does not name a graphical parameter > print(pathname) [1] "figures/favicon.png" > > message("- toFavicon() ... DONE") - toFavicon() ... DONE > > > message("- favicon() errors ...") - favicon() errors ... > > ## Exception handling > res <- try({ + favicon(width=32L, height=64L) + dev.off() + }) Error in favicon(width = 32L, height = 64L) : The width and the height must be the same for a favicon: 32 != 64 > stopifnot(inherits(res, "try-error")) > > message("- favicon() errors ... DONE") - favicon() errors ... DONE > > message("*** favicon() ... DONE") *** favicon() ... DONE > > proc.time() user system elapsed 0.51 0.09 0.59