LabyrinthView.axaml 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213
  1. <UserControl xmlns="https://github.com/avaloniaui"
  2. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  3. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
  6. x:Class="HelloItQuantum.Views.LabyrinthView"
  7. x:DataType="vm:MainWindowViewModel"
  8. xmlns:vm="using:HelloItQuantum.ViewModels"
  9. Background="#CCD7EB"
  10. >
  11. <UserControl.Styles>
  12. <Style Selector="TextBlock">
  13. <Setter Property="FontFamily" Value="{StaticResource BankGothicMediumRUS}"/>
  14. <Setter Property="FontSize" Value="26"/>
  15. </Style>
  16. <Style Selector="Button">
  17. <Setter Property="FontFamily" Value="{StaticResource BankGothicMediumRUS}"/>
  18. <Setter Property="FontSize" Value="26"/>
  19. <Setter Property="CornerRadius" Value="10"/>
  20. <Setter Property="HorizontalContentAlignment" Value="Center"/>
  21. </Style>
  22. <Style Selector="TextBox">
  23. <Setter Property="FontFamily" Value="{StaticResource BankGothicMediumRUS}" />
  24. </Style>
  25. <Style Selector="ComboBox">
  26. <Setter Property="Background" Value="#E6EFD8"/>
  27. <Setter Property="CornerRadius" Value="10"/>
  28. <Setter Property="VerticalAlignment" Value="Center"/>
  29. <Setter Property="BorderBrush" Value="Transparent"/>
  30. </Style>
  31. </UserControl.Styles>
  32. <StackPanel>
  33. <!---->
  34. <Grid Height="{Binding $parent[StackPanel].Bounds.Height}" ColumnDefinitions="*,*,2*" RowDefinitions="*">
  35. <Border Background="#F26527" CornerRadius="15"
  36. Margin="20,25,20,30">
  37. <!--Область "кода"-->
  38. <Panel Grid.Column="0" Grid.Row="0" >
  39. <ScrollViewer>
  40. <UserControl
  41. Content="{Binding LabyrinthVM.ListCommandForRobots}"
  42. HorizontalAlignment="Center"
  43. Margin="10"/>
  44. </ScrollViewer>
  45. </Panel>
  46. </Border>
  47. <!--Область кнопок-->
  48. <Panel Grid.Column="1" HorizontalAlignment="Left" VerticalAlignment="Top" Height="450">
  49. <Border CornerRadius="15"
  50. Margin="0,25,0,30">
  51. <StackPanel Orientation="Vertical" >
  52. <StackPanel Orientation="Horizontal" VerticalAlignment="Top" >
  53. <Button Width="40" CornerRadius="10000" Padding="1" Margin="0,0,5,0">
  54. <Image Source="/Assets/ImgLabyrinth/img_left.png"/>
  55. </Button>
  56. <Button Command="{Binding LabyrinthVM.AddButton}" CommandParameter="left" Width="150" FontSize="24" Background="#F26527">go left</Button>
  57. </StackPanel>
  58. <StackPanel Margin="0,10,0,0" Orientation="Horizontal" VerticalAlignment="Top" >
  59. <Button Width="40" CornerRadius="10000" Padding="1" Margin="0,0,5,0">
  60. <Image Source="/Assets/ImgLabyrinth/img_right.png"/>
  61. </Button>
  62. <Button Command="{Binding LabyrinthVM.AddButton}" CommandParameter="right" Width="150" FontSize="24" Background="#F26527">go right</Button>
  63. </StackPanel>
  64. <StackPanel Margin="0,10,0,0" Orientation="Horizontal" VerticalAlignment="Top" >
  65. <Button Width="40" CornerRadius="10000" Padding="1" Margin="0,0,5,0">
  66. <Image Source="/Assets/ImgLabyrinth/img_up.png"/>
  67. </Button>
  68. <Button Command="{Binding LabyrinthVM.AddButton}" CommandParameter="up" Width="150" FontSize="24" Background="#F26527">go up</Button>
  69. </StackPanel>
  70. <StackPanel Margin="0,10,0,0" Orientation="Horizontal" VerticalAlignment="Top" >
  71. <Button Width="40" CornerRadius="10000" Padding="1" Margin="0,0,5,0">
  72. <Image Source="/Assets/ImgLabyrinth/img_down.png"/>
  73. </Button>
  74. <Button Command="{Binding LabyrinthVM.AddButton}" CommandParameter="down" Width="150" FontSize="24" Background="#F26527">go down</Button>
  75. </StackPanel>
  76. <!--Кнопка Запустить-->
  77. <Border CornerRadius="20" Background="#00A659" BoxShadow="0 5 #006838" Margin="0 20 0 0" HorizontalAlignment="Right" Height="40" Width="200"
  78. IsVisible="True">
  79. <Button Command="{Binding LabyrinthVM.CheckCommand}" VerticalContentAlignment="Center"
  80. CommandParameter="Нет" CornerRadius="20" Height="40" Width="200">
  81. <TextBlock Text="Запустить" TextAlignment="Center" FontSize="24" Foreground="#FFFFFF" />
  82. </Button>
  83. </Border>
  84. <!--Кнопка Очистить-->
  85. <Border CornerRadius="20" Background="#F26527" BoxShadow="0 5 #803717" Margin="-10 20 0 0" HorizontalAlignment="Right" Height="40" Width="200"
  86. IsVisible="True">
  87. <Button Command="{Binding LabyrinthVM.DeleteCommand}" VerticalContentAlignment="Center"
  88. CommandParameter="Нет" CornerRadius="20" Height="40" Width="200">
  89. <TextBlock Text="Очистить" TextAlignment="Center" FontSize="24" Foreground="#FFFFFF" />
  90. </Button>
  91. </Border>
  92. <!--Кнопка Выйти-->
  93. <Border CornerRadius="20" Background="#B21E22" BoxShadow="0 5 #470C0D" Margin="-10 20 0 0" HorizontalAlignment="Right" Height="40" Width="200"
  94. IsVisible="True">
  95. <Button Command="{Binding LabyrinthVM.GoBack}" VerticalContentAlignment="Center"
  96. CommandParameter="Нет" CornerRadius="20" Height="40" Width="200">
  97. <TextBlock Text="Выйти" TextAlignment="Center" FontSize="24" Foreground="#FFFFFF" />
  98. </Button>
  99. </Border>
  100. </StackPanel>
  101. </Border>
  102. </Panel>
  103. <!--Область "поля"-->
  104. <Panel Grid.Column="2" HorizontalAlignment="Left" VerticalAlignment="Center" >
  105. <Border CornerRadius="15"
  106. Margin="0,25,40,30">
  107. <StackPanel Orientation="Horizontal">
  108. <StackPanel VerticalAlignment="Bottom">
  109. <Image Height="150" Source="/Assets/ImgLabyrinth/РоботОранж.png"/>
  110. </StackPanel>
  111. <StackPanel Orientation="Vertical">
  112. <Image Margin="160,0,0,0" Height="150" Source="/Assets/ImgLabyrinth/RobotManipulator.png"/>
  113. <Grid ColumnDefinitions="90,90,90" RowDefinitions="80,80,80,80,80">
  114. <Border Grid.Row="0" Grid.Column="0" Margin="2.5" CornerRadius="15" Background="#F26527">
  115. <TextBlock> </TextBlock>
  116. </Border>
  117. <Border Grid.Row="0" Grid.Column="1" Margin="2.5" CornerRadius="15" Background="#F26527">
  118. <TextBlock> </TextBlock>
  119. </Border>
  120. <Border Grid.Row="0" Grid.Column="2" Margin="2.5" CornerRadius="15" Background="#00A659">
  121. <TextBlock> </TextBlock>
  122. </Border>
  123. <Border Grid.Row="1" Grid.Column="0" Margin="2.5" CornerRadius="15" Background="#F26527">
  124. <TextBlock> </TextBlock>
  125. </Border>
  126. <Border Grid.Row="1" Grid.Column="1" Margin="2.5" CornerRadius="15" Background="#B21E22">
  127. <TextBlock> </TextBlock>
  128. </Border>
  129. <Border Grid.Row="1" Grid.Column="2" Margin="2.5" CornerRadius="15" Background="#B21E22">
  130. <TextBlock> </TextBlock>
  131. </Border>
  132. <Border Grid.Row="2" Grid.Column="0" Margin="2.5" CornerRadius="15" Background="#F26527">
  133. <TextBlock> </TextBlock>
  134. </Border>
  135. <Border Grid.Row="2" Grid.Column="1" Margin="2.5" CornerRadius="15" Background="#F26527">
  136. <TextBlock> </TextBlock>
  137. </Border>
  138. <Border Grid.Row="2" Grid.Column="2" Margin="2.5" CornerRadius="15" Background="#B21E22">
  139. <TextBlock> </TextBlock>
  140. </Border>
  141. <Border Grid.Row="3" Grid.Column="0" Margin="2.5" CornerRadius="15" Background="#B21E22">
  142. <TextBlock> </TextBlock>
  143. </Border>
  144. <Border Grid.Row="3" Grid.Column="1" Margin="2.5" CornerRadius="15" Background="#F26527">
  145. <TextBlock> </TextBlock>
  146. </Border>
  147. <Border Grid.Row="3" Grid.Column="2" Margin="2.5" CornerRadius="15" Background="#B21E22">
  148. <TextBlock> </TextBlock>
  149. </Border>
  150. <Border Grid.Row="4" Grid.Column="0" Margin="2.5" CornerRadius="15" Background="#F26527">
  151. <TextBlock> </TextBlock>
  152. </Border>
  153. <Border Grid.Row="4" Grid.Column="1" Margin="2.5" CornerRadius="15" Background="#F26527">
  154. <TextBlock> </TextBlock>
  155. </Border>
  156. <Border Grid.Row="4" Grid.Column="2" Margin="2.5" CornerRadius="15" Background="#B21E22">
  157. <TextBlock> </TextBlock>
  158. </Border>
  159. </Grid>
  160. </StackPanel>
  161. </StackPanel>
  162. </Border>
  163. </Panel>
  164. <!--Область "поля"-->
  165. <Panel Grid.Row="1" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Bottom" Margin="300, 100,10,10" Height="200" IsVisible="{Binding LabyrinthVM.IsVisibleContextWindow}">
  166. <StackPanel Width="800">
  167. <Image Source="/Assets/ImgLabyrinth/Диалоговое_окно.png" Stretch="Fill" Margin="0,-60,0,0"/>
  168. <!--Текст-->
  169. <StackPanel>
  170. <Button Height="50" Command="" VerticalAlignment="Top" CornerRadius="10000" Padding="1" Margin="50, -230,0,0">
  171. <Image Source="/Assets/ImgHotkeys/КнопкаPlay.png"/>
  172. </Button>
  173. <TextBlock Text="{Binding LabyrinthVM.TextInSP}" TextWrapping="Wrap" Margin="110, -210,15,20" FontSize="22" Foreground="#0534B5"></TextBlock>
  174. <Border CornerRadius="20" Background="#00A659" BoxShadow="0 5 #006838" Margin="0 -130 30 0" HorizontalAlignment="Right" Height="40" Width="200"
  175. IsVisible="True">
  176. <Button Command="{Binding LabyrinthVM.GoNext}" VerticalContentAlignment="Center"
  177. CommandParameter="Нет" CornerRadius="20" Height="40" Width="200">
  178. <TextBlock Text="{Binding LabyrinthVM.TextInBTN}" TextAlignment="Center" FontSize="24" Foreground="#FFFFFF" />
  179. </Button>
  180. </Border>
  181. </StackPanel>
  182. <!--Кнопка Далее-->
  183. </StackPanel>
  184. <StackPanel>
  185. </StackPanel>
  186. </Panel>
  187. </Grid>
  188. <StackPanel>
  189. </StackPanel>
  190. </StackPanel>
  191. </UserControl>