How to register new FileEditorProvider in system?

What I want to do is creating new editor for the file of special extension.
For that I need Intellij recognize this file when trying to open it in openFileImpl4() function.

FileEditorProviderManagerImpl class has only private methods of registering providers.

Many thanks in advance

Comment actions Permalink

FileEditorProvider implementations are registered via Extension Point with name com.intellij.openapi.fileEditor.FileEditorProvider#EP_FILE_EDITOR_PROVIDER


Comment actions Permalink

Am I right that you mean the following:

add to the plugin.xml file:

<extensionPoint name="fileEditorProvider"

Or not?

Could you please prove a snippet of code?

Comment actions Permalink

There are many samples in IntelliJ Community Edition source code

for example, org.intellij.images.editor.impl.ImageFileEditorProvider which is registered in images/src/META-INF/ImagesPlugin.xml


Please sign in to leave a comment.