Hello! Is it possible to interrupt the resizing of a block on the fly, without adding [crNoResize] to Restrictions? This is when the user has already started to stretch the block and we need to cancel this operation programmatically. Something like "CancelResizing"
I don't think this is possible, no.
Hmm, this feature would be very useful! Our users asked a lot that editing could be canceled, for example, by Escape. There are also other problems associated with this. I see that the TatDiagram.MouseState property is responsible for this, would it be possible to make it not read-only?
Well, then you could ask for cancelation of resizing when pressing Esc.
You can maybe file a feature request so it's not forgotten and we implement it eventually.
It's not save to publish mouse state, there are additional checks that need to be performed on mouse up, for example. So I don't think just setting MouseState will work out of the box.
Note that, though, users can simply finish the resizing operation and then undo their changes if they are not happy with it.
Yes, Undo works, but that's not quite it. I will explain why this is important to us. Double-click to open a modal window. If the user clicked in the area which changes the size (black rectangle) or on the point of rotation, then after closing the modal window, editing will continue. And the user simply closed the window, he does not wait for other actions. I understand that this is the expected behavior of the block (resizing, rotation), but it is very annoying to our users.
That's why I asked about how to interrupt resizing or rotation.
You should not call the modal window on the double click then, but instead send a Windows message that, when processed, opens the modal window.
This way you are sure Diagram and any other mouse/control processing is finished when modal is called.
Thanks for the tip! I'll think about how to do it better.
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.