How do I add the JDesktopPane
to JFrame
using GridBagLayout
and set its height and width. If I add JDesktopPane
that contains JInternalFrame
I don't get anything. But works well in case of GridLayout
but the problem is I can't set my desired size in it as GridLayout
splits equal space among each component added.
相关问题
- Delete Messages from a Topic in Apache Kafka
- Jackson Deserialization not calling deserialize on
- How to maintain order of key-value in DataFrame sa
- StackExchange API - Deserialize Date in JSON Respo
- Difference between Types.INTEGER and Types.NULL in
You will probably need to set the fill and weight attributes of the
GridBagConstraints
...This will cause the component to want to push to the limits of the container and will cause the component to fill it's cell within the grid
This override the components preferred size (for the most part)
Take a look at How to Use GridBagLayout for more details...