Select subProcess when clicking inside of it

We use a model extension that allows to build larger structures with subProcesses (I will attach a screenshot to visualize our use case). While the editing is currently allowed in the subProcess, too, in our use case, we plan to move the editing of subProcesses to a separate tab, in which the content of it is loaded and can be edited freely. This works really well – however, as soon as we have to zoom out to display the overall model, it is nearly impossible to hit the edges of a subProcess to use the context menu in order to connect these subProcesses with ease.

Therefore, we want to allow users to also select subProcesses, when clicking inside of them (but not hiting another element). Thus, I was wondering if it is possible to detect, e.g., on element.mousedown whether the position of the cursor is inside of a subProcess?

Maybe, I can use a similar function that is used by the connect tool, in which the target is marked in green, as soon as the mouse hovers the subProcess?

Thank you for your help & this awesome library!

1 Like