Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [platform-ui-dev] Multiple editors for same resource (how to?)

Bob,
 
Please see the MultiPageEditorExample in the examples zip available off of the download page.
It illustrates how to have an editor containing multiple tabs, where each tab could either be implemented by another editor, or directly using SWT.
Now, this does support the kind of dynamic composition of editors you describe, but it does simplify some of the details of implementing a multi page editor from existing editors.
 
As Randy Hudson describes, the HTML editor in WSAD uses this.
 
If you wish to continue this discussion, could you please move it to the newsgroup.
 
Thanks,
Nick

 
-----platform-ui-dev-admin@xxxxxxxxxxx wrote: -----

To: <platform-ui-dev@xxxxxxxxxxx>
From: "Bob Foster" <bob@xxxxxxxxxx>
Sent by: platform-ui-dev-admin@xxxxxxxxxxx
Date: 03/26/2002 05:42PM
Subject: [platform-ui-dev] Multiple editors for same resource (how to?)

There are many circumstances where multiple editors might be used for the
same resource in rapid sequence (or even simultaneously). E.g., a source
editor in combination with a graphical editor for a Java source file
defining a dialog, a graphical editor for an XML file containing a schema,
an HTML WYSIWYG editor, etc. It is very important from a UI perspective that
these choices be in the user's face and not buried in some configuration
API.

In other IDEs, e.g., JBuilder, XMLSpy, this relationship is often
represented by inner tabs within the resource tab. An example of this
representation in Eclipse is the plugin.xml editor.

A cursory look at editor support tells me that an editor can set itself up
to to be tabbed or not, but I do not find how one plugin can add an editor
tab to a resource "already" edited by another plugin. E.g., a graphical
editor for a Java source file. In fact, IEditorPart javadoc says "... only
one editor can exist for each editor input within a page." It looks like the
user would have to open a different editor each time she wants to switch
between graphical and text views, which seems obscure and very clumsy. It
seems absurd that the only way to accomplish a tabbed representation would
be to, e.g., supply one's own Java editor.

Less clumsy (once the user managed to get the right perspectives open) would
be to switch editors in different perspectives, but the editor re-use policy
seems to work against that approach. E.g., if a user turns off re-use so a
different editor can be seen in the "graphical perspective," what happens in
the debug perspective?

Quite possibly I have missed some feature that makes this scenario possible.
Any insight would be appreciated.

Bob
Object Factory Inc.

_______________________________________________
platform-ui-dev mailing list
platform-ui-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-ui-dev

Back to the top