I am writing an IntelliJ IDEA plugin to save open tab sessions called session tab . This question is a continuation of IntelliJ IDEA Plugin Development: saving groups of tabs, keeping them persistent, and reloading the set of tabs at the user's request .
Split windows are not currently supported. Therefore, I want to do two things:
- Get information about all split or unconnected windows that are containers for editor tabs. I need their position and the direction of separation (horizontal or vertical).
- When this information is saved and I need to load the tab session, I need to restore the broken panels and their tabs exactly as they were before.
Due to a lack of documentation, I am currently browsing the source code and found this promising piece of code:
private EditorsSplitters getSplittersFromFocus() { return FileEditorManagerEx.getInstanceEx(myProject).getSplitters(); }
This allows me to go through a set of split windows using EditorWindow[] windows = getSplittersFromFocus.getOrderedWindows() . They contain editor tabs and information about their width and height. But I did not find any information about the direction of the separation and how to restore the broken windows, as they were before.
Can anyone help?
java intellij-idea intellij-plugin
Alp Nov 01. '13 at 14:12 2013-11-01 14:12
source share