I am looking to get the co-ordinates of the main window.
I want to create a new JFrame that can be created in the center of the main window, rather than where the OS decides to open it.
I have already looked into it, but I can only find screenX(), but that does the inverse of what I am looking for. I just want to know the coordinate of the top-left corner of the window, ie. where 0,0 is on the window.
Thanks.
1