Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic image is not show according to shape in background. (Read 6610 times)
Yogendra
Junior Member
**
Offline


I Love MindFusion!

Posts: 68
Joined: Dec 27th, 2012
image is not show according to shape in background.
Jan 29th, 2013 at 2:42pm
Print Post  
Hi
I am working diagramming.mindfussion diagram. I can add shape node in diagram like as circle, triangle, rectangle etc. i can assign image in shape. code is here:-

Dim shapeNode as shapeNode=diagram.Selection.Item(0)
shapeNode.Image=bitMapImage


//bitmapImage is object of BitMapImage class and has image which i want to be assigned Image property of shape node.

This working is fine with rectangle shape but circle and other shapes, Image is always rectangle , not according to shape as circle and triangle.

Thanks in advance  Smiley
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: image is not show according to shape in background.
Reply #1 - Jan 29th, 2013 at 7:29pm
Print Post  
You could set the node's Clip property and update it from NodeModifying events:

Code
Select All
node.Clip = node.Shape.CreateOutlineGeometry(
	node.Bounds.Width, node.Bounds.Height, diagram.MeasureUnit); 



I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Yogendra
Junior Member
**
Offline


I Love MindFusion!

Posts: 68
Joined: Dec 27th, 2012
Re: image is not show according to shape in background.
Reply #2 - Jan 30th, 2013 at 5:27am
Print Post  
Thanks God member.

It's solved my lots of problem.  Wink
  
Back to top
 
IP Logged
 
Yogendra
Junior Member
**
Offline


I Love MindFusion!

Posts: 68
Joined: Dec 27th, 2012
Re: image is not show according to shape in background.
Reply #3 - Jan 30th, 2013 at 6:38am
Print Post  
Hi stoyo,

Your solution is working fine. Thanks a lot. But when I re-size my node by dragging it through mouse, the image didn't show at the time of dragging, but as I release the mouse button, the image gets re-sized to its new dimension and is start showing in the the diagram. How to make the image re-size smoothly with the control it is assigned to?  I'll be thankful to you if you help me in solving this issue too.
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: image is not show according to shape in background.
Reply #4 - Jan 30th, 2013 at 7:14am
Print Post  
Do you call this also from the NodeModifying handler?
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint