-
Notifications
You must be signed in to change notification settings - Fork 298
Expand file tree
/
Copy pathMagnifierExample.xaml
More file actions
32 lines (32 loc) · 1.97 KB
/
MagnifierExample.xaml
File metadata and controls
32 lines (32 loc) · 1.97 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
<UserControl x:Class="WPFDevelopers.Samples.ExampleViews.MagnifierExample"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:controls="clr-namespace:WPFDevelopers.Samples.Controls"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:wd="https://github.com/WPFDevelopersOrg/WPFDevelopers"
xmlns:local="clr-namespace:WPFDevelopers.Samples.ExampleViews"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<controls:CodeViewer Header="{Binding NavigateMenuItem.Name}">
<StackPanel Orientation="Vertical">
<UniformGrid Rows="2">
<CheckBox Content="启动放大镜时隐藏当前窗口"
VerticalAlignment="Bottom" HorizontalAlignment="Center"
IsChecked="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type local:MagnifierExample}}, Path=IsChecked}"/>
<Button Content="放大镜" VerticalAlignment="Top" HorizontalAlignment="Center" Click="Button_Click"
Margin="0,10"/>
</UniformGrid>
<Image Source="pack://application:,,,/WPFDevelopers.Samples;component/Resources/Images/Craouse/0.jpg" Stretch="None"
wd:Magnifier.Add="{x:Static wd:Magnifier.Default}"/>
</StackPanel>
<controls:CodeViewer.SourceCodes>
<controls:SourceCodeModel
CodeSource="/WPFDevelopers.SamplesCode;component/ExampleViews/MagnifierExample.xaml"
CodeType="Xaml"/>
<controls:SourceCodeModel
CodeSource="/WPFDevelopers.SamplesCode;component/ExampleViews/MagnifierExample.xaml.cs"
CodeType="CSharp"/>
</controls:CodeViewer.SourceCodes>
</controls:CodeViewer>
</UserControl>