Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » File in the folder don't associated with the editor
File in the folder don't associated with the editor [message #1791884] Fri, 06 July 2018 13:29 Go to next message
kozhaev Vladimir is currently offline kozhaev VladimirFriend
Messages: 108
Registered: July 2009
Senior Member
Hi all, I have plugin with multipage plug-in extention point. As you can see it associate with txt files. But, problem is that in some folder (it's name is "local") files don't recognised as buinded with my custom editor.

Maybe there are some filter what can stop the file associating in the eclipse, or some listener? If Yes, please describe on what class on interface I need to search

See my extention point bellow


<extension
         point="org.eclipse.ui.editors">
      <editor
            name="Omega Editor"
            extensions="txt"
            contributorClass="com.idc.eclipseplugin.editors.MultiPageEditorContributor"
            class="com.idc.eclipseplugin.editors.OmegaMultiPageEditor"
            id="com.idc.eclipseplugin.editors.OmegaMultiPageEditor">
      </editor>
   </extension>

Re: File in the folder don't associated with the editor [message #1794207 is a reply to message #1791884] Mon, 27 August 2018 13:53 Go to previous message
Jakob Sachs is currently offline Jakob SachsFriend
Messages: 15
Registered: May 2018
Junior Member
I don't know if this is the best way, but I achieved this by creating a new content type.

I have the extensions:
<extension
         point="org.eclipse.core.contenttype.contentTypes">

 <content-type
       base-type="org.eclipse.core.runtime.xml"
       default-charset="UTF-8"
       file-extensions="xml"
       id="myfile"
       name="My File"
       priority="high">
         <describer
               class="org.eclipse.core.runtime.content.XMLRootElementContentDescriber2"
               plugin="org.eclipse.core.runtime">
           ...
          Add your own describer here
           ...
         </describer>
      </content-type>
   </extension>




<extension
         point="org.eclipse.ui.editors">
      <editor
            class="main.java..editor.MyEditor"
            default="true"
            icon="icons/-editor-icon.png"
            id="MyEditor"
            name="My Editor">
             <contentTypeBinding contentTypeId="myplugin.myfile"/>
      </editor>
   </extension>


I hope this helps you ^^
Previous Topic:IWorkbenchBrowserSupport plugin is not working in Oxygen4.7.3a
Next Topic:TextEditor AnnotationModel not supporting multiple Documents ?
Goto Forum:
  


Current Time: Fri Apr 19 11:57:59 GMT 2024

Powered by FUDForum. Page generated in 0.02089 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top