Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 451364

Summary: It should be possible to customize property cell editors in Sirius
Product: [Modeling] Sirius Reporter: Esteban DUGUEPEROUX <esteban.dugueperoux>
Component: DiagramAssignee: Florian Barbin <florian.barbin>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: belqassim.djafer, cedric.brun, esteban.dugueperoux, florian.barbin, jfbraz, laurent.redor, pierre-charles.david
Version: 1.0.0Keywords: triaged
Target Milestone: 3.0.0M6   
Hardware: PC   
OS: Linux   
See Also: https://git.eclipse.org/r/40432
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=96ecae77c9b57d5a76bb2f3d54f758e9fd8ff994
Whiteboard:
Bug Depends on: 438123    
Bug Blocks:    

Description Esteban DUGUEPEROUX CLA 2014-11-13 10:48:52 EST
It should be possible to customize property cell editors in Sirius as it is possible with a standard EMF Tree Viewer.
Examples :
http://eclipser-blog.blogspot.fr/2007/10/custom-property-source-for-emf.html)
http://gmfsamples.tuxfamily.org/wiki/doku.php?id=emf_tutorial5
In a standard EMF tree editor, this is possible by changing the generated code.
Sirius is not generated, so this capability could probably be provided through an extension point (injected in Sirius property sources).

This could allow Sirius users to provide customized cell editors with syntax coloring, completion, ...
Comment 1 Cedric Brun CLA 2014-11-14 07:12:47 EST
Aren't the property source provided by the AdapterFactory used in the property view ?

Are you refering to the property view or something else ?
Comment 2 Esteban DUGUEPEROUX CLA 2014-11-19 04:52:01 EST
Hi Cedric,

Jean-François Brazeau will answer you as soon as.

Best Regards.
Comment 3 Cedric Brun CLA 2014-11-19 05:56:04 EST
Jean-François confirmed that this is about making sure the CellEditor defined in the (potentialy customized) .edit implementation of an Ecore model gets used in the "Semantic" tab of Sirius.
Comment 4 Cedric Brun CLA 2014-11-19 06:23:53 EST
It would essentially means that the code in org.eclipse.sirius.diagram.ui.tools.internal.properties.SemanticPropertySection would have to use an AdapterFactoryContentProvider leveraging the adapter factory and use getPropertySource( on this adapterfactorycontentprovider instead of instantiating a PropertySource (though we should probably keep that as a fall back)

This AdapterFactoryContentProvider should probably not be instantiated each time as it *might* listen to changes and do something or we need to make sure we can dispose it so that it gets removed from the list of listeners of the adapterfactory.
Comment 5 Cedric Brun CLA 2014-11-19 09:38:50 EST
I recall some discussions in EMF core itself about this issue :

See https://bugs.eclipse.org/bugs/show_bug.cgi?id=438123
Comment 6 Eclipse Genie CLA 2015-02-19 09:32:31 EST
WARNING: this patchset contains 1014 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 7 Eclipse Genie CLA 2015-02-19 09:42:06 EST
WARNING: this patchset contains 1014 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 8 Eclipse Genie CLA 2015-02-19 09:50:09 EST
WARNING: this patchset contains 1015 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 9 Eclipse Genie CLA 2015-02-19 11:37:31 EST
WARNING: this patchset contains 1017 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 10 Eclipse Genie CLA 2015-02-20 03:02:57 EST
Gerrit change https://git.eclipse.org/r/40432 was merged to [master].
Commit: http://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=96ecae77c9b57d5a76bb2f3d54f758e9fd8ff994

WARNING: this patchset contains 1017 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 11 Florian Barbin CLA 2015-02-20 04:03:02 EST
Committed on Master.
Comment 12 Belqassim Djafer CLA 2015-04-13 03:51:33 EDT
Verified on Sirius 3.0.0M6
Comment 13 Pierre-Charles David CLA 2015-06-24 11:15:37 EDT
Available in Sirius 3.0.0. See https://wiki.eclipse.org/Sirius/3.0.0.