开发者

Unexpandable Window

While using JFrame, is it开发者_Go百科 possible to have the window unable to be expanded by the user?


This is what you want. It explains it setResizable() method.

EDIT: If you would like a quick introduction, say your JFrame object is called myFrame, then, to make it non-resizable,

myFrame.setResizable(false);


You just need call setResizable(false) on your JFrame, e.g.:

JFrame frame = new JFrame();
frame.setSize(500, 300);
frame.setResizable(false);
frame.setVisible(true);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜