How to preserved tool window

Hi Team,

I created tool window to display some results(data grid), but when user restart the IDE taht tool window is gone. Is this the default behaviour or Is it possible to dock tool window untill user close it (even IDE restart previous tool window need to appear content data can be empty).

I created tool window using 'ToolWindowManager' class and not configured using plugin.xml.


Comment actions Permalink

ToolWindow is registered by its' unique ID. This ID is also used to save/restore layout.
So, if IDE tries to restore toolwindow with 'unknown' ID it fails.
You should add your toolwindow to plugin.xml as ProjectComponent or ApplicationComponent

Comment actions Permalink

Hi Vassiliy,

Is it possible to register a tool window as ApplicationComponent? I thought it always needs to use project instance to be created/registered.

Comment actions Permalink

It's may register toolwindow like this:





<toolWindow id="{MyUniqueID}" anchor="right" secondary="false" icon="..." factoryClass="..." />




Please sign in to leave a comment.