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: 346
Registered: August 2013
Senior Member
Hi

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

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?
index.php/fa/39444/0/

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: 572
Registered: May 2011
Senior Member
Hello,

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

[1] https://www.eclipse.org/sirius/doc/developer/extensions-provide_custom_style.html
[2] https://www.eclipse.org/sirius/doc/developer/extensions-provide_tabbar_extensions.html


Steve Monnier - Obeo Canada
Need training or professional services for Sirius?
http://www.obeodesigner.com/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: Mon Sep 23 23:06:07 GMT 2024

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

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

Back to the top