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

Bug 481098

Summary: Mapping with style not allowing resize should not allow to set the size on creation by draging the mouse cursor
Product: [Modeling] Sirius Reporter: Steve Monnier <steve.monnier>
Component: DiagramAssignee: Project Inbox <sirius.diagram-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: esteban.dugueperoux, florian.barbin, jerome.pequery, pierre-charles.david
Version: 3.1.0Keywords: triaged
Target Milestone: ---   
Hardware: All   
OS: All   
See Also: https://git.eclipse.org/r/74782
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=3dcfa218f627f916ab1ebb646a7a64091e7d162a
https://git.eclipse.org/r/88753
https://git.eclipse.org/r/106230
Whiteboard:

Description Steve Monnier CLA 2015-10-30 07:00:53 EDT
With a creation tool, it is possible to define the size of the created element by holding the mouse to define an area that will be covered by the new element. However, this still work if the mapping style defines that the resizing horizontaly or verticaly is not allowed. This creates an element that has not the default size, and it is not possible to resize it to default size.
As you can allow or not the resize horizontaly or verticaly separatly, the above issue should be solved separatly as well. For instance, if the resize is allowed only horizontaly, when the user create a new element and define the area by holding the mouse button, only the horizontal dimension (width then) will be kept. The height will be set as defined in the odesign.
Comment 1 Esteban DUGUEPEROUX CLA 2015-11-06 10:00:20 EST
This is not an issue, you must distinguish sizing and resizing :

- sizing is done at creation time
- resizing is done after creation, the "Allow resizing" feature in odesign is only about changing the size after creation.

Allowing or not sizing at creation is another feature. You can change the status as enhancement if you want this feature request.
Comment 2 Florian Barbin CLA 2015-11-09 03:35:46 EST
Actually this can be seen as a bug since the specifier decided a default size and to do not let the user to modify this size. That looks like an inconsistent behavior to let define the size at the creation time without authorize the resizing later.
Comment 3 Pierre-Charles David CLA 2015-12-01 10:46:18 EST
*** Bug 483380 has been marked as a duplicate of this bug. ***
Comment 4 Eclipse Genie CLA 2016-06-07 10:29:58 EDT
New Gerrit change created: https://git.eclipse.org/r/74782
Comment 6 Steve Monnier CLA 2016-08-19 10:27:30 EDT
A fix has been committed. 

SWTBot tests need to be added. An odesign with 4 different node mapping should be added so we can test to create a node (with drag and drop to define the size) for the 4 different cases:
- mapping with no resize allowed
- mapping with horizontal resize allowed
- mapping with vertical resize allowed
- mapping with both resize allowed
Comment 7 Eclipse Genie CLA 2017-01-16 06:14:23 EST
New Gerrit change created: https://git.eclipse.org/r/88753
Comment 8 Eclipse Genie CLA 2017-10-04 12:23:09 EDT
New Gerrit change created: https://git.eclipse.org/r/106230