Page Index Toggle Pages: 1 [2] 3  Send TopicPrint
Very Hot Topic (More than 25 Replies) Moving shadow not the actual item (Read 21969 times)
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #15 - Oct 26th, 2009 at 3:37pm
Print Post  
1) This is not supported.

2) Try calling diagram.Interaction.CancelNow() in response to the ESC key-down event.

Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #16 - Oct 27th, 2009 at 12:43pm
Print Post  
Thanks Stoyan,

I have tried diagram.Interaction.CancelNow(), it is working fine except one little issue.

When I select any node and drag it, at this time if I press Escape, nothing happens. Escape works when I move the mouse 1 pixel. If I don’t move the mouse, interaction state doesn’t cancel the drag.

I want if I press Escape; node should immediately cancel the drag operation without waiting for mouse to move. Please give your suggestion on this.

Regards,
Anshul
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #17 - Oct 27th, 2009 at 1:55pm
Print Post  
Hi Anshul,

Try the Diagram.CancelDrag method from this version:
https://www.mindfusion.eu/_beta/wpfdiag_canceldrag.zip

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #18 - Oct 27th, 2009 at 2:56pm
Print Post  
Hi Stoyan,

When you are going to release next licensed build of Mindfusion.Diagramming.Wpf. Will that build include this CancelDrag() method ?

Regards,
Anshul
« Last Edit: Oct 28th, 2009 at 8:41am by Anshul »  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #19 - Nov 12th, 2009 at 6:53am
Print Post  
Hi Stoyan,

I am using ModificationEffect Property to view the clone movement effect; this is working fine for me except in one case.

If I select any node in the diagram and than try to move some another node, in this time clone effect not works. I need to select that node than only I can move that node but if not anyone node is selected in the diagram than everything works fine.

Please suggest if anyone node is selected and I want to move another node, how can I get ModificationEffect in that?


Regards,
Anshul
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #20 - Nov 12th, 2009 at 12:23pm
Print Post  
Hi Anshul,

Are you using ModificationStart="AutoHandles" to move nodes without selecting them? This worked fine in my test.

Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #21 - Nov 12th, 2009 at 12:41pm
Print Post  
No, I am using ModificationStart="MoveShades".
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #22 - Nov 12th, 2009 at 12:54pm
Print Post  
You can assign MoveShades to ModificationEffect; and there is a different property called ModificationStart. I was wondering if you are using the latter to allow moving nodes that are not selected, or are doing that by some other means.
« Last Edit: Nov 12th, 2009 at 2:38pm by Stoyo »  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #23 - Nov 12th, 2009 at 1:14pm
Print Post  
Hi Stoyan,

I am using version 2.2.1, it does not have ModificationStyle property. Is it a new one?

Sorry by mistake I have written ModificationStart instead of ModificationEffect.

With your suggestion I have tried this. Now it is working fine but has a small issue. When I move mouse over the node it appears selected.

1). Can I remove this behavior (item appear as selected while mouse over?
2). If not; on mouse leave from that node, node appears selected till some distance. Can I handle this distance or can minimize it?

Regards,
Anshul
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #24 - Nov 12th, 2009 at 2:41pm
Print Post  
Hi Anshul,

Yes, it's ModificationEffect. You could change the HandlesStyle of items dynamically in response to the NodeSelected and Deselected events. For deselected nodes set InvisibleMove, and for selected nodes set SquareHandles (if that's what you were using originally).

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #25 - Nov 13th, 2009 at 9:27am
Print Post  
Hi Stoyan,

I have tried NodeSelected and NodeDeselected events. These events called when we select or deselect the node so in our case it is of no use.

What happening here is that when mouse enters to the node, DrawAdjustmentHandles event of the diagram gets called and it draws a selection rectangle around the nodes (node is not getting select but appear as selected due to selection handle ) but when mouse leave from that node, node appear selected for few distance say 20 pixels and after that selection handle goes away.

I don’t want this selection handle while mouse enter to the node.

Now please suggest how to remove this selection handle.


Regards,
Anshul
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #26 - Nov 13th, 2009 at 10:18am
Print Post  
Quote:
node is not getting select but appear as selected due to selection handle


This happens when ModificationStart = AutoHandles, which you set in order to allow dragging a node without selecting it first. The adjustment handles appear automatically in order to let you grab one and start modifying the node.

If you don't want the handles seen with AutoHandles but still need to move unselected nodes, you can use the InvisibleMove HandleStyle and toggle between it and the style you are currently using. You can change the HandlesStyle value in response to the node selection events, or the global SelectionChanged event.

If you custom-draw the handles anyway, you could move the drawing code to an "if (e.Node.Selected)" block, so they don't appear when the mouse hovers over the node. You won't have to toggle between the different handles styles in such case.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #27 - Nov 18th, 2009 at 1:51pm
Print Post  
Hi Stoyan,

We are using ModificationStart = AutoHandles.

But it is not allowing us to create link between two nodes when we select DrawLink Mode. Instead of that it makes the node to move.

We want both behaviour, when we select DrawLink I should be able to Draw the links , otherwise when I select AutoHandle , the normal behaviour .

Regards,
Anshul
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Moving shadow not the actual item
Reply #28 - Nov 18th, 2009 at 3:20pm
Print Post  
Hi Anshul,

Change the HandlesStyle to a value different from InvisibleMove when setting up your DrawLink mode, or set ModificationStart back to SelectedOnly.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Re: Moving shadow not the actual item
Reply #29 - Nov 20th, 2009 at 8:59am
Print Post  
Hi Stoyan,

Thanks for the reply, that problem is now solved.

I am getting issue with link. link appear selected while mouse move over the diagram.
I have set LinkHitDistance = 3 in my code.

I want link appear selected only when user click over the link.

Please suggest for  this.

Regards,
Anshul
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1 [2] 3 
Send TopicPrint