[RkWard-devel] Graphics devices

Thomas Friedrichsmeier thomas.friedrichsmeier at ruhr-uni-bochum.de
Thu Jan 4 11:53:15 UTC 2007


Hi!

On Thursday 04 January 2007 02:20, Renaud Lacour wrote:
> A new window entitled "R Graphics: Device 2 (ACTIVE) - RKWard" opens and
> shows a gray background and no graphics.
>
> The Konsole output shows :
>
> [...]
>
> rkward: *** Embed 65011714 into 33556934. window=0
> rkward:  failure to withdraw window
> Assert failed at rkwardapplication.cpp - function registerNameWatcher
> line 73
>
> Although quite frequent, that is not always the case, Rkward sometimes
> displays my graphics.

Yes, I've seen this problem, before, too. It is due to a bug in kwin (see: 
http://lists.kde.org/?l=kde-devel&m=116448102901184&w=2). This *should* be 
fixed for KDE 3.5.6, which is expected to be released on January, 23.
While I was aware of that problem, here, it occurs only rarely. That's why I 
still included the feature. I have no idea, why it seems to be so much more 
frequent on your machine. If it becomes too annoying, you can run the 
following R code:

x11 <- X11 <- grDevices::X11

This will (for that session) disable the menu bar RKWard tries to put around 
X11 windows, but rather display the plain window as in earlier versions.

> I tried to display x plot on Rkward's output tab using teh following
> commands :
>
> dev.off()
> rk.graph.on()
> plot(x)
> rk.graph.off()
>
> but the output tab only shows a blank image. Output refresh doesn't help
> yet the image actually exists in ~/.rkward.

Ok, I can reproduce this, and get the same bug. The problem seems to be that 
the khtmlpart does not reload images that did not work previously. For me, 
the image does show, when I close and reopen the Output window.
Another workaround would be to ensure that everything from rk.graph.on () to 
rk.graph.off () gets run in a single go. E.g. in the console, write this 
instead:

rk.graph.on (); plot (x); rk.graph.off ()

Now the image should already be valid when the khtmlpart first opens it, and 
show up correctly. Alternatively, write the command in the script editor and 
run all with F9.

I'll try to find a proper fix, soon.

Regards
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/rkward-devel/attachments/20070104/4e31f5b7/attachment.sig>


More information about the Rkward-devel mailing list