有没有办法从QWebView保存Bokeh plot?

2024-04-26 13:22:18 发布

您现在位置:Python中文网/ 问答频道 /正文

我在QWebView中显示Bokeh plot,但不幸的是,Bokeh plot工具栏上的save按钮不起作用(当我在浏览器中显示相同的plot时,一切正常)。QWebView中的其他Bokeh按钮可以操作。如何使save按钮在QWebView中工作?你知道吗

# plt_file is temporary html-file with html generated by Bokeh
plt_file.seek(0)
self.plot_web_view.setContent(plt_file.read())

Tags: byplotissavehtmlwithbokeh浏览器