Skip to main content



      Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Basic question: view or editor
Basic question: view or editor [message #451282] Tue, 20 June 2006 08:06 Go to next message
Eclipse UserFriend
Originally posted by: e.dominguez.ticino.com

Hi all,

I have a question. I'm trying to develop an application. Left side I
have my navigator. Right side my 'forms' or pages.
I.ex. in one of this pages i have 3 fields, some buttons, a file choser,
and a table.

What should i use as 'container' for this purpose? a View (i don't
think)? an editorPart? (but needs a File as parameter... why?) what else?

Thank you very much for a response...

kind regards

e. dominguez
Re: Basic question: view or editor [message #451343 is a reply to message #451282] Tue, 20 June 2006 08:53 Go to previous messageGo to next message
Eclipse UserFriend
We have made use of ViewPart's for this... It depends.
As far as I've understood, the EditorPart does not require the the input
to be an actual file, it just requires that it should implement
IEditorInput. What exactly do you provide as an editor input, is really
up to your editor implementation.

The most obvious downside to having editor is that you can not stack
views and editors in the same tab folder. If you use views OTOH, you run
the risk of having your navigator all over the application window, when
user closes the last details window. You could avoid this probably by
disallowing closing of the "details view" or modifying the presentation
of the workbench.

E. Dominguez kirjutas mulle midagi seesugust:
> Hi all,
>
> I have a question. I'm trying to develop an application. Left side I
> have my navigator. Right side my 'forms' or pages.
> I.ex. in one of this pages i have 3 fields, some buttons, a file choser,
> and a table.
>
> What should i use as 'container' for this purpose? a View (i don't
> think)? an editorPart? (but needs a File as parameter... why?) what else?
>
> Thank you very much for a response...
>
> kind regards
>
> e. dominguez

--
Roland Tepp
Re: Basic question: view or editor [message #451345 is a reply to message #451343] Tue, 20 June 2006 09:00 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: e.dominguez.ticino.com

but what's the purpose of editors then?
i had this problem (navigator all over app win)... how to avoid it?

Has someone an example that shows usage of editors (how to open, and so on)?

Roland Tepp wrote:
> We have made use of ViewPart's for this... It depends.
> As far as I've understood, the EditorPart does not require the the input
> to be an actual file, it just requires that it should implement
> IEditorInput. What exactly do you provide as an editor input, is really
> up to your editor implementation.
>
> The most obvious downside to having editor is that you can not stack
> views and editors in the same tab folder. If you use views OTOH, you run
> the risk of having your navigator all over the application window, when
> user closes the last details window. You could avoid this probably by
> disallowing closing of the "details view" or modifying the presentation
> of the workbench.
>
> E. Dominguez kirjutas mulle midagi seesugust:
>> Hi all,
>>
>> I have a question. I'm trying to develop an application. Left side I
>> have my navigator. Right side my 'forms' or pages.
>> I.ex. in one of this pages i have 3 fields, some buttons, a file
>> choser, and a table.
>>
>> What should i use as 'container' for this purpose? a View (i don't
>> think)? an editorPart? (but needs a File as parameter... why?) what else?
>>
>> Thank you very much for a response...
>>
>> kind regards
>>
>> e. dominguez
>
Re: Basic question: view or editor [message #451351 is a reply to message #451345] Tue, 20 June 2006 10:08 Go to previous messageGo to next message
Eclipse UserFriend
Think of editors as specialized views that have a lifecycle (saving,
etc...) to them and are displayed in a special area of the perspective.
This implies that editors cannot be stacked etc...

Regards
Stefan

E. Dominguez wrote:
> but what's the purpose of editors then?
> i had this problem (navigator all over app win)... how to avoid it?
>
> Has someone an example that shows usage of editors (how to open, and so
> on)?
>
> Roland Tepp wrote:
>> We have made use of ViewPart's for this... It depends.
>> As far as I've understood, the EditorPart does not require the the
>> input to be an actual file, it just requires that it should implement
>> IEditorInput. What exactly do you provide as an editor input, is
>> really up to your editor implementation.
>>
>> The most obvious downside to having editor is that you can not stack
>> views and editors in the same tab folder. If you use views OTOH, you
>> run the risk of having your navigator all over the application window,
>> when user closes the last details window. You could avoid this
>> probably by disallowing closing of the "details view" or modifying the
>> presentation of the workbench.
>>
>> E. Dominguez kirjutas mulle midagi seesugust:
>>> Hi all,
>>>
>>> I have a question. I'm trying to develop an application. Left side I
>>> have my navigator. Right side my 'forms' or pages.
>>> I.ex. in one of this pages i have 3 fields, some buttons, a file
>>> choser, and a table.
>>>
>>> What should i use as 'container' for this purpose? a View (i don't
>>> think)? an editorPart? (but needs a File as parameter... why?) what
>>> else?
>>>
>>> Thank you very much for a response...
>>>
>>> kind regards
>>>
>>> e. dominguez
>>
Re: Basic question: view or editor [message #451358 is a reply to message #451351] Tue, 20 June 2006 11:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: e.dominguez.ticino.com

so what do you suggest to use in my place?
Re: Basic question: view or editor [message #451359 is a reply to message #451358] Tue, 20 June 2006 11:45 Go to previous message
Eclipse UserFriend
If you have a resource (doesn't have to be a file) that is edited and
needs saving, cancel abilites I would suggest an editor. For all other
cases I would suggest a viewpart. Keep in mind that the viewpart can be
dragged around the workbench and be made into a quickview if desired.

See IEditorInput in the help to see what you have to implement. In the
extension point for your editor don't specify a file extension if you
are not using a file.

E. Dominguez wrote:
> so what do you suggest to use in my place?
Previous Topic:Use classes of a required plugins jar file
Next Topic:Building and Testing a JDOM plugin
Goto Forum:
  


Current Time: Sun Oct 26 02:35:34 EDT 2025

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

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

Back to the top