TextFieldProperty.xaml 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501
  1. <UserControl
  2. x:Class="PDF_Office.Views.Form.TextFieldProperty"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:convert="clr-namespace:PDF_Office.DataConvert"
  6. xmlns:cus="clr-namespace:PDF_Office.CustomControl"
  7. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  8. xmlns:form="clr-namespace:PDF_Office.CustomControl.Form"
  9. xmlns:local="clr-namespace:PDF_Office.Views.Form"
  10. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  11. xmlns:prism="http://prismlibrary.com/"
  12. prism:ViewModelLocator.AutoWireViewModel="True"
  13. xmlns:CompositeControl="clr-namespace:PDF_Office.CustomControl.CompositeControl"
  14. xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
  15. d:DesignHeight="750"
  16. d:DesignWidth="260"
  17. Background="{StaticResource color.sys.layout.mg}"
  18. mc:Ignorable="d">
  19. <UserControl.Resources>
  20. <ResourceDictionary>
  21. <ResourceDictionary.MergedDictionaries>
  22. <ResourceDictionary Source="../../Styles/ListViewStyle.xaml" />
  23. <ResourceDictionary Source="../../Styles/SliderStyle.xaml"/>
  24. </ResourceDictionary.MergedDictionaries>
  25. <convert:InvertBoolConvert x:Key="InvertBoolConvert" />
  26. <Style TargetType="{x:Type TabItem}">
  27. <Setter Property="Width" Value="74.67 " />
  28. <Setter Property="Height" Value="28" />
  29. <Setter Property="BorderThickness" Value="0" />
  30. <Setter Property="Template" Value="{DynamicResource Segmented}" />
  31. </Style>
  32. <Style TargetType="{x:Type Path}">
  33. <Setter Property="Width" Value="16" />
  34. <Setter Property="Height" Value="16" />
  35. <Setter Property="Fill" Value="{StaticResource color.icon.base.neutral.norm.lv1}" />
  36. </Style>
  37. <DataTemplate x:Key="ContentColorTemplate">
  38. <Grid Width="84" Height="24">
  39. <Rectangle Stroke="Red" StrokeThickness="1"/>
  40. <TextBlock Text="Text"/>
  41. </Grid>
  42. </DataTemplate>
  43. <ContextMenu x:Key="ColorBtnFlyoutMenu" FontSize="14">
  44. <ContextMenu.ItemContainerStyle>
  45. <Style TargetType="MenuItem">
  46. <Setter Property="Padding" Value="0,7,0,7" />
  47. <Setter Property="VerticalContentAlignment" Value="Center" />
  48. </Style>
  49. </ContextMenu.ItemContainerStyle>
  50. <MenuItem
  51. Name="EditMenuItem"
  52. Click="EditMenuItem_Click"
  53. Header="Edit"
  54. IsEnabled="True" />
  55. </ContextMenu>
  56. </ResourceDictionary>
  57. </UserControl.Resources>
  58. <Grid ScrollViewer.VerticalScrollBarVisibility="Auto">
  59. <Grid.RowDefinitions>
  60. <RowDefinition Height="auto" />
  61. <RowDefinition Height="*" />
  62. <RowDefinition Height="auto" />
  63. </Grid.RowDefinitions>
  64. <TextBlock
  65. Margin="16,14"
  66. FontFamily="Segoe UI"
  67. FontSize="14"
  68. FontWeight="SemiBold"
  69. Text="Text Field" />
  70. <TabControl
  71. Grid.Row="1"
  72. Margin="16,0"
  73. Padding="0"
  74. Background="Transparent"
  75. BorderThickness="0"
  76. Style="{DynamicResource FormTabControl}">
  77. <TabItem>
  78. <TabItem.Header>
  79. <Path Data="M8.33337 2.75704L3.19495 4.5L8.33337 6.24296L9.93268 5.70047L10.7558 5.42127L11.2376 6.84178L10.4145 7.12098L8.76831 7.67937C8.49068 7.77354 8.17606 7.77354 7.89843 7.67937L1.31361 5.44579C0.999461 5.33923 0.583374 5.03874 0.583374 4.5C0.583374 3.96126 0.999461 3.66077 1.31361 3.55421L7.89843 1.32063C8.17606 1.22646 8.49068 1.22646 8.76831 1.32063L15.3531 3.55421C15.6673 3.66077 16.0834 3.96126 16.0834 4.5C16.0834 5.03874 15.6673 5.33923 15.3531 5.44579L14.53 5.72499L13.7069 6.00419L13.2251 4.58368L13.4718 4.5L8.33337 2.75704ZM8.33337 9.74993L15.1244 7.7797L15.5423 9.2203L8.7427 11.193C8.48085 11.269 8.1859 11.269 7.92405 11.193L1.1244 9.2203L1.54235 7.7797L8.33337 9.74993ZM15.1244 11.2797L8.33337 13.2499L1.54235 11.2797L1.1244 12.7203L7.92405 14.693C8.1859 14.769 8.48085 14.769 8.7427 14.693L15.5423 12.7203L15.1244 11.2797Z" Fill="{StaticResource color.light.gray.11}" />
  80. </TabItem.Header>
  81. <StackPanel Background="Transparent" IsEnabled="{Binding ElementName=ChkLock, Path=IsChecked, Converter={StaticResource InvertBoolConvert}}">
  82. <TextBlock
  83. Margin="0,18,0,10"
  84. Style="{StaticResource PropertyHeaderLv2}"
  85. Text="Name" />
  86. <cus:TextBoxEx x:Name="TbName" Height="32" CornerRadius="4" Text="{Binding NameStr,Mode=TwoWay}" >
  87. <i:Interaction.Triggers>
  88. <i:EventTrigger EventName="TextChanged">
  89. <i:InvokeCommandAction Command="{Binding NameTextChangedCommand}" CommandParameter="{Binding ElementName=TbName,Path=Text}"/>
  90. </i:EventTrigger>
  91. </i:Interaction.Triggers>
  92. </cus:TextBoxEx>
  93. <TextBlock
  94. Margin="0,18,0,10"
  95. Style="{StaticResource PropertyHeaderLv2}"
  96. Text="ToolTip" />
  97. <cus:TextBoxEx x:Name="TbToolTip" Height="32" CornerRadius="4" >
  98. <i:Interaction.Triggers>
  99. <i:EventTrigger EventName="TextChanged">
  100. <i:InvokeCommandAction Command="{Binding ToolTipTextChangedCommand}" CommandParameter="{Binding ElementName=TbToolTip,Path=Text}"/>
  101. </i:EventTrigger>
  102. </i:Interaction.Triggers>
  103. </cus:TextBoxEx>
  104. <TextBlock
  105. Margin="0,18,0,10"
  106. Style="{StaticResource PropertyHeaderLv2}"
  107. Text="Form Field" />
  108. <form:FormFieldCombox x:Name="formCombox" Type="{Binding FormPos,Mode=OneWay}" Height="32" Margin="0,8,0,16" />
  109. <CheckBox x:Name="ReadOnlyCheckBox" Content="Read Only" Command="{Binding IsReadOnlyCheckedCommand}" CommandParameter="{Binding ElementName=ReadOnlyCheckBox,Path=IsChecked}"/>
  110. <CheckBox x:Name="RequiredFieldCheckBox" Margin="0,8" Content="Required field" Command="{Binding RequiredFieldCheckedCommand}" CommandParameter="{Binding ElementName=RequiredFieldCheckBox,Path=IsChecked}"/>
  111. </StackPanel>
  112. </TabItem>
  113. <TabItem>
  114. <TabItem.Header>
  115. <Path Data="M2.5 2.5V4.5H10.5V2.5H2.5ZM2 1C1.44772 1 1 1.44772 1 2V5C1 5.55228 1.44771 6 2 6H11C11.5523 6 12 5.55228 12 5V3.75H13.25V6.58333H8.4C7.76487 6.58333 7.25 7.09821 7.25 7.73333V9H7C6.44772 9 6 9.44772 6 10V14C6 14.5523 6.44772 15 7 15H9C9.55228 15 10 14.5523 10 14V10C10 9.44772 9.55228 9 9 9H8.75V8.08333H13.6C14.2351 8.08333 14.75 7.56846 14.75 6.93333V3.4C14.75 2.76487 14.2351 2.25 13.6 2.25H12V2C12 1.44772 11.5523 1 11 1H2ZM7.50018 13.4998V10.5002H8.49982V13.4998H7.50018Z" Fill="{StaticResource color.light.gray.11}" />
  116. </TabItem.Header>
  117. <Grid IsEnabled="{Binding ElementName=ChkLock, Path=IsChecked, Converter={StaticResource InvertBoolConvert}}" >
  118. <StackPanel>
  119. <StackPanel>
  120. <TextBlock
  121. Margin="0,18,0,10"
  122. Style="{StaticResource PropertyHeaderLv2}"
  123. Text="Set Color" />
  124. <Grid Height="50" >
  125. <Grid.RowDefinitions>
  126. <RowDefinition Height="auto"/>
  127. <RowDefinition Height="auto"/>
  128. </Grid.RowDefinitions>
  129. <Grid.ColumnDefinitions>
  130. <ColumnDefinition Width="*"/>
  131. <ColumnDefinition Width="*"/>
  132. </Grid.ColumnDefinitions>
  133. <RadioButton x:Name="OneBtn" BorderThickness="1" Width="84" Height="24" Grid.Row="0" Grid.Column="0" Tag="One"
  134. Style="{StaticResource BlueBorderRadionButtonWithCorner}" Padding="3"
  135. ContextMenu="{StaticResource ColorBtnFlyoutMenu}"
  136. >
  137. <Grid Width="78" Height="18">
  138. <Rectangle Fill="{Binding ResetColorOne.FillColor}" Stroke="{Binding ResetColorOne.BorderColor}" StrokeThickness="1" VerticalAlignment="Stretch"/>
  139. <TextBlock Text="Text" FontSize="14" LineHeight="22" FontFamily="Segoe UI" Foreground="{Binding ResetColorOne.FontColor}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
  140. </Grid>
  141. <i:Interaction.Triggers>
  142. <i:EventTrigger EventName="Checked">
  143. <i:InvokeCommandAction Command="{Binding ResetColorCheckedBtnCommand}" CommandParameter="{Binding ElementName=OneBtn,Path=Tag}"/>
  144. </i:EventTrigger>
  145. </i:Interaction.Triggers>
  146. </RadioButton>
  147. <RadioButton x:Name="TwoBtn" BorderThickness="1" Width="84" Height="24" Grid.Row="0" Grid.Column="1" Tag="Two"
  148. Style="{StaticResource BlueBorderRadionButtonWithCorner}"
  149. ContextMenu="{StaticResource ColorBtnFlyoutMenu}"
  150. >
  151. <Grid Width="78" Height="18">
  152. <Rectangle Fill="{Binding ResetColorTwo.FillColor}" Stroke="{Binding ResetColorTwo.BorderColor}" StrokeThickness="1" VerticalAlignment="Stretch"/>
  153. <TextBlock Text="Text" FontSize="14" LineHeight="22" FontFamily="Segoe UI" Foreground="{Binding ResetColorTwo.FontColor}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
  154. </Grid>
  155. <i:Interaction.Triggers>
  156. <i:EventTrigger EventName="Checked">
  157. <i:InvokeCommandAction Command="{Binding ResetColorCheckedBtnCommand}" CommandParameter="{Binding ElementName=TwoBtn,Path=Tag}"/>
  158. </i:EventTrigger>
  159. </i:Interaction.Triggers>
  160. </RadioButton>
  161. <RadioButton x:Name="ThreeBtn" BorderThickness="1" Width="84" Height="24" Grid.Row="1" Grid.Column="0" Tag="Three"
  162. Style="{StaticResource BlueBorderRadionButtonWithCorner}"
  163. ContextMenu="{StaticResource ColorBtnFlyoutMenu}"
  164. >
  165. <Grid Width="78" Height="18">
  166. <Rectangle Fill="{Binding ResetColorThree.FillColor}" Stroke="{Binding ResetColorThree.BorderColor}" StrokeThickness="1" VerticalAlignment="Stretch"/>
  167. <TextBlock Text="Text" FontSize="14" LineHeight="22" FontFamily="Segoe UI" Foreground="{Binding ResetColorThree.FontColor}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
  168. </Grid>
  169. <i:Interaction.Triggers>
  170. <i:EventTrigger EventName="Checked">
  171. <i:InvokeCommandAction Command="{Binding ResetColorCheckedBtnCommand}" CommandParameter="{Binding ElementName=ThreeBtn,Path=Tag}"/>
  172. </i:EventTrigger>
  173. </i:Interaction.Triggers>
  174. </RadioButton>
  175. <RadioButton x:Name="ForthBtn" BorderThickness="1" Width="84" Height="24" Grid.Row="1" Grid.Column="1" Tag="Forth"
  176. Style="{StaticResource BlueBorderRadionButtonWithCorner}"
  177. ContextMenu="{StaticResource ColorBtnFlyoutMenu}"
  178. >
  179. <Grid Width="78" Height="18">
  180. <Rectangle Fill="{Binding ResetColorForth.FillColor}" Stroke="{Binding ResetColorForth.BorderColor}" StrokeThickness="1" VerticalAlignment="Stretch"/>
  181. <TextBlock Text="Text" FontSize="14" LineHeight="22" FontFamily="Segoe UI" Foreground="{Binding ResetColorForth.FontColor}" HorizontalAlignment="Center" VerticalAlignment="Center"/>
  182. </Grid>
  183. <i:Interaction.Triggers>
  184. <i:EventTrigger EventName="Checked">
  185. <i:InvokeCommandAction Command="{Binding ResetColorCheckedBtnCommand}" CommandParameter="{Binding ElementName=ForthBtn,Path=Tag}"/>
  186. </i:EventTrigger>
  187. </i:Interaction.Triggers>
  188. </RadioButton>
  189. </Grid>
  190. </StackPanel>
  191. <StackPanel>
  192. <TextBlock
  193. Margin="0,18,0,10"
  194. Style="{StaticResource PropertyHeaderLv2}"
  195. Text="Line" />
  196. <CompositeControl:SlidComboControl x:Name="thickness">
  197. <i:Interaction.Triggers>
  198. <i:EventTrigger EventName="ValueChanged">
  199. <i:InvokeCommandAction Command="{Binding ThicknessChangedCommand}" CommandParameter="{Binding ElementName=thickness,Path=Value}"/>
  200. </i:EventTrigger>
  201. </i:Interaction.Triggers>
  202. </CompositeControl:SlidComboControl>
  203. <StackPanel
  204. x:Name="PnlLineStyle"
  205. Margin="0,20,0,0"
  206. Orientation="Horizontal">
  207. <cus:CustomIconToggleBtn
  208. x:Name="BtnSolidLine"
  209. Width="110"
  210. Height="32"
  211. Click="BtnLineStyle_Click"
  212. Command="{Binding LineStyleCommand}"
  213. CommandParameter="{Binding ElementName=BtnSolidLine, Path=Tag}"
  214. Style="{StaticResource ToggleBtnViewModeStyle}" IsChecked="{Binding IsSolid}"
  215. Tag="Solid">
  216. <Border
  217. Width="108"
  218. Height="30"
  219. Padding="8,0,8,0"
  220. BorderBrush="Black"
  221. BorderThickness="1">
  222. <Line
  223. Stroke="Black"
  224. StrokeThickness="2"
  225. X1="10"
  226. X2="260"
  227. Y1="15"
  228. Y2="15" />
  229. </Border>
  230. </cus:CustomIconToggleBtn>
  231. <cus:CustomIconToggleBtn
  232. x:Name="BtnDottedLine"
  233. Width="110"
  234. Height="32"
  235. Click="BtnLineStyle_Click"
  236. Command="{Binding LineStyleCommand}"
  237. CommandParameter="{Binding ElementName=BtnDottedLine, Path=Tag}"
  238. Style="{StaticResource ToggleBtnViewModeStyle}" IsChecked="{Binding IsSolid,Converter={StaticResource InvertBoolConvert}}"
  239. Tag="Dotted">
  240. <Border
  241. Width="108"
  242. Height="30"
  243. Padding="8,0,8,0"
  244. BorderBrush="Black"
  245. BorderThickness="1">
  246. <Line
  247. Stroke="Black"
  248. StrokeDashArray="2"
  249. StrokeThickness="2"
  250. X1="10"
  251. X2="260"
  252. Y1="15"
  253. Y2="15" />
  254. </Border>
  255. </cus:CustomIconToggleBtn>
  256. </StackPanel>
  257. </StackPanel>
  258. <StackPanel>
  259. <TextBlock
  260. Margin="0,18,0,10"
  261. Style="{StaticResource PropertyHeaderLv2}"
  262. Text="文本" />
  263. <Grid Margin="0,6,0,0">
  264. <Grid.ColumnDefinitions>
  265. <ColumnDefinition Width="auto"></ColumnDefinition>
  266. <ColumnDefinition Width="auto"></ColumnDefinition>
  267. </Grid.ColumnDefinitions>
  268. <Grid.RowDefinitions>
  269. <RowDefinition Height="auto"></RowDefinition>
  270. <RowDefinition Height="auto"></RowDefinition>
  271. <RowDefinition Height="auto"></RowDefinition>
  272. </Grid.RowDefinitions>
  273. <CompositeControl:CustomComboControl x:Name="FontFamilyBox" ItemSource="{Binding Items}" IsValueContent="True" Grid.ColumnSpan="2" Width="228" Height="32">
  274. <i:Interaction.Triggers>
  275. <i:EventTrigger EventName="ValueChanged">
  276. <i:InvokeCommandAction Command="{Binding FontFamilyChangedCommand}" CommandParameter="{Binding ElementName=FontFamilyBox,Path=ValueStr}"/>
  277. </i:EventTrigger>
  278. </i:Interaction.Triggers>
  279. </CompositeControl:CustomComboControl>
  280. <Border Grid.Row="1" BorderBrush="#E2E3E6" Width="148" Height="32" Margin="12,8,4,0" BorderThickness="0">
  281. <Grid>
  282. <ComboBox Name="FontStyleBox" IsReadOnly="True" BorderThickness="1" BorderBrush="#FFE2E3E6" Padding="10 10 0 0" Background="Transparent">
  283. <ComboBox.ItemContainerStyle>
  284. <Style TargetType="{x:Type ComboBoxItem}">
  285. <Setter Property="Padding" Value="10 0 0 0"/>
  286. </Style>
  287. </ComboBox.ItemContainerStyle>
  288. <ComboBoxItem x:Name="RegularItem" Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Regular</ComboBoxItem>
  289. <ComboBoxItem x:Name="BoldItem" Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Bold</ComboBoxItem>
  290. <ComboBoxItem x:Name="ItalicItem" Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Italic</ComboBoxItem>
  291. <ComboBoxItem x:Name="BoldItalicItem" Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Bold Italic</ComboBoxItem>
  292. <i:Interaction.Triggers>
  293. <i:EventTrigger EventName="SelectionChanged">
  294. <i:InvokeCommandAction Command="{Binding FontStyleChangedCommand}" CommandParameter="{Binding ElementName=FontStyleBox,Path=SelectedItem}"/>
  295. </i:EventTrigger>
  296. </i:Interaction.Triggers>
  297. </ComboBox>
  298. <TextBox Name="FontStyleText" IsReadOnly="True" FontFamily="Segoe UI" FontSize="14" Background="White" Padding="10 0 0 0" Height="20" Margin="2,0,35,0"
  299. BorderThickness="0" VerticalAlignment="Center" TextAlignment="Left">
  300. </TextBox>
  301. </Grid>
  302. </Border>
  303. <Border Grid.Row="1" Grid.Column="1" BorderBrush="#E2E3E6" Width="80" Height="32" Margin="-1,8,0,0" BorderThickness="0">
  304. <Grid>
  305. <ComboBox Name="FontSizeBox" BorderThickness="1" Background="Transparent" BorderBrush="#FFE2E3E6"
  306. MaxDropDownHeight="200">
  307. <ComboBox.ItemContainerStyle>
  308. <Style TargetType="{x:Type ComboBoxItem}">
  309. <Setter Property="Padding" Value="10 0 0 0"/>
  310. </Style>
  311. </ComboBox.ItemContainerStyle>
  312. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">6</ComboBoxItem>
  313. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">8</ComboBoxItem>
  314. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">9</ComboBoxItem>
  315. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">10</ComboBoxItem>
  316. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">12</ComboBoxItem>
  317. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">14</ComboBoxItem>
  318. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">18</ComboBoxItem>
  319. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">20</ComboBoxItem>
  320. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">22</ComboBoxItem>
  321. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">24</ComboBoxItem>
  322. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">26</ComboBoxItem>
  323. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">28</ComboBoxItem>
  324. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">32</ComboBoxItem>
  325. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">36</ComboBoxItem>
  326. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">48</ComboBoxItem>
  327. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">72</ComboBoxItem>
  328. <i:Interaction.Triggers>
  329. <i:EventTrigger EventName="SelectionChanged">
  330. <i:InvokeCommandAction Command="{Binding FontSizeChangedCommand}" CommandParameter="{Binding ElementName=FontSizeBox,Path=SelectedItem}"/>
  331. </i:EventTrigger>
  332. </i:Interaction.Triggers>
  333. </ComboBox>
  334. <TextBox Name="FontSizeText" FontFamily="Segoe UI" FontSize="14" Background="White" Height="20" Padding="10 0 0 0" Margin="2,0,35,0"
  335. BorderThickness="0" VerticalAlignment="Center" TextAlignment="Left" IsReadOnly="True">
  336. </TextBox>
  337. </Grid>
  338. </Border>
  339. </Grid>
  340. </StackPanel>
  341. <StackPanel>
  342. <TextBlock
  343. Margin="0,18,0,10"
  344. Style="{StaticResource PropertyHeaderLv2}"
  345. Text="大小" />
  346. <StackPanel Orientation="Horizontal">
  347. <Path Data="M12.9999 8.75012V10.8285L15.8284 8.00006L12.9999 5.17163V7.25012H2.82843V5.17175L0 8.00017L2.82843 10.8286V8.75012H12.9999Z" Fill="#616469"/>
  348. <cus:NumericUpDown Height="32" Width="90"/>
  349. <Path Data="M10.8284 2.82843H8.74999L8.74999 12.9999H10.8285L8.00005 15.8284L5.17163 12.9999H7.24999L7.24999 2.82843H5.17151L7.99994 0L10.8284 2.82843Z" Fill="#616469"/>
  350. <cus:NumericUpDown Height="32" Width="90"/>
  351. </StackPanel>
  352. </StackPanel>
  353. </StackPanel>
  354. </Grid>
  355. </TabItem>
  356. <TabItem>
  357. <TabItem.Header>
  358. <Path Data="M4.91675 3.75V5H6.41675V1H4.91675V2.25H1.66675V3.75H4.91675ZM15.6667 3.75L7.66675 3.75V2.25L15.6667 2.25V3.75ZM1.66675 7.25V8.75H8.91675V10H10.4167V6H8.91675V7.25H1.66675ZM15.6667 8.75L11.6667 8.75V7.25L15.6667 7.25V8.75ZM7.66675 12.25V13.75L15.6667 13.75V12.25L7.66675 12.25ZM4.91675 13.75H1.66675V12.25H4.91675V11H6.41675V15H4.91675V13.75Z" Fill="{StaticResource color.light.gray.11}" />
  359. </TabItem.Header>
  360. <Grid>
  361. <StackPanel IsEnabled="{Binding ElementName=ChkLock, Path=IsChecked, Converter={StaticResource InvertBoolConvert}}">
  362. <TextBlock Text="Alignment"/>
  363. <ComboBox Name="AlignmentBox" BorderThickness="1" Background="Transparent" BorderBrush="#FFE2E3E6"
  364. MaxDropDownHeight="200">
  365. <ComboBox.ItemContainerStyle>
  366. <Style TargetType="{x:Type ComboBoxItem}">
  367. <Setter Property="Padding" Value="10 0 0 0"/>
  368. </Style>
  369. </ComboBox.ItemContainerStyle>
  370. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Left</ComboBoxItem>
  371. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Center</ComboBoxItem>
  372. <ComboBoxItem Height="32" VerticalContentAlignment="Center" Template="{StaticResource comboxitem}">Right</ComboBoxItem>
  373. <i:Interaction.Triggers>
  374. <i:EventTrigger EventName="SelectionChanged">
  375. <i:InvokeCommandAction Command="{Binding AlignmentChangedCommand}" CommandParameter="{Binding ElementName=AlignmentBox,Path=SelectedItem}"/>
  376. </i:EventTrigger>
  377. </i:Interaction.Triggers>
  378. </ComboBox>
  379. <TextBlock Text="Default Value"/>
  380. <cus:TextBoxEx x:Name="DefaultValueBox" Height="150" CornerRadius="4" Text="{Binding FormContent,Mode=TwoWay}" >
  381. <i:Interaction.Triggers>
  382. <i:EventTrigger EventName="TextChanged">
  383. <i:InvokeCommandAction Command="{Binding FormContentTextChangedCommand}" CommandParameter="{Binding ElementName=DefaultValueBox,Path=Text}"/>
  384. </i:EventTrigger>
  385. </i:Interaction.Triggers>
  386. </cus:TextBoxEx>
  387. <CheckBox x:Name="MultiLineCheck" Content="Nulti-line" Command="{Binding IsMultiLineCheckedCommand}" CommandParameter="{Binding ElementName=MultiLineCheck,Path=IsChecked}"/>
  388. <CheckBox x:Name="ScrollToDisplayLongCheck" Content="Scroll to display long text" Command="{Binding IsScrollToDisplayCheckedCommand}" CommandParameter="{Binding ElementName=ScrollToDisplayLongCheck,Path=IsChecked}"/>
  389. </StackPanel>
  390. <StackPanel Visibility="Collapsed" IsEnabled="{Binding ElementName=ChkLock, Path=IsChecked, Converter={StaticResource InvertBoolConvert}}">
  391. <TextBlock
  392. Margin="0,18,0,10"
  393. Style="{StaticResource PropertyHeaderLv2}"
  394. Text="Projects" />
  395. <Grid>
  396. <cus:TextBoxEx
  397. Width="188"
  398. Height="32"
  399. HorizontalAlignment="Left"
  400. CornerRadius="4" />
  401. <Button
  402. Width="32"
  403. HorizontalAlignment="Right"
  404. Style="{StaticResource btn.sec-icon}">
  405. <Path Data="M7.25 8.75V14H8.75V8.75H14V7.25H8.75V2H7.25V7.25H2V8.75H7.25Z" />
  406. </Button>
  407. </Grid>
  408. <TextBlock
  409. Margin="0,18,0,10"
  410. Style="{StaticResource PropertyHeaderLv2}"
  411. Text="Exported Values" />
  412. <cus:TextBoxEx Height="32" CornerRadius="4" />
  413. <ListBox Height="98" Margin="0,8" />
  414. <StackPanel Margin="0,0,0,8" Orientation="Horizontal">
  415. <Button
  416. Width="32"
  417. Height="32"
  418. Style="{StaticResource btn.sec-icon}">
  419. <Path Data="M6 1.75H10V0.25H6V1.75ZM1 4.25H2.25V15C2.25 15.4142 2.58579 15.75 3 15.75H13C13.4142 15.75 13.75 15.4142 13.75 15V4.25H15V2.75H1V4.25ZM3.75 14.25V4.25H12.25V14.25H3.75ZM7.25 6.5V11.5H8.75V6.5H7.25Z" />
  420. </Button>
  421. <Button
  422. Width="32"
  423. Height="32"
  424. Margin="8,0"
  425. Style="{StaticResource btn.sec-icon}">
  426. <Path Data="M8.72505 12.4147L8.72505 1.02539L7.22505 1.02539L7.22505 12.4147L4.9054 10.0951L3.84474 11.1557L7.44471 14.7557C7.7376 15.0486 8.21248 15.0486 8.50537 14.7557L12.1053 11.1557L11.0447 10.0951L8.72505 12.4147Z" />
  427. </Button>
  428. <Button
  429. Width="32"
  430. Height="32"
  431. Style="{StaticResource btn.sec-icon}">
  432. <Path Data="M8.77509 3.58605L11.0947 5.9057L12.1554 4.84504L8.55542 1.24506C8.26253 0.952167 7.78765 0.952167 7.49476 1.24506L3.89478 4.84504L4.95544 5.9057L7.27509 3.58605L7.27509 14.9754L8.77509 14.9754L8.77509 3.58605Z" />
  433. </Button>
  434. </StackPanel>
  435. <CheckBox Margin="0,8,0,4" Content="Sort Items" />
  436. <CheckBox Margin="0,4" Content="Allow users to enter custom text" />
  437. <CheckBox Margin="0,4">
  438. <TextBlock Text="Submit the selected value immediately" TextWrapping="Wrap" />
  439. </CheckBox>
  440. </StackPanel>
  441. </Grid>
  442. </TabItem>
  443. </TabControl>
  444. <Border
  445. Grid.Row="2"
  446. BorderBrush="{StaticResource color.sys.layout.divider}"
  447. BorderThickness="0,1,0,0">
  448. <CheckBox
  449. Name="ChkLock"
  450. Margin="16"
  451. Content="Locked" />
  452. </Border>
  453. </Grid>
  454. </UserControl>