[rkward-cvs] SF.net SVN: rkward:[4404] trunk/rkward
tfry at users.sourceforge.net
tfry at users.sourceforge.net
Wed Oct 31 12:14:50 UTC 2012
Revision: 4404
http://rkward.svn.sourceforge.net/rkward/?rev=4404&view=rev
Author: tfry
Date: 2012-10-31 12:14:49 +0000 (Wed, 31 Oct 2012)
Log Message:
-----------
Add convenience function rk.flush.output()
Modified Paths:
--------------
trunk/rkward/ChangeLog
trunk/rkward/rkward/rbackend/rpackages/rkward/NAMESPACE
trunk/rkward/rkward/rbackend/rpackages/rkward/R/rk.filename-functions.R
trunk/rkward/rkward/rbackend/rpackages/rkward/man/rk.get.tempfile.name.Rd
Modified: trunk/rkward/ChangeLog
===================================================================
--- trunk/rkward/ChangeLog 2012-10-31 12:03:24 UTC (rev 4403)
+++ trunk/rkward/ChangeLog 2012-10-31 12:14:49 UTC (rev 4404)
@@ -1,3 +1,4 @@
+- Added utiltity function rk.flush.output() TODO: Output Window->Flush Output should use this
- RKWard is now categorized as Science/Math/Numerical Analysis in its .desktop file
- Fixed: Device history was not working with more recent versions of ggplot2 (TODO: find out, which version broke it, exactly)
- Fixed: Option to include suggested packages in install was mis-labelled "install dependencies"
Modified: trunk/rkward/rkward/rbackend/rpackages/rkward/NAMESPACE
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkward/NAMESPACE 2012-10-31 12:03:24 UTC (rev 4403)
+++ trunk/rkward/rkward/rbackend/rpackages/rkward/NAMESPACE 2012-10-31 12:14:49 UTC (rev 4404)
@@ -25,6 +25,7 @@
export(rk.first.plot)
export(.rk.fix.assignments)
export(.rk.fix.assignments.graphics)
+export(rk.flush.output)
export(rk.force.append.plot)
export(rk.get.description)
export(.rk.get.environment.children)
Modified: trunk/rkward/rkward/rbackend/rpackages/rkward/R/rk.filename-functions.R
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkward/R/rk.filename-functions.R 2012-10-31 12:03:24 UTC (rev 4403)
+++ trunk/rkward/rkward/rbackend/rpackages/rkward/R/rk.filename-functions.R 2012-10-31 12:14:49 UTC (rev 4404)
@@ -3,7 +3,8 @@
#' In RKWard the output is saved as a html file which is located at "~/.rkward"
#' by default. (\bold{TODO}: make this platform free). The name of this html
#' file can be retrieved and set using \code{rk.get.output.html.file} and
-#' \code{rk.set.output.html.file}.
+#' \code{rk.set.output.html.file}. \code{rk.flush.output.html.file} will delete
+#' the current (or specified) html file, and re-initialize it.
#'
#' \code{rk.get.tempfile.name} returns a non-existing filename inside the
#' directory of the output file. It is mainly used by \link{rk.graph.on} to
@@ -157,3 +158,10 @@
.rk.do.plain.call ("set.output.file", x, synchronous=FALSE)
invisible (NULL)
}
+
+#' @export
+#' @rdname rk.get.tempfile.name
+"rk.flush.output" <- function (x=rk.get.output.html.file ()) {
+ unlink (file)
+ rk.set.output.html.file (file)
+}
Modified: trunk/rkward/rkward/rbackend/rpackages/rkward/man/rk.get.tempfile.name.Rd
===================================================================
--- trunk/rkward/rkward/rbackend/rpackages/rkward/man/rk.get.tempfile.name.Rd 2012-10-31 12:03:24 UTC (rev 4403)
+++ trunk/rkward/rkward/rbackend/rpackages/rkward/man/rk.get.tempfile.name.Rd 2012-10-31 12:14:49 UTC (rev 4404)
@@ -1,4 +1,5 @@
\name{rk.get.tempfile.name}
+\alias{rk.flush.output}
\alias{rk.get.output.html.file}
\alias{rk.get.tempfile.name}
\alias{rk.get.workspace.url}
@@ -12,7 +13,10 @@
rk.get.output.html.file()
- rk.set.output.html.file(x)
+ rk.set.output.html.file(x,
+ additional.header.contents = getOption("rk.html.header.additions"))
+
+ rk.flush.output(x = rk.get.output.html.file())
}
\arguments{
\item{prefix}{a string, used as a filename prefix when
@@ -23,6 +27,11 @@
\item{x}{a string, giving the filename of the of the
output file}
+
+ \item{additional.header.contents}{NULL or an additional
+ string to add to the HTML header section. This could be
+ scripts or additional CSS definitions, for example. Note
+ that}
}
\value{
\code{rk.get.tempfile.name},
@@ -36,6 +45,8 @@
this platform free). The name of this html file can be
retrieved and set using \code{rk.get.output.html.file}
and \code{rk.set.output.html.file}.
+ \code{rk.flush.output.html.file} will delete the current
+ (or specified) html file, and re-initialize it.
}
\details{
\code{rk.get.tempfile.name} returns a non-existing
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the rkward-tracker
mailing list