Where is the information about the position of a window stored?
An example: I start
notepad.exe
, and it starts neither minimized or maximized, but just a medium size window in the center of the screen. If I close it and start it again, it is at the same XY coordinates. But then if I close it while it is at the bottom of the screen, it will start up again at the bottom (as opposed to the midlle) of the screen.If I wanted to manually change the XY positions of a window so it were to open up at a non-standard location, what would I need to edit?
Probably the registry, but where?
Solution:
Each program stores information about its windows in its own way. For Notepad, I found the following in my Windows XP registry.
In the registry, go to the following folder
HKEY_CURRENT_USERSoftwareMicrosoftNotepad
then modify the following values
iWindowPosX
iWindowPosY
iWindowPosDX
iWindowPosDY
X and Y are the coordinates of the window’s top left corner.DX and DY are the width and height of the window.
Other programs might save window position information in the registry or in other settings files.