简体   繁体   English

TraitsUI错误视图(取决于操作系统)

[英]TraitsUI buggy view depending on OS

I'm using TraitsUI in Python to create applications, and noticed that the UI disappears on a Mac 10.8, looks great on Ubuntu 10.04, and is somewhere in between for Ubuntu-Mate 14.04 (ie small view discrepancies) 我在Python中使用TraitsUI创建应用程序,并注意到该UI在Mac 10.8上消失了,在Ubuntu 10.04上看起来很棒,并且在Ubuntu-Mate 14.04之间介于两者之间(即,小视图差异)

这是Mac映像

这是Ubuntu Mate映像

This is using the latest version of traits=4.5.0 on both computers and traitsui=4.4.0. 这在计算机和traitsui = 4.4.0上都使用了最新版本的traits = 4.5.0。 Any ideas, if not why this is happening, in which package or component of traits/traitsui the issue might reside? 是否有任何想法(如果不是这样的话),问题可能存在于traits / traitsui的哪个包或组件中?

Thanks. 谢谢。

PS the plot is not missing from the first screenshot, I just deleted it so that's not part of the bug. PS第一个屏幕截图中没有丢失该图,我只是删除了它,所以这不是错误的一部分。

Converting chat to answer: 将聊天转换为答案:

The discrepancy was due to differences in installed GUI backend toolkit versions. 差异是由于已安装的GUI后端工具包版本不同。 There are two main backends available in TraitsUI: The newer Qt is more performant, OO, full-featured, and attractive, which is why it is the default within Canopy. TraitsUI中有两个主要的后端可用:较新的Qt更具性能,面向对象,功能齐全且吸引人,这就是为什么它是Canopy中的默认后端。 The older Wx is still the default at the command line for legacy reasons. 由于遗留原因,较旧的Wx仍然是命令行的默认设置。 There are two wrappers for Qt: pyside and pyqt. Qt有两种包装:pyside和pyqt。 We recommend and use pyside for licensing reasons (and provide it for free, unlike pyqt). 出于许可原因,我们建议并使用pyside(并与pyqt不同,免费提供)。

The backend can be specified either in code or by setting environment variables at the command line. 可以通过代码或在命令行中设置环境变量来指定后端。 See Toolkit Selection and Integrating in a Qt application and VTK/Mayavi on Mac OS X . 请参阅Mac OS X上 的Qt应用程序中的“ 工具箱选择集成”VTK / Mayavi

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

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