问题
I have a JFrame of which extended state option is set to MAXIMIZE_BOTH
When i want to get the width of the JFrame it returns 0.
so WHY?
回答1:
- I have a JFrame of which extended state option is set to MAXIMIZE_BOTH
JFrame.getExtendedState() returns proper state
- When i want to get the width of the JFrame it returns 0.
any coordinated are accesible after
pack()is calledfor already visible container on the screen
来源:https://stackoverflow.com/questions/15152297/how-to-get-extendedstate-width-of-jframe