Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » How to add an extra property to a container style specification?
How to add an extra property to a container style specification? [message #1835363] Tue, 01 December 2020 17:39 Go to next message
Denis Nikiforov is currently offline Denis NikiforovFriend
Messages: 334
Registered: August 2013
Senior Member

I'm trying to customize containers visualization. A label should be displayed on the left side, it's almost work:

1) The problem is that I can't programmatically distinguish usual containers and rotated one. I need a property in a diagram specification to mark rotated containers. Is it possible to add a custom property for Gradient Container styles to a Sirius specification?

Or Is it possible to add a Custom Gradient Container Style, which inherits most of the properties of the default one?

2) Or maybe it will be better to let a user decide whether he wants to rotate the container. Is it possible to add such a property on a diagram level (not specification)?

3) If variants 1 and 2 are very hard to implement, then I can add a property (indicating container display rules) to a corresponding semantic object. However I don't think it's a preferred solution, because it's a pure visualization property, not semantic one.
Re: How to add an extra property to a container style specification? [message #1835487 is a reply to message #1835363] Fri, 04 December 2020 15:32 Go to previous message
Steve Monnier is currently offline Steve MonnierFriend
Messages: 570
Registered: May 2011
Senior Member

It is possibly but you will need to customize.

1) To do it from the odesign editor, you will need to modify the Sirius metamodel and properties view. It is possible but that would require to implement it in Sirius and rebuild it, or that you fork Sirius and to it yourself.
In my opinion, it will be far easier for you to provide a custom style[1].
2) That is also a feature not provided by Sirius, but that could be added. I think that I would provide a new action in the tab-bar using this extension point documentation [2].
3) Indeed, it would be better to avoid adding a graphical information in your semantic object. I would go with the solutions above. By the way, you can implement both solution in order to have the label position decided by the specifier, but still locally modifiable by the end user.

Best regards,


Steve Monnier - Obeo Canada
Need training or professional services for Sirius?

[Updated on: Fri, 04 December 2020 15:33]

Report message to a moderator

Previous Topic:[ANN] Sirius 6.4.0
Next Topic:background color of Project explorer in eclipse
Goto Forum:

Current Time: Wed Sep 28 09:27:35 GMT 2022

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

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

Back to the top