PageStation.xaml 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348
  1. <Page x:Class="NEIntelligentControl2.Pages.BoostStation.PageStation"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:NEIntelligentControl2.Pages.BoostStation"
  7. mc:Ignorable="d"
  8. d:DesignHeight="450" d:DesignWidth="800" Loaded="Page_Loaded" Unloaded="Page_Unloaded">
  9. <Page.Resources>
  10. <Style x:Key="PopupTextBox" TargetType="TextBox">
  11. <Setter Property="MinWidth" Value="60"/>
  12. <Setter Property="Margin" Value="3"/>
  13. <Setter Property="FontSize" Value="14"/>
  14. <Setter Property="Padding" Value="2"/>
  15. <Setter Property="VerticalAlignment" Value="Center"/>
  16. </Style>
  17. <Style x:Key="PopupTestBlock" TargetType="TextBlock">
  18. <Setter Property="VerticalAlignment" Value="Center"/>
  19. <Setter Property="FontSize" Value="14"/>
  20. </Style>
  21. </Page.Resources>
  22. <Grid>
  23. <Grid.RowDefinitions>
  24. <RowDefinition Height="76"/>
  25. <RowDefinition/>
  26. </Grid.RowDefinitions>
  27. <Grid HorizontalAlignment="Center" VerticalAlignment="Top" Width="294" Height="51">
  28. <Grid.Background>
  29. <ImageBrush ImageSource="pack://application:,,,/智动启停;component/Images/BoostStation/boost_station_title.png"/>
  30. </Grid.Background>
  31. <TextBox HorizontalAlignment="Center" VerticalAlignment="Stretch" MinWidth="200" Text="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=StationInfo.Name}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" FontSize="20" Foreground="White" Background="{x:Null}" BorderBrush="{x:Null}">
  32. <TextBox.Style>
  33. <Style TargetType="TextBox">
  34. <Style.Triggers>
  35. <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=IsEditModel}" Value="True">
  36. <Setter Property="Visibility" Value="Visible"/>
  37. </DataTrigger>
  38. <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=IsEditModel}" Value="False">
  39. <Setter Property="Visibility" Value="Collapsed"/>
  40. </DataTrigger>
  41. </Style.Triggers>
  42. </Style>
  43. </TextBox.Style>
  44. </TextBox>
  45. <TextBlock HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=StationInfo.Name}" FontSize="20" Foreground="White">
  46. <TextBlock.Style>
  47. <Style TargetType="TextBlock">
  48. <Style.Triggers>
  49. <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=IsEditModel}" Value="True">
  50. <Setter Property="Visibility" Value="Collapsed"/>
  51. </DataTrigger>
  52. <DataTrigger Binding="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=IsEditModel}" Value="False">
  53. <Setter Property="Visibility" Value="Visible"/>
  54. </DataTrigger>
  55. </Style.Triggers>
  56. </Style>
  57. </TextBlock.Style>
  58. </TextBlock>
  59. </Grid>
  60. <Canvas Grid.Row="1" x:Name="_Canvas" MouseLeftButtonUp="Canvas_MouseLeftButtonUp" MouseMove="Canvas_MouseMove" MouseRightButtonUp="_Canvas_MouseRightButtonUp" Background="#01000000" MouseLeave="_Canvas_MouseLeave" MouseEnter="_Canvas_MouseEnter">
  61. <Canvas.ContextMenu>
  62. <ContextMenu>
  63. <MenuItem Header="编辑" Click="MenuItem_Click" Tag="edit"/>
  64. </ContextMenu>
  65. </Canvas.ContextMenu>
  66. </Canvas>
  67. <Border x:Name="_ToolPane" Visibility="Collapsed" Background="#E5FFFFFF" Margin="10" HorizontalAlignment="Right" VerticalAlignment="Top" CornerRadius="7">
  68. <Border.Effect>
  69. <DropShadowEffect ShadowDepth="0" BlurRadius="9"/>
  70. </Border.Effect>
  71. <StackPanel Orientation="Horizontal">
  72. <ListBox x:Name="_LBTools" Margin="10" Background="Transparent" BorderThickness="0,0,0,0" SelectedIndex="0">
  73. <ListBox.ItemsPanel>
  74. <ItemsPanelTemplate>
  75. <WrapPanel IsItemsHost="True"/>
  76. </ItemsPanelTemplate>
  77. </ListBox.ItemsPanel>
  78. <ListBoxItem x:Name="_LBISelect" Selected="ListBoxItem_Selected" Tag="Select" ToolTip="选择">
  79. <Viewbox Width="15">
  80. <Path Data="M760.32 587.264c9.216 8.704 11.264 19.456 6.144 30.72-5.12 11.776-13.824 17.92-26.624 17.92l-196.096 5.12 94.72 207.36c3.072 7.168 3.072 14.848 0 22.016s-8.192 12.288-15.36 15.36l-37.888 17.92c-7.168 3.072-14.848 3.072-22.016 0s-12.288-8.192-15.36-15.36l-100.864-201.728-144.384 154.624c-5.632 5.632-12.288 8.704-19.968 8.704-3.584 0-7.168-1.024-10.752-2.048-11.776-5.12-17.92-13.824-17.92-26.624v-670.72c0-12.288 6.144-21.504 17.92-26.624 3.584-1.536 7.168-2.048 10.752-2.048 8.192 0 14.848 2.56 19.968 8.704l457.728 456.704z" Fill="#FF515151"/>
  81. </Viewbox>
  82. </ListBoxItem>
  83. <ListBoxItem Selected="ListBoxItem_Selected" Tag="Breaker" ToolTip="断路器">
  84. <Rectangle Fill="#FFA2A2A2" Width="12" Height="19"/>
  85. </ListBoxItem>
  86. <ListBoxItem Selected="ListBoxItem_Selected" ToolTip="开关底座" Tag="SwitchBase">
  87. <Viewbox>
  88. <Canvas Name="g10" Width="16.485" Height="12.299">
  89. <Canvas.RenderTransform>
  90. <TranslateTransform X="-846.12" Y="-159.77"/>
  91. </Canvas.RenderTransform>
  92. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="854.14" Y1="159.77" X2="854.14" Y2="172.07" Name="line2" StrokeThickness="2.5" Stroke="#FF40B9B0" StrokeMiterLimit="10"/>
  93. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="862.6" Y1="165.93" X2="854.14" Y2="165.93" Name="line4" StrokeThickness="2.5" Stroke="#FF40B9B0" StrokeMiterLimit="10"/>
  94. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="850.76" Y1="162.31" X2="850.76" Y2="169.54" Name="line6" StrokeThickness="2.5" Stroke="#FF40B9B0" StrokeMiterLimit="10"/>
  95. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="847.37" Y1="163.73" X2="847.37" Y2="168.12" Name="line8" StrokeThickness="2.5" Stroke="#FF40B9B0" StrokeMiterLimit="10"/>
  96. </Canvas>
  97. </Viewbox>
  98. </ListBoxItem>
  99. <ListBoxItem ToolTip="开关" Selected="ListBoxItem_Selected" Tag="Switch">
  100. <Viewbox Width="15">
  101. <Canvas Name="_11_" Width="22.443" Height="17.266">
  102. <Canvas.RenderTransform>
  103. <TranslateTransform X="-862.63" Y="-77.941"/>
  104. </Canvas.RenderTransform>
  105. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="883.82" Y1="77.941" X2="883.82" Y2="95.207" StrokeThickness="2.5" Stroke="#FF1B9D3A" StrokeMiterLimit="10"/>
  106. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF1B9D3A">
  107. <Path.Data>
  108. <PathGeometry Figures="m867.23 84.51c1.421 0 2.575 1.155 2.575 2.571s-1.155 2.573-2.575 2.573c-1.418 0-2.571-1.155-2.571-2.573-1e-3 -1.417 1.154-2.571 2.571-2.571m0-2.033c-2.543 0-4.604 2.061-4.604 4.604s2.062 4.604 4.604 4.604c2.545 0 4.606-2.063 4.606-4.604s-2.061-4.604-4.606-4.604z" FillRule="NonZero"/>
  109. </Path.Data>
  110. </Path>
  111. <Line xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" X1="881.66" Y1="93.541" X2="870.84" Y2="86.574" StrokeThickness="2" Stroke="#FF1B9D3A" StrokeMiterLimit="10"/>
  112. </Canvas>
  113. </Viewbox>
  114. </ListBoxItem>
  115. <ListBoxItem ToolTip="大手车" Selected="ListBoxItem_Selected" Tag="HandcartBig">
  116. <Viewbox Height="30">
  117. <Canvas Width="14.818" Height="62.064">
  118. <Canvas.RenderTransform>
  119. <TranslateTransform X="-1096.1" Y="-589.33"/>
  120. </Canvas.RenderTransform>
  121. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="1110.4 642.7 1103.6 650.42 1096.6 642.7" Name="polyline2" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  122. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="1110.4 636.85 1103.6 644.57 1096.6 636.85" Name="polyline4" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  123. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="1096.6 605.18 1103.4 597.46 1110.4 605.18" Name="polyline6" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  124. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="1096.6 598.02 1103.4 590.3 1110.4 598.02" Name="polyline8" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  125. </Canvas>
  126. </Viewbox>
  127. </ListBoxItem>
  128. <ListBoxItem ToolTip="小手车" Selected="ListBoxItem_Selected" Tag="HandcartSmall">
  129. <Viewbox Width="10">
  130. <Canvas Name="g6" Width="14.809" Height="16.294">
  131. <Canvas.RenderTransform>
  132. <TranslateTransform X="-727.87" Y="-594.66"/>
  133. </Canvas.RenderTransform>
  134. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="728.36 610.52 735.19 602.79 742.2 610.52" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  135. <Polyline xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Points="728.36 603.36 735.19 595.63 742.2 603.36" FillRule="NonZero" StrokeThickness="1.3" Stroke="#FFFF0000" StrokeMiterLimit="10"/>
  136. </Canvas>
  137. </Viewbox>
  138. </ListBoxItem>
  139. <ListBoxItem ToolTip="数据标签" Selected="ListBoxItem_Selected" Tag="DataLabel">
  140. <Viewbox Width="20">
  141. <Canvas Name="svg6" Width="1024" Height="1024">
  142. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Name="path2" Fill="#FF515151">
  143. <Path.Data>
  144. <PathGeometry Figures="M736 416h-160v64h160v64h-128a64 64 0 0 0-64 64v64a64 64 0 0 0 64 64h192v-256a64.064 64.064 0 0 0-64-64z m0 256h-128v-64h128zM416 288H288a64.064 64.064 0 0 0-64 64v384h64v-160h128v160h64V352a64.064 64.064 0 0 0-64-64z m-128 224v-160h128v160z" FillRule="NonZero"/>
  145. </Path.Data>
  146. </Path>
  147. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Name="path4" Fill="#FF515151">
  148. <Path.Data>
  149. <PathGeometry Figures="M896 896H128a64.064 64.064 0 0 1-64-64V192a64.064 64.064 0 0 1 64-64h768a64.064 64.064 0 0 1 64 64v640a64.064 64.064 0 0 1-64 64zM128 192v640h768V192z" FillRule="NonZero"/>
  150. </Path.Data>
  151. </Path>
  152. </Canvas>
  153. </Viewbox>
  154. </ListBoxItem>
  155. <ListBoxItem ToolTip="标签" Selected="ListBoxItem_Selected" Tag="DataTag">
  156. <Viewbox Width="20">
  157. <Canvas Width="1024" Height="1024">
  158. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  159. <Path.Data>
  160. <PathGeometry Figures="M695.7 118.6H326.9c-58.2 0-105.4 47.2-105.4 105.4v579.6c0 58.2 47.2 105.4 105.4 105.4l184.4-184.4L695.7 909c58.2 0 105.4-47.2 105.4-105.4V224c0-58.2-47.1-105.4-105.4-105.4z" FillRule="NonZero"/>
  161. </Path.Data>
  162. </Path>
  163. </Canvas>
  164. </Viewbox>
  165. </ListBoxItem>
  166. </ListBox>
  167. <Rectangle Height="25" Width="2" Fill="#FF686868" Margin="0,0,5,0"/>
  168. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" Tag="angle" BorderThickness="0,0,0,0" ToolTip="控件方向选择" Margin="5,0">
  169. <Viewbox Width="20">
  170. <Viewbox.RenderTransform>
  171. <TransformGroup>
  172. <ScaleTransform/>
  173. <SkewTransform/>
  174. <RotateTransform Angle="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=Angle}" CenterX="10" CenterY="10"/>
  175. <TranslateTransform/>
  176. </TransformGroup>
  177. </Viewbox.RenderTransform>
  178. <Canvas Name="svg8" Width="1024" Height="1024">
  179. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF8FB3FF">
  180. <Path.Data>
  181. <PathGeometry Figures="M559.795332 978.804414h-95.390684l2.499756 45.195586h90.391173z" FillRule="NonZero"/>
  182. </Path.Data>
  183. </Path>
  184. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF2868F0">
  185. <Path.Data>
  186. <PathGeometry Figures="M567.2946 843.217655H456.90538l4.999512 90.391172h100.390196z" FillRule="NonZero"/>
  187. </Path.Data>
  188. </Path>
  189. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF2C66E1">
  190. <Path.Data>
  191. <PathGeometry Figures="M512.09999 0.09999L240.926472 255.775022h183.282101l30.197051 542.247046h115.488722L599.991407 255.775022h183.282101z" FillRule="NonZero"/>
  192. </Path.Data>
  193. </Path>
  194. </Canvas>
  195. </Viewbox>
  196. </Button>
  197. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" Tag="enlarge" BorderThickness="0,0,0,0" ToolTip="放大" Margin="5,0">
  198. <Viewbox Width="20">
  199. <Canvas Width="1024" Height="1024">
  200. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  201. <Path.Data>
  202. <PathGeometry Figures="M815.3 959.1H208.9c-79.7 0-144.4-64.6-144.4-144.4V208.3c0-79.7 64.6-144.4 144.4-144.4h606.5c79.7 0 144.4 64.6 144.4 144.4v606.5c-0.1 79.7-64.7 144.3-144.5 144.3zM266.6 540.4c0-23.9-19.4-43.3-43.3-43.3S180 516.5 180 540.4v259.9c0 23.9 19.4 43.3 43.3 43.3h259.9c23.9 0 43.3-19.4 43.3-43.3S507.1 757 483.2 757H266.6V540.4z m577.6-317.7c0-23.9-19.4-43.3-43.3-43.3H541c-23.9 0-43.3 19.4-43.3 43.3S517.1 266 541 266h216.6v216.6c0 23.9 19.4 43.3 43.3 43.3s43.3-19.4 43.3-43.3V222.7z" FillRule="NonZero"/>
  203. </Path.Data>
  204. </Path>
  205. </Canvas>
  206. </Viewbox>
  207. </Button>
  208. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" Tag="narrow" BorderThickness="0,0,0,0" ToolTip="缩小" Margin="5,0">
  209. <Viewbox Width="20">
  210. <Canvas Width="1024" Height="1024">
  211. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  212. <Path.Data>
  213. <PathGeometry Figures="M815.5 63.9H208.7c-79.8 0-144.5 64.7-144.5 144.5V815c0 79.8 64.7 144.5 144.5 144.5h606.7c79.8 0 144.5-64.7 144.5-144.5V208.3c0-79.8-64.7-144.4-144.4-144.4z m-289 736.7c0 23.9-19.4 43.3-43.3 43.3s-43.3-19.4-43.3-43.3V583.9H223.2c-23.9 0-43.3-19.4-43.3-43.3s19.4-43.3 43.3-43.3h260c23.9 0 43.3 19.4 43.3 43.3v260z m303.4-303.4h-260c-23.9 0-43.3-19.4-43.3-43.3v-260c0-23.9 19.4-43.3 43.3-43.3s43.3 19.4 43.3 43.3v216.7h216.7c23.9 0 43.3 19.4 43.3 43.3s-19.4 43.3-43.3 43.3z" FillRule="NonZero"/>
  214. </Path.Data>
  215. </Path>
  216. </Canvas>
  217. </Viewbox>
  218. </Button>
  219. <Rectangle Height="25" Width="2" Fill="#FF686868"/>
  220. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" BorderThickness="0,0,0,0" ToolTip="选择背景图片" Tag="background" Margin="5,0">
  221. <Viewbox Width="23">
  222. <Canvas Width="1024" Height="1024">
  223. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  224. <Path.Data>
  225. <PathGeometry Figures="M860.6 261.2c10.8 0 20 9.2 20 20v500c0 10.8-9.2 20-20 20h-696c-10.8 0-20-9.2-20-20v-500c0-10.8 9.2-20 20-20h696m0-80h-696c-55 0-100 45-100 100v500c0 55 45 100 100 100h696c55 0 100-45 100-100v-500c0-55-45-100-100-100z" FillRule="NonZero"/>
  226. </Path.Data>
  227. </Path>
  228. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  229. <Path.Data>
  230. <PathGeometry Figures="M424.1 319.2c-41.4 0-75 33.6-75 75s33.6 75 75 75 75-33.6 75-75-33.6-75-75-75z" FillRule="NonZero"/>
  231. </Path.Data>
  232. </Path>
  233. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Name="path6" Fill="#FF5ABE64">
  234. <Path.Data>
  235. <PathGeometry Figures="M880.6 672.3V565.7l-111.3-98c-8.3-7.3-21.1-6.5-28.3 1.9L530.7 712.8c-7.6 8.8-21.1 9.3-29.3 1.1L389.5 602c-7.9-7.9-20.7-7.8-28.5 0.2l-193.2 199h111.5l82.5-85c7.8-8 20.6-8.1 28.5-0.2l60.6 60.6c6.6 6.6 7.7 16.9 2.9 24.6H560L748.7 583c7.3-8.4 20-9.3 28.3-1.9l103.1 90.8c0.2 0.1 0.4 0.2 0.5 0.4z" FillRule="NonZero"/>
  236. </Path.Data>
  237. </Path>
  238. </Canvas>
  239. </Viewbox>
  240. </Button>
  241. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" BorderThickness="0,0,0,0" ToolTip="删除所有选择的控件" Tag="delete" Margin="5,0">
  242. <Viewbox Width="20">
  243. <Canvas Name="svg10" Width="1024" Height="1024">
  244. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  245. <Path.Data>
  246. <PathGeometry Figures="M804.8128 239.035733A34.133333 34.133333 0 0 1 836.266667 273.2032l-0.1024 2.56-48.725334 617.079467a68.266667 68.266667 0 0 1-64.6144 62.805333l-3.4304 0.085333H304.605867a68.266667 68.266667 0 0 1-67.703467-59.477333l-0.341333-3.413333-48.725334-617.096534a34.133333 34.133333 0 0 1 67.754667-7.901866l0.3072 2.542933L304.605867 887.466667h414.788266l48.708267-617.079467A34.133333 34.133333 0 0 1 802.269867 238.933333l2.56 0.1024z" FillRule="NonZero"/>
  247. </Path.Data>
  248. </Path>
  249. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  250. <Path.Data>
  251. <PathGeometry Figures="M887.466667 204.8a34.133333 34.133333 0 0 1 2.56 68.181333L887.466667 273.066667H136.533333a34.133333 34.133333 0 0 1-2.56-68.181334L136.533333 204.8h750.933334z" FillRule="NonZero"/>
  252. </Path.Data>
  253. </Path>
  254. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  255. <Path.Data>
  256. <PathGeometry Figures="M597.333333 68.266667a102.4 102.4 0 0 1 102.331734 98.56L699.733333 170.666667v68.266666a34.133333 34.133333 0 0 1-68.181333 2.56L631.466667 238.933333v-68.266666a34.133333 34.133333 0 0 0-31.573334-34.048L597.333333 136.533333H426.666667a34.133333 34.133333 0 0 0-34.048 31.573334L392.533333 170.666667v68.266666a34.133333 34.133333 0 0 1-68.181333 2.56L324.266667 238.933333v-68.266666a102.4 102.4 0 0 1 98.56-102.331734L426.666667 68.266667h170.666666z" FillRule="NonZero"/>
  257. </Path.Data>
  258. </Path>
  259. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF00B386">
  260. <Path.Data>
  261. <PathGeometry Figures="M682.666667 750.933333v34.133334a34.133333 34.133333 0 0 1-34.133334 34.133333H375.466667a34.133333 34.133333 0 0 1-34.133334-34.133333v-34.133334h341.333334z" FillRule="NonZero"/>
  262. </Path.Data>
  263. </Path>
  264. </Canvas>
  265. </Viewbox>
  266. </Button>
  267. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" BorderThickness="0,0,0,0" ToolTip="保存所有更改并退出编辑模式" Tag="save" Margin="5,0">
  268. <Viewbox Width="20">
  269. <Canvas Width="1024" Height="1024">
  270. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  271. <Path.Data>
  272. <PathGeometry Figures="M754.8 63.3h-476c-115.5 0-210 94.5-210 210v646c0 22 18 40 40 40h816c22 0 40-18 40-40v-646c0-115.5-94.5-210-210-210z m-108 80v114.9h-260V143.3h260z m238 736h-736v-606c0-34.5 13.6-67.1 38.3-91.7 24.7-24.7 57.3-38.3 91.7-38.3h28v154.9c0 22 18 40 40 40h340c22 0 40-18 40-40V143.3h28c34.5 0 67.1 13.6 91.7 38.3 24.7 24.7 38.3 57.3 38.3 91.7v606z" FillRule="NonZero"/>
  273. </Path.Data>
  274. </Path>
  275. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF5ABE64">
  276. <Path.Data>
  277. <PathGeometry Figures="M656.8 795.3h-280c-22 0-40-18-40-40v-20c0-22 18-40 40-40h280c22 0 40 18 40 40v20c0 22-18 40-40 40z" FillRule="NonZero"/>
  278. </Path.Data>
  279. </Path>
  280. </Canvas>
  281. </Viewbox>
  282. </Button>
  283. <Button HorizontalAlignment="Center" VerticalAlignment="Center" Click="Button_Click" BorderThickness="0,0,0,0" ToolTip="放弃所有更改并退出编辑模式" Tag="close" Margin="5,0">
  284. <Viewbox Width="20">
  285. <Canvas Name="svg4" Width="1024" Height="1024">
  286. <Path xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Fill="#FF515151">
  287. <Path.Data>
  288. <PathGeometry Figures="M512 1024C229.248 1024 0 794.752 0 512S229.248 0 512 0s512 229.248 512 512-229.248 512-512 512z m0-572.330667L300.629333 240.213333a42.538667 42.538667 0 0 0-60.16 0.213334 42.410667 42.410667 0 0 0-0.213333 60.16L451.669333 512 240.213333 723.370667a42.538667 42.538667 0 0 0 0.213334 60.16 42.410667 42.410667 0 0 0 60.16 0.213333L512 572.330667l211.370667 211.413333a42.538667 42.538667 0 0 0 60.16-0.213333 42.410667 42.410667 0 0 0 0.213333-60.16L572.330667 512l211.413333-211.370667a42.538667 42.538667 0 0 0-0.213333-60.16 42.410667 42.410667 0 0 0-60.16-0.213333L512 451.669333z" FillRule="NonZero"/>
  289. </Path.Data>
  290. </Path>
  291. </Canvas>
  292. </Viewbox>
  293. </Button>
  294. </StackPanel>
  295. </Border>
  296. <Popup x:Name="_Popup" Placement="Mouse" PopupAnimation="Fade" Margin="5" AllowsTransparency="True">
  297. <Border CornerRadius="7" Background="#E5FFFFFF" Margin="15">
  298. <Border.Effect>
  299. <DropShadowEffect ShadowDepth="0" BlurRadius="9"/>
  300. </Border.Effect>
  301. <Grid Margin="5">
  302. <Grid.RowDefinitions>
  303. <RowDefinition/>
  304. <RowDefinition/>
  305. <RowDefinition/>
  306. </Grid.RowDefinitions>
  307. <Grid.ColumnDefinitions>
  308. <ColumnDefinition Width="Auto"/>
  309. <ColumnDefinition/>
  310. </Grid.ColumnDefinitions>
  311. <TextBlock Text="标签:" Style="{StaticResource PopupTestBlock}"/>
  312. <TextBox Grid.Column="1" Style="{StaticResource PopupTextBox}" Text="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=DataTag, UpdateSourceTrigger=PropertyChanged}"/>
  313. <Grid Grid.Row="1" Grid.ColumnSpan="2">
  314. <Grid.ColumnDefinitions>
  315. <ColumnDefinition/>
  316. <ColumnDefinition/>
  317. <ColumnDefinition/>
  318. <ColumnDefinition/>
  319. <ColumnDefinition/>
  320. </Grid.ColumnDefinitions>
  321. <TextBlock Text="坐标x:" Style="{StaticResource PopupTestBlock}"/>
  322. <TextBox Grid.Column="1" Style="{StaticResource PopupTextBox}" Text="{Binding RelativeSource={ RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=Coordinate.X, UpdateSourceTrigger=PropertyChanged}"/>
  323. <TextBlock Grid.Column="2" Text="坐标y:" Style="{StaticResource PopupTestBlock}"/>
  324. <TextBox Grid.Column="3" Style="{StaticResource PopupTextBox}" Text="{Binding RelativeSource={ RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=Coordinate.Y, UpdateSourceTrigger=PropertyChanged}"/>
  325. <Grid Grid.Column="4" Margin="5,0">
  326. <Grid.ColumnDefinitions>
  327. <ColumnDefinition/>
  328. <ColumnDefinition/>
  329. <ColumnDefinition/>
  330. </Grid.ColumnDefinitions>
  331. <Grid.RowDefinitions>
  332. <RowDefinition/>
  333. <RowDefinition/>
  334. </Grid.RowDefinitions>
  335. <Button Grid.Row="1" Content="←" Click="Direction_Click" Tag="left" Width="20" Height="20"/>
  336. <Button Grid.Column="1" Content="↑" Click="Direction_Click" Tag="up" Width="20" Height="20"/>
  337. <Button Grid.Row="1" Grid.Column="2" Content="→" Click="Direction_Click" Tag="right" Width="20" Height="20"/>
  338. <Button Grid.Row="1" Grid.Column="1" Content="↓" Click="Direction_Click" Tag="down" Width="20" Height="20"/>
  339. </Grid>
  340. </Grid>
  341. <TextBlock Text="取反:" Grid.Row="2" Style="{StaticResource PopupTestBlock}"/>
  342. <CheckBox Grid.Row="2" Grid.Column="1" IsChecked="{Binding RelativeSource={RelativeSource AncestorType={x:Type Page}, Mode=FindAncestor}, Path=IsNegate, UpdateSourceTrigger=PropertyChanged}" VerticalAlignment="Center"/>
  343. </Grid>
  344. </Border>
  345. </Popup>
  346. </Grid>
  347. </Page>