简体   繁体   中英

Eclipse plugin - how to open editor in a view plugin

I haven't written any eclipse plugin before so my question may be stupid to some of you, but is it possible to open one of editors available in Eclipse inside my new eclipse view?

Well, actually I don't know how to open any editor, even simple text area there, I've just searched for some examples, but all of them just display some simple data in table or tree.

Thanks in advance for your help.

Editors and views are different animals, so you can't just mix and match. This FAQ explains the difference.

You can also check this good eclipse plug-in development tutorial . It was a great starting source for me.

As @vainolo has mentioned, editor and views are 2 different things in Eclipse application.

Views are used to display information in an RCP application; they can also be used to change data. Views extend the abstract class ViewPart. Editors extend the abstract EditorPart. Both extend WorkbenchPart.

An editor typically requires that the user explicitly select "save" to apply the changes to the data while a view typically changes the data immediately. All editors are opened in the same area.

For creating an editor in your eclipse application you can follow this Eclipse Editors tutorial .

You may also go through this Eclipse RCP tutorial which describes developing Eclipse RCP applications.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM