开发者

JFrame Default size on ubuntu

I use ubuntu 10.04, but have discovered this on other ubuntu distributions as well.

开发者_StackOverflow中文版

When I start the first JFrame of an application, it won't start in its default size (specified by setSize()), but instead is maximized all over the screen.

I have one workaround for this, which is to use setResizable(false) (which brings the window to its intended size), then I set it back to true (I still want to be able to resize).

Anybody knows where this bug is from? Is there any elegant way to deal with this?

Thanks,


It is a window manager preference. Either disable it in ubuntu or modify your program live with users wanting to resize your program.

To disable (from ubuntu forum post):

  1. Open System->Preferences->Startup-Apps
  2. Find the entry for 'Maximus' and uncheck it
  3. Logout/login
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜