Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个复合材料FillLayout
FillLayout
comp.setLayout(new FillLayout(SWT.VERTICAL));
我在这个里面创建了 2 个复合材料。
现在我想隐藏第一个并释放被占用的地方。
child1.setVisible(false);
我知道如果使用GridDataand可以排除复合材料,GridLayout但我使用的是FillLayout.
GridData
GridLayout
可以做什么?
黑客将其Control.setParent()添加到不可见的 Shell 中。请注意,Control.setParent()可能并非所有平台都支持。恕我直言,避免使用这种黑客GridLayout是不值得的,您应该FillLayout将GridLayout.
Control.setParent()