When a tool window is closed, it becomes invisible but preserves its content that will be available when the window is opened again. Most tool windows are listed in the View menu and can be displayed by selecting the corresponding View menu command. You can also use shortcut keys to display certain tool windows.
All layout changes are saved when you close the application and restored when you open it again.