Drag few custom shapes together and cancel shape resize.

2 posts, 0 answers
  1. Tanya
    Tanya avatar
    2 posts
    Member since:
    Jan 2016

    Posted 04 May Link to this post


    I'm create diagram with custom shapes from type image.

    I have one large custom image shape that look like background image and few small image shapes.

    I need to allow click on diagram and drag all my custom shapes together.

    I use selectAll() method on document.onmousedown.

    The bug: Sometimes when I zoom out and drag right rapidly its dragging only one large custom image shape. 

    How to solve it?

    Or. Can I combine all custom shapes into one group or container to allow to grad them together?

    2. when I use selectAll() method it also allow to resize my shapes. 
       How to cancel resize and allow drag?



  2. Vessy
    Vessy avatar
    1357 posts

    Posted 09 May Link to this post

    Hi Tanya,

    I am not quite sure I understand the exact scenario properly - can you elaborate a bit on the exact implementation that is leading to the experienced behavior? It will be really helpful if you can send us a runnable page reproducing the sace so we can examine the problematic configuration on our side.

    In addition, you can try setting the background of the diagram using a similar CSS style, instead of using additional "background" shape:
        background-image: url('http://pleshka.neocities.org/cloud.png');
        background-repeat: no-repeat;
        top: 0px;

    I hope this helps.

  3. DevCraft R3 2016 release webinar banner
Back to Top