是否可以使用 wxPython 将菜单与菜单栏右侧对齐?

发布于 2024-10-12 09:36:04 字数 152 浏览 9 评论 0原文

我正在尝试在 wxPython 2.8.11.0 和 Python 2.7 中创建一个菜单栏,其中大多数菜单都是左对齐的(正常情况下),但理想情况下,有一个菜单栏是右对齐的,或者至少以某种方式与其余菜单分开。

这可能吗?

编辑:这需要是一个跨平台的解决方案。

I'm trying to create a menu bar in wxPython 2.8.11.0 and Python 2.7 where most of the menus are left aligned (as normal) but one is - ideally - right aligned, or at least separated in some way from the rest.

Is this possible?

EDIT: This needs to be a cross-platform solution.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

街道布景 2024-10-19 09:36:04

如果本机菜单栏不支持它,那么 wxPython 可能也不支持。不过,菜单栏有一个纯 Python 实现。它被称为平面菜单。我会尝试一下。如果它不起作用,至少你可以破解它或提交 Python 代码补丁,而不是试图找出 C++ 来修复 wxWidgets。

If the native menubar doesn't support it, then wxPython probably won't either. There is a pure Python implementation of the menubar though. It's called FlatMenu. I would try that. If it doesn't work, at least you can hack it or submit a patch in Python code rather than trying to figure out the C++ for fixing wxWidgets.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文