我想用traitsui.api.ValueEditor要为字典创建树视图,请执行以下操作:
class my_editor(HasTraits):
x = Any
traits_view = View(Item('x', editor = ValueEditor()))
a = my_editor(x = my_dict)
a.configure_traits()
输出结果如下:
我想隐藏项目''u listener\u traits'、''u sync\u trait'和''u traits\u listener',它们以下划线字符开头。这样树查看器将只显示d、指示符、材料名称、材料、模型树和名称。
在查找了ValueEditor的源代码之后,我猜编辑TreeEditor、RootNode或value树节点可能会自定义要查看的特性?这是正确的方法吗?我应该特别编辑哪个来定制ValueEditor?你知道吗
目前没有回答
相关问题 更多 >
编程相关推荐