Java的setLocationRelativeTo()

来源:互联网 发布:查看nginx运行状态 编辑:程序博客网 时间:2024/04/28 17:00

public void setLocationRelativeTo(Component c)

设置窗口相对于指定组件的位置。


如果组件当前未显示或者 c 为 null,则此窗口将置于屏幕的中央。

中点可以使用 GraphicsEnvironment.getCenterPoint 确定。

0 0
原创粉丝点击