Permalink
Browse files

use transparent bg color

  • Loading branch information...
1 parent 3d3aca9 commit 7a65519761bcb9f14f4949548c72bebc14aa5824 @jjallaire jjallaire committed Mar 8, 2013
@@ -300,7 +300,8 @@ Error PlotManager::savePlotAsBitmapFile(const FilePath& targetPath,
// generate code for creating bitmap file device
boost::format fmt(
"{ require(grDevices, quietly=TRUE); "
- " %1%(filename=\"%2%\", width=%3%, height=%4%, pointsize = 16 %5%); }");
+ " %1%(filename=\"%2%\", width=%3%, height=%4%, "
+ " bg = \"transparent\", pointsize = 16 %5%); }");
std::string deviceCreationCode = boost::str(fmt % bitmapFileType %
string_utils::utf8ToSystem(targetPath.absolutePath()) %
width %
@@ -106,7 +106,9 @@ Error shadowDevDesc(DeviceContext* pDC, pDevDesc* pDev)
PreserveCurrentDeviceScope preserveCurrentDeviceScope;
// create PNG device (completely bail on error)
- boost::format fmt("grDevices:::png(\"%1%\", %2%, %3% %4%, pointsize = 16)");
+ boost::format fmt("grDevices:::png(\"%1%\", %2%, %3% %4%, "
+ "bg = \"transparent\", "
+ "pointsize = 16)");
std::string code = boost::str(fmt %
string_utils::utf8ToSystem(pDC->targetPath.absolutePath()) %
pDC->width %

0 comments on commit 7a65519

Please sign in to comment.