简体   繁体   English

在带有R的tcltk窗口中显示图像......怎么样?

[英]display image in tcltk window with R… How?

Can anyone tell me how to dislpay an image in a tcltk window ? 谁能告诉我如何在tcltk窗口中取消图像?

I found Img package here : sourceforge (1.3 version) but I can't install it manually because of missing 'DESCRIPTION' file. 我在这里找到了Img包: sourceforge (1.3版)但由于缺少'DESCRIPTION'文件,我无法手动安装它。

How can I install it ? 我该如何安装?

-> How can I display image on a tcltk window (using Img package or not) ? - >如何在tcltk窗口上显示图像(使用Img包还是不使用)?

thank you 谢谢

Config : Windows 7 64 bits, R 3.0.1 配置:Windows 7 64位,R 3.0.1

You can use a label for this: 您可以使用标签:

w <- tktoplevel()
tcl("image","create","photo", "imageID", file="your_image.gif")
l <- ttklabel(w, image="imageID", compound="image")
tkpack(l)

This only supports a limited number of file formats though. 这仅支持有限数量的文件格式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM