Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Required shadowed selection border (Read 1827 times)
Anshul
Senior Member
****
Offline


I love YaBB 1G - SP1!

Posts: 316
Joined: Apr 3rd, 2009
Required shadowed selection border
Apr 28th, 2010 at 1:13pm
Print Post  
Hi,

In our application, we are using custom selection handle for ShapeNodes. We want some shadow effect in our selection handle. Is it possible to have shadowed selection handle? How?

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


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Required shadowed selection border
Reply #1 - Apr 28th, 2010 at 2:51pm
Print Post  
If you are using DropShadowsEffects, try assigning ones to the nodes' Adorner objects. Otherwise you might run the custom drawing code for a second time with slight offset and in a different color to draw shadows.

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: Required shadowed selection border
Reply #2 - Apr 29th, 2010 at 12:47pm
Print Post  
Hi Stoyan,

Yes, we are using DropShadowEffect in our application. Sorry but we are not able to understand your suggestion, can you please explain in detail?

Please also explain another way in detail.

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


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Required shadowed selection border
Reply #3 - Apr 29th, 2010 at 3:39pm
Print Post  
Selection handles are drawn in a separate visual object placed over the node, called Adorner. So you can add shadows to the handles like this:

node.Adorner.Effect = new DropShadowEffect();

Or the other method is if you call something like DrawRect(brush, x, y, 10, 10) to draw a custom handle, then before it call DrawRect(shbrush, x + shadowOffset, y + shadowOffset, 10, 10) to draw its shadow, perhaps using some semitransparent grayish brush.

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