1

I'm developing a program on Microsoft Surface.

And I didn't succeed to make disable completely the shadow. Here is my problem :

http://i61.servimg.com/u/f61/11/31/25/01/sans_t10.png

Heres is the XAML code :

    <s:ScatterViewItem Height="130" x:Name="jetons1" Width="180" CanScale="False" 
       BorderThickness="0" ShowsActivationEffects="False" StaysActive="True" 
       SnapsToDevicePixels="True" Foreground="{x:Null}" Background="{x:Null}" 
       BorderBrush="{x:Null}" />
Isak Savo
  • 34,957
  • 11
  • 60
  • 92

2 Answers2

0

Assuming that item is your ScatterViewItem:

item.ApplyTemplate();
item.Background = new SolidColorBrush(Colors.Transparent);
item.ShowsActivationEffects = false;
Microsoft.Surface.Presentation.Generic.SurfaceShadowChrome ssc;
ssc = item.Template.FindName("shadow", item) as Microsoft.Surface.Presentation.Generic.SurfaceShadowChrome;
ssc.Visibility = Visibility.Hidden;
-1

You can do it. Use Expression Blend to extract template and remove the control named x:name="Shadow". You could do this as well in code-behind. As a Microsoft Surface developer you have access to the community (I think now it's free for all), both solutions were posted.

Sascha
  • 10,231
  • 4
  • 41
  • 65