Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Adding one more image in ShapeNode (Read 1699 times)
Bala
Full Member
***
Offline


I love YaBB 1G - SP1!

Posts: 156
Joined: Apr 21st, 2009
Adding one more image in ShapeNode
Dec 16th, 2011 at 11:25am
Print Post  

Hi,

In our  Shapenode, image region is present at the centre and Node Text region below it for displaying name of shapenode.
We want to add another region in the Left botton on shapenode. (Required Region in the attached image)

Please let us know is this supprted, if yes please let know how this can be achieved.

Thanks,
Balaram
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Adding one more image in ShapeNode
Reply #1 - Dec 19th, 2011 at 7:42am
Print Post  
Hi,

For shape nodes you will have to draw additional images yourself. Either derive from ShapeNode and override its Draw method, or set CustomDraw = Additional and handle the DrawNode event. You can set the target rectangle at the bottom left like this:

Rect imgRect = new Rect(0, node.Bounds.Height - imgHeigt, imgWidth, imgHeight);

Alternatively, use templated nodes as shown in tutorial 3. You can add a second <image> element to the Xaml template to show the additional image.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint