Hi,
I am starting out using MiGLayout for my GUI design, and one of the feature I would need is to show/hide certain components based on the state of other components.
I was going to code this myself, when I noticed that one of the Component Constraints supported by MiGLayoutis hidemode
.
Does this do what I think it does? If so, how do I trigger a hide / unhide action, assuming the hidemode
has been set? (After looking through the documentation I was able to find out how to set the hidemode
, but not how it is used thereafter)
Thanks!
hidemode
Sets the hide mode for the component. If the hide mode has been specified in the This hide mode can be overridden by the component constraint. The hide mode specified how the layout manager should handle a component that isn't visible. The modes are:
0 - Default. Means that invisible components will be handled exactly as if they were visible.
1 - The size of the component (if invisible) will be set to 0, 0.
2 - The size of the component (if invisible) will be set to 0, 0 and the gaps will also be set to 0 around it.
3 - Invisible components will not participate in the layout at all and it will for instance not take up a grid cell.
Example: "hidemode 1"