[rkward-devel] altering rk.graph.on and rk.graph.off
Thomas Friedrichsmeier
thomas.friedrichsmeier at ruhr-uni-bochum.de
Wed Sep 1 16:02:06 UTC 2010
Hi,
On Saturday 28 August 2010, Prasenjit Kapat wrote:
> I've modified the rk.graph.on () and rk.graph.off () functions
> slightly in trunk. Since many might be using these functions (as it is
> used in a lot of plugins), here is a little explanation:
yes, I think this is a good idea, indeed!
I wonder whether the "set.active.device" parameter is actually needed,
however. I see you use set.active.device=FALSE, for the copy to output action.
But isn't the net effect the same as the default set.active.device=TRUE? The
only difference I can see is that the graphics window to be copied is not
activated in this case. But then why not? Most other interactions with a
graphics window lead to activation, too, and why shouldn't they?
Note that
dev.set (non.current.device.number)
will open a new device. This could cause confusion in the (unlikely) case that
the previous device was closed in between calls to rk.graph.on() and
rk.graph.off(). So I'd suggest to re-write the line rk.graph.off() as
if ((!is.null (i)) && (i %in% dev.list ()) dev.set (i)
Regards
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/rkward-devel/attachments/20100901/d5cc3e40/attachment.sig>
More information about the Rkward-devel
mailing list