-
Notifications
You must be signed in to change notification settings - Fork 298
Expand file tree
/
Copy pathWaterfallPanelExample.xaml
More file actions
147 lines (147 loc) · 7.88 KB
/
WaterfallPanelExample.xaml
File metadata and controls
147 lines (147 loc) · 7.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
<UserControl
x:Class="WPFDevelopers.Samples.ExampleViews.WaterfallPanelExample"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:WPFDevelopers.Samples.Controls"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:WPFDevelopers.Samples.ExampleViews"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:wd="https://github.com/WPFDevelopersOrg/WPFDevelopers"
d:DesignHeight="450"
d:DesignWidth="800"
mc:Ignorable="d">
<controls:CodeViewer Header="{Binding NavigateMenuItem.Name}">
<ScrollViewer>
<wd:WaterfallPanel Width="750">
<wd:WaterfallPanel.Resources>
<Style TargetType="Border">
<Setter Property="CornerRadius" Value="10" />
<Setter Property="BorderBrush" Value="LightGray" />
<Setter Property="BorderThickness" Value="1" />
</Style>
<Style TargetType="ImageBrush">
<Setter Property="Stretch" Value="Fill" />
</Style>
<Style TargetType="TextBlock">
<Setter Property="Margin" Value="4,10" />
<Setter Property="Foreground" Value="White" />
</Style>
<Style x:Key="BorderContent" TargetType="Border">
<Setter Property="Height" Value="40" />
<Setter Property="CornerRadius" Value="10,10,0,0" />
<Setter Property="VerticalAlignment" Value="Top" />
<Setter Property="Background">
<Setter.Value>
<LinearGradientBrush Opacity=".3" StartPoint="0,.5" EndPoint="0,1">
<GradientStop Offset="0" Color="DimGray" />
<GradientStop Offset="0.9" Color="Gray" />
<GradientStop Offset="1" Color="Transparent" />
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Style>
</wd:WaterfallPanel.Resources>
<Border Height="340">
<Border.Background>
<ImageBrush ImageSource="http://tse2-mm.cn.bing.net/th/id/OIP-C.WVAYTzW5VMZgAErg-y6EgwAAAA" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="WVAYTzW5VMZgAErg" />
</Border>
</Border>
<Border Height="300">
<Border.Background>
<ImageBrush ImageSource="http://tse1-mm.cn.bing.net/th/id/OIP-C.e51iwDiqzatju6Bf50lJ2QHaMW" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="e51iwDiqzatju6Bf50lJ2QHaMW" />
</Border>
</Border>
<Border Height="280">
<Border.Background>
<ImageBrush ImageSource="http://tse1-mm.cn.bing.net/th/id/OIP-C.dB2fWdfqfr8w3sP7wiboHgHaNK" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="dB2fWdfqfr8w3sP7wiboHgHaNK" />
</Border>
</Border>
<Border Height="350">
<Border.Background>
<ImageBrush ImageSource="http://tse4-mm.cn.bing.net/th/id/OIP-C.IzGLt2NgGhakuvbk008FOwHaK9" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="IzGLt2NgGhakuvbk008FOwHaK9" />
</Border>
</Border>
<Border Height="400">
<Border.Background>
<ImageBrush ImageSource="http://pic4.zhimg.com/v2-6233e57a364dcb3b6c5f066f8b30dab4_r.jpg" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="6233e57a364dcb3b6c5f066f8b30dab4_r" />
</Border>
</Border>
<Border Height="240">
<Border.Background>
<ImageBrush ImageSource="http://tse1-mm.cn.bing.net/th/id/OIP-C.ivs2k5Q7Zx7WRZVuSDUJqQHaJ4" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="ivs2k5Q7Zx7WRZVuSDUJqQHaJ4" />
</Border>
</Border>
<Border Height="290">
<Border.Background>
<ImageBrush ImageSource="http://tse3-mm.cn.bing.net/th/id/OIP-C.sTVQljOS9ntgkUyvDXk68AHaKe" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="sTVQljOS9ntgkUyvDXk68AHaKe" />
</Border>
</Border>
<Border Height="207">
<Border.Background>
<ImageBrush ImageSource="http://tse2-mm.cn.bing.net/th/id/OIP-C.caVFPs_YGiHH-7vOpQ7GqwHaHY" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="7vOpQ7GqwHaHY" />
</Border>
</Border>
<Border Height="200">
<Border.Background>
<ImageBrush ImageSource="http://tse2-mm.cn.bing.net/th/id/OIP-C.T_Zi1o-AYSCp4c00D_zCVAHaHa" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="AYSCp4c00D_zCVAHaHa" />
</Border>
</Border>
<Border Height="220">
<Border.Background>
<ImageBrush ImageSource="http://tse2-mm.cn.bing.net/th/id/OIP-C.-EGv7Ycl5Zu46_YIGjNuDgHaH4" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="EGv7Ycl5Zu46_YIGjNuDgHaH4" />
</Border>
</Border>
<Border Height="200">
<Border.Background>
<ImageBrush ImageSource="http://tse4-mm.cn.bing.net/th/id/OIP-C.TQ1f0BMQ7Bo7PuRKnCJAMAHaHa" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="TQ1f0BMQ7Bo7PuRKnCJAMAHaHa" />
</Border>
</Border>
<Border Height="450">
<Border.Background>
<ImageBrush ImageSource="http://img.zcool.cn/community/01493f5d11d9cca801205e4b24e764.jpg" />
</Border.Background>
<Border Style="{StaticResource BorderContent}">
<TextBlock Text="01493f5d11d9cca801205e4b24e764" />
</Border>
</Border>
</wd:WaterfallPanel>
</ScrollViewer>
<controls:CodeViewer.SourceCodes>
<controls:SourceCodeModel CodeSource="/WPFDevelopers.SamplesCode;component/ExampleViews/WaterfallPanelExample.xaml" CodeType="Xaml" />
<controls:SourceCodeModel CodeSource="/WPFDevelopers.SamplesCode;component/ExampleViews/WaterfallPanelExample.xaml.cs" CodeType="CSharp" />
</controls:CodeViewer.SourceCodes>
</controls:CodeViewer>
</UserControl>