public abstract class FileEditorManagerEx extends FileEditorManager
SEPARATOR_DISABLED, USE_CURRENT_WINDOW| Constructor and Description |
|---|
FileEditorManagerEx() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
changeSplitterOrientation() |
abstract void |
closeAllFiles()
Closes all files IN ACTIVE SPLITTER (window).
|
abstract void |
closeFile(VirtualFile file,
EditorWindow window)
Closes editors for the file opened in particular window.
|
abstract void |
createSplitter(int orientation,
EditorWindow window) |
abstract Promise<EditorWindow> |
getActiveWindow()
Asynchronous version of
getCurrentWindow(). |
abstract javax.swing.JComponent |
getComponent() |
abstract VirtualFile |
getCurrentFile() |
abstract EditorWindow |
getCurrentWindow()
Synchronous version of
getActiveWindow(). |
java.lang.Object |
getData(java.lang.String dataId,
Editor editor,
Caret caret)
Returns data associated with given editor/caret context.
|
abstract Pair<FileEditor[],FileEditorProvider[]> |
getEditorsWithProviders(VirtualFile file) |
abstract VirtualFile |
getFile(FileEditor editor) |
static FileEditorManagerEx |
getInstanceEx(Project project) |
abstract EditorWindow |
getNextWindow(EditorWindow window) |
abstract javax.swing.JComponent |
getPreferredFocusedComponent() |
abstract EditorWindow |
getPrevWindow(EditorWindow window) |
abstract FileEditorWithProvider |
getSelectedEditorWithProvider(VirtualFile file) |
abstract VirtualFile [] |
getSiblings(VirtualFile file) |
abstract EditorsSplitters |
getSplitters() |
abstract EditorsSplitters |
getSplittersFor(java.awt.Component c) |
abstract EditorWindow [] |
getWindows() |
abstract int |
getWindowSplitCount() |
abstract boolean |
hasOpenedFile() |
abstract boolean |
hasSplitOrUndockedWindows() |
abstract boolean |
isChanged(EditorComposite editor) |
abstract boolean |
isInsideChange() |
abstract boolean |
isInSplitter() |
abstract ActionCallback |
notifyPublisher(java.lang.Runnable runnable) |
FileEditor [] |
openFile(VirtualFile file,
boolean focusEditor) |
FileEditor [] |
openFile(VirtualFile file,
boolean focusEditor,
boolean searchForOpen)
Opens a file.
|
abstract Pair<FileEditor[],FileEditorProvider[]> |
openFileWithProviders(VirtualFile file,
boolean focusEditor,
boolean searchForSplitter) |
abstract Pair<FileEditor[],FileEditorProvider[]> |
openFileWithProviders(VirtualFile file,
boolean focusEditor,
EditorWindow window) |
void |
refreshIcons() |
void |
registerExtraEditorDataProvider(EditorDataProvider provider,
Disposable parentDisposable) |
void |
runWhenLoaded(Editor editor,
java.lang.Runnable runnable)
FileEditorManager supports asynchronous opening of text editors, i.e. |
abstract void |
setCurrentWindow(EditorWindow window) |
abstract void |
unsplitAllWindow() |
abstract void |
unsplitWindow() |
abstract void |
updateFilePresentation(VirtualFile file)
Refreshes the text, colors and icon of the editor tabs representing the specified file.
|
addBottomComponent, addFileEditorManagerListener, addFileEditorManagerListener, addTopComponent, closeFile, getAllEditors, getAllEditors, getEditors, getInstance, getOpenFiles, getProject, getSelectedEditor, getSelectedEditor, getSelectedEditors, getSelectedFiles, getSelectedTextEditor, hasOpenFiles, isFileOpen, navigateToTextEditor, openEditor, openTextEditor, removeBottomComponent, removeFileEditorManagerListener, removeTopComponent, setSelectedEditorpublic static FileEditorManagerEx getInstanceEx(Project project)
public abstract javax.swing.JComponent getComponent()
JComponent which represent the place where all editors are locatedpublic abstract javax.swing.JComponent getPreferredFocusedComponent()
FileEditor.getPreferredFocusedComponent()
but it also tracks (and remember) focus movement inside tabbed container.EditorComposite.getPreferredFocusedComponent()public abstract Pair<FileEditor[],FileEditorProvider[]> getEditorsWithProviders(VirtualFile file)
public abstract VirtualFile getFile(FileEditor editor)
public abstract void updateFilePresentation(VirtualFile file)
file - the file to refresh.public abstract EditorWindow getCurrentWindow()
getActiveWindow(). Will return null if invoked not from EDT.public abstract Promise<EditorWindow> getActiveWindow()
getCurrentWindow(). Execution happens after focus settle down. Can be invoked on any thread.public abstract void setCurrentWindow(EditorWindow window)
public abstract void closeFile(VirtualFile file, EditorWindow window)
file - file to be closed. Cannot be null.public abstract void unsplitWindow()
public abstract void unsplitAllWindow()
public abstract int getWindowSplitCount()
public abstract boolean hasSplitOrUndockedWindows()
public abstract EditorWindow [] getWindows()
public abstract VirtualFile [] getSiblings(VirtualFile file)
file itself) that belong
to the same tabbed container. The method returns empty array if file
is not open. The returned files have the same order as they have in the
tabbed container.public abstract void createSplitter(int orientation,
EditorWindow window)
public abstract void changeSplitterOrientation()
public abstract boolean isInSplitter()
public abstract boolean hasOpenedFile()
public abstract VirtualFile getCurrentFile()
public abstract FileEditorWithProvider getSelectedEditorWithProvider(VirtualFile file)
public abstract void closeAllFiles()
public abstract EditorsSplitters getSplitters()
public FileEditor [] openFile(VirtualFile file, boolean focusEditor)
openFile in class FileEditorManagerfile - file to open. File should be valid.
Must be called from EDT.public FileEditor [] openFile(VirtualFile file, boolean focusEditor, boolean searchForOpen)
FileEditorManageropenFile in class FileEditorManagerfile - file to openfocusEditor - true if need to focuspublic abstract Pair<FileEditor[],FileEditorProvider[]> openFileWithProviders(VirtualFile file, boolean focusEditor, boolean searchForSplitter)
public abstract Pair<FileEditor[],FileEditorProvider[]> openFileWithProviders(VirtualFile file, boolean focusEditor, EditorWindow window)
public abstract boolean isChanged(EditorComposite editor)
public abstract EditorWindow getNextWindow(EditorWindow window)
public abstract EditorWindow getPrevWindow(EditorWindow window)
public abstract boolean isInsideChange()
public final java.lang.Object getData(java.lang.String dataId,
Editor editor,
Caret caret)
FileEditorManagerFileEditorManager.registerExtraEditorDataProvider(EditorDataProvider, Disposable) method.getData in class FileEditorManagerpublic void registerExtraEditorDataProvider(EditorDataProvider provider, Disposable parentDisposable)
registerExtraEditorDataProvider in class FileEditorManagerpublic void refreshIcons()
public abstract EditorsSplitters getSplittersFor(java.awt.Component c)
public abstract ActionCallback notifyPublisher(java.lang.Runnable runnable)
public void runWhenLoaded(Editor editor, java.lang.Runnable runnable)
FileEditorManagerFileEditorManager supports asynchronous opening of text editors, i.e. when one of 'openFile' methods returns, returned
editor might not be fully initialized yet. This method allows to delay (if needed) execution of given runnable until editor is
fully loaded.runWhenLoaded in class FileEditorManager