Tags Python , Qt

A few months ago I posted a couple of demo snippets for embedding matplotlib plots into wxPython GUIs.

Well, as I'm now in the process of moving to PyQt for my GUI needs in Python, I've reimplemented one of the demos with PyQt. Here's a screenshot:

And the demo itself can be taken from here.

The demo features:

  • Using the maplotlib navigation toolbar
  • Adding data to the plot dynamically
  • Dynamically modifying the plot's properties
  • Processing matplotlib events in the GUI
  • Saving the plot to a file from a menu
The embedding of matplotlib into PyQt is relatively smooth and similar to wxPython, with a couple of tiny differences (which mainly have to do with how the two frameworks handle parenting of GUI elements). Note that I've reimplemented only one of the demos, but it's really sufficient for getting started with combining the two libraries. ::...
免责声明:
当前网页内容, 由 大妈 ZoomQuiet 使用工具: ScrapBook :: Firefox Extension 人工从互联网中收集并分享;
内容版权归原作者所有;
本人对内容的有效性/合法性不承担任何强制性责任.
若有不妥, 欢迎评注提醒:

或是邮件反馈可也:
askdama[AT]googlegroups.com



自怼圈/年番新

DU21.4
关于 ~ DebugUself with DAMA ;-)


关注公众号, 持续获得相关各种嗯哼:
zoomquiet


粤ICP备18025058号-1
公安备案号: 44049002000656 ...::