有人在 Wx Perl 中使用过 Wx::GridBagSizer 布局管理器吗?
我找到的非常稀疏的 wxPerl 文档说它是受支持的,而且果然,我可以创建它的一个实例。
my $layout = new Wx::GridBagSizer(5,5);
但我无法让它发挥作用。具体来说,我无法将小部件添加到 $layout。有人做过这个吗?
当我谈论这个主题时,有没有人找到 wxPerl 的任何好的文档?
The very sparse wxPerl documentation that I have been able to find says it is supported and sure enough, I can create an instance of it.
my $layout = new Wx::GridBagSizer(5,5);
But I cannot make it work. Specifically, I cannot add a widget to $layout. Anyone done this?
And while I am on the subject, has anyone found any GOOD documentation for wxPerl?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
首先,查看 Wx::Demo 以获取几乎每个类的示例。
您应该使用其
Add
方法 添加小部件。也许
First, checkout Wx::Demo for examples of just about every class.
You should add widgets using its
Add
method.and maybe
池上让我朝着正确的方向前进。 Wx::Demo 非常有帮助(就像 PerlTk 的小部件,如果有人熟悉该工具的话)。但 Wx::GridBagSizer 没有明确讨论,因此需要经过一些尝试和错误才能最终实现。这是我试图做的:
ikegami got me going in the right direction. Wx::Demo was VERY helpful (like widget for PerlTk if anyone is familiar with that tool). But Wx::GridBagSizer is not explicitly discussed so it took some trial and error to finally get there. Here is what I was trying to do: