Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » Sirius as a viewer(Possible to use sirius as a viewer instead of an editor?)
Sirius as a viewer [message #1335997] Tue, 06 May 2014 07:28 Go to next message
Florian Dunz is currently offline Florian DunzFriend
Messages: 20
Registered: March 2014
Junior Member
Hi there,

Sirius is an amazing editor and provides a lot of tools to work with!

Now though I want to use it as a simple viewer. Basically i want to remove the flyout-palette completely (not just the input), pretty much all of the tabbar and forbid any kind of changes made to the representation (except for nagivation operations triggered by a double-click).

I came across your org.eclipse.sirius.business.api.session.SessionListener with some kind of permission implementation. Is this the way to go? Was Sirius made with this kind of thought in mind?

Regards,
Florian
Re: Sirius as a viewer [message #1359763 is a reply to message #1335997] Fri, 16 May 2014 13:45 Go to previous message
Pierre-Charles David is currently offline Pierre-Charles DavidFriend
Messages: 703
Registered: July 2009
Senior Member
Le 06/05/2014 09:28, Florian Dunz a écrit :
> Hi there,

Hi.

> Sirius is an amazing editor and provides a lot of tools to work with!
> Now though I want to use it as a simple viewer. Basically i want to
> remove the flyout-palette completely (not just the input), pretty much
> all of the tabbar and forbid any kind of changes made to the
> representation (except for nagivation operations triggered by a
> double-click).
>
> I came across your
> org.eclipse.sirius.business.api.session.SessionListener with some kind
> of permission implementation. Is this the way to go?

SessionListener is more for reacting to session-wide, coarse-grained
events than for inspecting/controling changes in the semantic models
and/or representations.

> Was Sirius made with this kind of thought in mind?

Not really (and GEF/GMF, on which we rely, neither).

There are some partial solutions possible, which may or may not
correspond to your specific needs:
* Export the diagrams as images and only provide those images to your
users. This can be automated using DialectUIManager.INSTANCE.export(...).
* Create your VSMs with no tools to modify the model. Users can still
create representations and manipulate the layout of the graphical
elements, but can no affect the underlying model. (Note that in such a
case you need to explicitly define some tools like "Delete" to do
nothing, or you will get the default behavior).
* Programmatically install some hooks in Sirius to prevent changes to be
kept/saved. For example a ResourceSetListener in post-commit which
rolls-back the transaction if it performed an unwanted changes. This is
less than ideal in terms of UI because to the user it looks like changes
are allowed, but they have no effect.


Pierre-Charles David - Obeo

Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Previous Topic:Linkage error due to the incompatible Guava versions
Next Topic:Using Sirius on external files (and without the Model Explorer)
Goto Forum:
  


Current Time: Fri Apr 26 15:56:57 GMT 2024

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

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

Back to the top