App.xaml 59 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847
  1. <prism:PrismApplication
  2. x:Class="PDF_Master.App"
  3. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  4. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  5. xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero2"
  6. xmlns:cus="clr-namespace:PDF_Master.CustomControl"
  7. xmlns:local="clr-namespace:PDF_Master"
  8. xmlns:prism="http://prismlibrary.com/"
  9. xmlns:sys="clr-namespace:System;assembly=mscorlib">
  10. <Application.Resources>
  11. <ResourceDictionary>
  12. <ResourceDictionary.MergedDictionaries>
  13. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Themes/Alias_Light.xaml" />
  14. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Themes/Global.xaml" />
  15. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/TabControlStyle.xaml" />
  16. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/SeparatorStyle.xaml" />
  17. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ButtonStyle.xaml" />
  18. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ToggleButton.xaml" />
  19. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/TextBoxStyle.xaml" />
  20. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ComboxStyle.xaml" />
  21. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ListBoxStyle.xaml" />
  22. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/WindowsStyle.xaml" />
  23. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/CustomBtnStyle.xaml" />
  24. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ContainerStyles/ComboxStyle/ComboxItemStyle.xaml" />
  25. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/RadioButtonStyle.xaml" />
  26. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/PathButtonStyle.xaml" />
  27. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ImageButtonStyle.xaml" />
  28. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/PathRadioButtonDictionary.xaml" />
  29. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ImageRadioButtonDictionary.xaml" />
  30. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ContextMenuTextEditStyle.xaml" />
  31. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ContextMenuStyle.xaml" />
  32. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Styles/ContextMenuFormStyle.xaml" />
  33. <!-- Enable show customctrol's correctly UI in Xaml Designer -->
  34. <ResourceDictionary Source="pack://application:,,,/PDF Master;component/Themes/Generic.xaml" />
  35. </ResourceDictionary.MergedDictionaries>
  36. <Style TargetType="{x:Type Hyperlink}">
  37. <Setter Property="Foreground" Value="#477EDE" />
  38. <Setter Property="TextBlock.TextDecorations" Value="{x:Null}" />
  39. <Style.Triggers>
  40. <Trigger Property="IsMouseOver" Value="True">
  41. <Setter Property="Foreground" Value="#6B97E4" />
  42. <!-- 在鼠标悬停显示下划线 -->
  43. <Setter Property="TextBlock.TextDecorations">
  44. <Setter.Value>
  45. <TextDecorationCollection>
  46. <TextDecoration Location="Underline" />
  47. </TextDecorationCollection>
  48. </Setter.Value>
  49. </Setter>
  50. </Trigger>
  51. </Style.Triggers>
  52. </Style>
  53. <!-- Design Token Menu Without Icon -->
  54. <Style x:Key="GlobalMenuItem" TargetType="{x:Type MenuItem}">
  55. <Setter Property="Foreground" Value="{StaticResource color.sys.text.neutral.lv1}" />
  56. <Setter Property="Background" Value="Transparent" />
  57. <Setter Property="Height" Value="32" />
  58. <Setter Property="Margin" Value="8,0" />
  59. <Setter Property="Template">
  60. <Setter.Value>
  61. <ControlTemplate TargetType="{x:Type MenuItem}">
  62. <Border
  63. x:Name="Border"
  64. Background="{TemplateBinding Background}"
  65. BorderBrush="{TemplateBinding BorderBrush}"
  66. BorderThickness="0"
  67. CornerRadius="7">
  68. <Grid>
  69. <Grid.ColumnDefinitions>
  70. <ColumnDefinition
  71. x:Name="ColIcon"
  72. Width="Auto"
  73. SharedSizeGroup="MenuItemIconColumnGroup" />
  74. <ColumnDefinition Width="Auto" SharedSizeGroup="MenuTextColumnGroup" />
  75. <ColumnDefinition Width="Auto" SharedSizeGroup="MenuItemIGTColumnGroup" />
  76. <ColumnDefinition x:Name="ColNext" Width="auto" />
  77. </Grid.ColumnDefinitions>
  78. <ContentPresenter
  79. x:Name="Icon"
  80. Grid.Column="0"
  81. Margin="5,0"
  82. VerticalAlignment="Center"
  83. ContentSource="Icon" />
  84. <Grid
  85. x:Name="GlyphPanel"
  86. Grid.Column="0"
  87. Margin="5,0"
  88. VerticalAlignment="Center"
  89. Visibility="Collapsed">
  90. <Viewbox
  91. Width="18"
  92. Height="18"
  93. VerticalAlignment="Center"
  94. FlowDirection="LeftToRight">
  95. <Path Data="M422.36247 839.786465c-13.320377 13.421684-34.909068 13.421684-48.126091 0l-10.69355-10.800997 0 0-11.398608-11.502985-50.145074-50.544163c-0.097214-0.201591 0-0.500397-0.201591-0.604774L72.380494 533.085224c-13.320377-13.421684-13.320377-35.218106 0-48.535413l72.132854-72.842005c13.319353-13.408381 34.907021-13.408381 48.224328 0l205.814506 209.252815L831.363631 184.208419c13.218046-13.414521 34.806737-13.414521 48.124044 0l72.134901 72.842005c13.317307 13.408381 13.317307 35.113729 0 48.52211L422.36247 839.786465 422.36247 839.786465z" Fill="{TemplateBinding Foreground}" />
  96. </Viewbox>
  97. </Grid>
  98. <ContentPresenter
  99. x:Name="HeaderHost"
  100. Grid.Column="1"
  101. Margin="{TemplateBinding Padding}"
  102. VerticalAlignment="Center"
  103. ContentSource="Header"
  104. RecognizesAccessKey="True" />
  105. <ContentPresenter
  106. x:Name="IGTHost"
  107. Grid.Column="2"
  108. Margin="0,0"
  109. VerticalAlignment="Center"
  110. ContentSource="InputGestureText" />
  111. <Grid
  112. x:Name="ArrowPanel"
  113. Grid.Column="3"
  114. Margin="10,0"
  115. HorizontalAlignment="Right"
  116. VerticalAlignment="Center">
  117. <Path
  118. x:Name="ArrowPanelPath"
  119. HorizontalAlignment="Right"
  120. VerticalAlignment="Center"
  121. Data="M0,0 L0,8 L4,4 z"
  122. Fill="{TemplateBinding Foreground}" />
  123. </Grid>
  124. <Popup
  125. x:Name="SubMenuPopup"
  126. Margin="4"
  127. AllowsTransparency="True"
  128. Focusable="false"
  129. IsOpen="{Binding Path=IsSubmenuOpen, RelativeSource={RelativeSource TemplatedParent}}"
  130. Placement="Right">
  131. <Border
  132. x:Name="SubMenuBorder"
  133. Padding="2,2,2,2"
  134. Background="{StaticResource color.sys.layout.mg}"
  135. BorderBrush="#999999"
  136. BorderThickness="0"
  137. CornerRadius="7"
  138. Margin="4"
  139. Effect="{StaticResource shadow.black-2-8}">
  140. <Grid x:Name="SubMenu" Grid.IsSharedSizeScope="True">
  141. <StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Cycle" />
  142. </Grid>
  143. </Border>
  144. </Popup>
  145. </Grid>
  146. </Border>
  147. <ControlTemplate.Triggers>
  148. <Trigger Property="Role" Value="TopLevelHeader">
  149. <Setter Property="Padding" Value="6,1" />
  150. <Setter TargetName="SubMenuPopup" Property="Placement" Value="Bottom" />
  151. <Setter TargetName="ColIcon" Property="MinWidth" Value="0" />
  152. <Setter TargetName="ColNext" Property="Width" Value="Auto" />
  153. <Setter TargetName="Icon" Property="Visibility" Value="Collapsed" />
  154. <Setter TargetName="GlyphPanel" Property="Visibility" Value="Collapsed" />
  155. <Setter TargetName="IGTHost" Property="Visibility" Value="Collapsed" />
  156. <Setter TargetName="ArrowPanel" Property="Visibility" Value="Collapsed" />
  157. </Trigger>
  158. <Trigger Property="IsHighlighted" Value="true">
  159. <Setter TargetName="Border" Property="Background" Value="{StaticResource color.item-state.sel.bg.lv1}" />
  160. <Setter Property="Foreground" Value="{StaticResource color.sys.text.accent.norm}" />
  161. </Trigger>
  162. <MultiTrigger>
  163. <MultiTrigger.Conditions>
  164. <Condition Property="IsHighlighted" Value="True" />
  165. <Condition Property="Role" Value="TopLevelHeader" />
  166. </MultiTrigger.Conditions>
  167. <MultiTrigger.Setters>
  168. <Setter TargetName="Border" Property="Background" Value="{StaticResource color.sys.layout.mg}" />
  169. </MultiTrigger.Setters>
  170. </MultiTrigger>
  171. <Trigger Property="Role" Value="TopLevelItem">
  172. <Setter Property="Padding" Value="6,1" />
  173. <Setter TargetName="ArrowPanel" Property="Visibility" Value="Collapsed" />
  174. </Trigger>
  175. <Trigger Property="Role" Value="SubmenuHeader">
  176. <Setter Property="Padding" Value="5,2" />
  177. </Trigger>
  178. <Trigger Property="Role" Value="SubmenuItem">
  179. <Setter Property="Padding" Value="5,2" />
  180. <Setter TargetName="ArrowPanel" Property="Visibility" Value="Collapsed" />
  181. </Trigger>
  182. <Trigger Property="Icon" Value="{x:Null}">
  183. <Setter TargetName="Icon" Property="Visibility" Value="Collapsed" />
  184. </Trigger>
  185. <Trigger Property="IsChecked" Value="true">
  186. <Setter TargetName="GlyphPanel" Property="Visibility" Value="Visible" />
  187. <Setter TargetName="Icon" Property="Visibility" Value="Collapsed" />
  188. </Trigger>
  189. <Trigger Property="IsEnabled" Value="false">
  190. <Setter Property="Foreground" Value="{StaticResource color.sys.text.neutral.dis}" />
  191. </Trigger>
  192. </ControlTemplate.Triggers>
  193. </ControlTemplate>
  194. </Setter.Value>
  195. </Setter>
  196. </Style>
  197. <!-- set as defualt MenuItem Style -->
  198. <Style BasedOn="{StaticResource GlobalMenuItem}" TargetType="{x:Type MenuItem}" />
  199. <!-- Design Token ContextMenu -->
  200. <Style TargetType="{x:Type ContextMenu}">
  201. <Setter Property="Template">
  202. <Setter.Value>
  203. <ControlTemplate TargetType="{x:Type ContextMenu}">
  204. <!-- Here is where you change the border thickness to zero on the menu -->
  205. <Border Width="{TemplateBinding Width}" Padding="5">
  206. <Border.Effect>
  207. <DropShadowEffect
  208. BlurRadius="5"
  209. Direction="0"
  210. Opacity="0.16"
  211. ShadowDepth="0"
  212. Color="#000000" />
  213. </Border.Effect>
  214. <!-- 需要补充背景色,如果这里的背景色是透明,按alt消失右键菜单时,会有一瞬间看到透明的右键菜单 -->
  215. <Border
  216. x:Name="Border"
  217. Padding="0,5"
  218. Background="{StaticResource color.sys.layout.mg}"
  219. CornerRadius="5">
  220. <StackPanel
  221. ClipToBounds="True"
  222. IsItemsHost="True"
  223. KeyboardNavigation.DirectionalNavigation="Cycle"
  224. Orientation="Vertical" />
  225. </Border>
  226. </Border>
  227. <ControlTemplate.Triggers>
  228. <Trigger Property="IsMouseOver" Value="true">
  229. <Setter TargetName="Border" Property="Background" Value="{StaticResource color.sys.layout.mg}" />
  230. </Trigger>
  231. </ControlTemplate.Triggers>
  232. </ControlTemplate>
  233. </Setter.Value>
  234. </Setter>
  235. </Style>
  236. <!-- Design Token CheckBox -->
  237. <Style TargetType="{x:Type CheckBox}">
  238. <Setter Property="FocusVisualStyle" Value="{x:Null}" />
  239. <Setter Property="Background" Value="{StaticResource color.icon.checkbox-radio.norm.bg}" />
  240. <Setter Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.norm.border}" />
  241. <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" />
  242. <Setter Property="BorderThickness" Value="1" />
  243. <Setter Property="FontFamily" Value="Segoe UI" />
  244. <Setter Property="FontSize" Value="14" />
  245. <Setter Property="VerticalContentAlignment" Value="Center" />
  246. <Setter Property="Template">
  247. <Setter.Value>
  248. <ControlTemplate TargetType="{x:Type CheckBox}">
  249. <Grid
  250. x:Name="templateRoot"
  251. Background="Transparent"
  252. SnapsToDevicePixels="True">
  253. <Grid.ColumnDefinitions>
  254. <ColumnDefinition Width="Auto" />
  255. <ColumnDefinition Width="*" />
  256. </Grid.ColumnDefinitions>
  257. <Border
  258. x:Name="checkBoxBorder"
  259. Width="14"
  260. Height="14"
  261. Margin="1"
  262. HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
  263. VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
  264. Background="{TemplateBinding Background}"
  265. BorderBrush="{TemplateBinding BorderBrush}"
  266. BorderThickness="{TemplateBinding BorderThickness}"
  267. CornerRadius="2">
  268. <Grid x:Name="markGrid">
  269. <Path
  270. x:Name="optionMark"
  271. Data="M3 7L6.2 10L11 4"
  272. Opacity="0"
  273. Stroke="{StaticResource color.icon.checkbox-radio.norm.bg}"
  274. StrokeLineJoin="Round"
  275. StrokeThickness="1.5">
  276. <Path.RenderTransform>
  277. <TranslateTransform X="-0.5" Y="-1" />
  278. </Path.RenderTransform>
  279. </Path>
  280. <Rectangle
  281. x:Name="indeterminateMark"
  282. Margin="2"
  283. Fill="{StaticResource color.icon.checkbox-radio.norm.border}"
  284. Opacity="0" />
  285. </Grid>
  286. </Border>
  287. <ContentPresenter
  288. x:Name="contentPresenter"
  289. Grid.Column="1"
  290. Margin="{TemplateBinding Padding}"
  291. HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
  292. VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
  293. Focusable="False"
  294. RecognizesAccessKey="True"
  295. SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
  296. </Grid>
  297. <ControlTemplate.Triggers>
  298. <Trigger Property="HasContent" Value="true">
  299. <Setter Property="Padding" Value="4,0,0,0" />
  300. </Trigger>
  301. <Trigger Property="IsMouseOver" Value="true">
  302. <Setter TargetName="checkBoxBorder" Property="Background" Value="{StaticResource color.icon.checkbox-radio.hov.bg}" />
  303. <Setter TargetName="checkBoxBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.hov.border}" />
  304. </Trigger>
  305. <MultiTrigger>
  306. <MultiTrigger.Conditions>
  307. <Condition Property="IsEnabled" Value="false" />
  308. <Condition Property="IsChecked" Value="True" />
  309. </MultiTrigger.Conditions>
  310. <MultiTrigger.Setters>
  311. <Setter TargetName="optionMark" Property="Opacity" Value="1" />
  312. <Setter TargetName="indeterminateMark" Property="Opacity" Value="0" />
  313. <Setter TargetName="checkBoxBorder" Property="Background" Value="{StaticResource color.icon.checkbox-radio.dis.bg}" />
  314. <Setter TargetName="checkBoxBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.dis.border}" />
  315. <Setter TargetName="optionMark" Property="Stroke" Value="{StaticResource color.icon.checkbox-radio.dis.fill}" />
  316. <Setter Property="Foreground" Value="{StaticResource color.sys.text.neutral.dis}" />
  317. </MultiTrigger.Setters>
  318. </MultiTrigger>
  319. <MultiTrigger>
  320. <MultiTrigger.Conditions>
  321. <Condition Property="IsEnabled" Value="false" />
  322. <Condition Property="IsChecked" Value="false" />
  323. </MultiTrigger.Conditions>
  324. <MultiTrigger.Setters>
  325. <Setter TargetName="optionMark" Property="Opacity" Value="0" />
  326. <Setter TargetName="indeterminateMark" Property="Opacity" Value="1" />
  327. <Setter TargetName="checkBoxBorder" Property="Background" Value="{StaticResource color.icon.checkbox-radio.dis.bg}" />
  328. <Setter TargetName="checkBoxBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.dis.border}" />
  329. </MultiTrigger.Setters>
  330. </MultiTrigger>
  331. <!--<Trigger Property="IsPressed" Value="true">
  332. <Setter TargetName="checkBoxBorder" Property="Background" Value="{StaticResource OptionMark.Pressed.Background}" />
  333. <Setter TargetName="checkBoxBorder" Property="BorderBrush" Value="{StaticResource OptionMark.Pressed.Border}" />
  334. <Setter TargetName="optionMark" Property="Fill" Value="{StaticResource OptionMark.Pressed.Glyph}" />
  335. <Setter TargetName="indeterminateMark" Property="Fill" Value="{StaticResource OptionMark.Pressed.Glyph}" />
  336. </Trigger>-->
  337. <Trigger Property="IsChecked" Value="true">
  338. <Setter TargetName="optionMark" Property="Opacity" Value="1" />
  339. <Setter TargetName="indeterminateMark" Property="Opacity" Value="0" />
  340. <Setter TargetName="checkBoxBorder" Property="Background" Value="{StaticResource color.icon.checkbox-radio.sel.bg}" />
  341. <Setter TargetName="checkBoxBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.sel.bg}" />
  342. </Trigger>
  343. <Trigger Property="IsChecked" Value="{x:Null}">
  344. <Setter TargetName="optionMark" Property="Opacity" Value="0" />
  345. <Setter TargetName="indeterminateMark" Property="Opacity" Value="1" />
  346. </Trigger>
  347. </ControlTemplate.Triggers>
  348. </ControlTemplate>
  349. </Setter.Value>
  350. </Setter>
  351. </Style>
  352. <!-- Design Token ComboboxItem -->
  353. <Style TargetType="{x:Type ComboBoxItem}">
  354. <Setter Property="Foreground" Value="{StaticResource color.sys.text.neutral.lv1}" />
  355. <Setter Property="BorderThickness" Value="0" />
  356. <Setter Property="Padding" Value="8,0" />
  357. <Setter Property="Height" Value="32" />
  358. <Setter Property="Template">
  359. <Setter.Value>
  360. <ControlTemplate TargetType="{x:Type ComboBoxItem}">
  361. <Border
  362. Name="Bd"
  363. Padding="{TemplateBinding Control.Padding}"
  364. Background="{TemplateBinding Panel.Background}"
  365. BorderBrush="{TemplateBinding Border.BorderBrush}"
  366. BorderThickness="{TemplateBinding Border.BorderThickness}"
  367. CornerRadius="{StaticResource border-radius.4}"
  368. SnapsToDevicePixels="True">
  369. <ContentPresenter
  370. HorizontalAlignment="{TemplateBinding Control.HorizontalContentAlignment}"
  371. VerticalAlignment="{TemplateBinding Control.VerticalContentAlignment}"
  372. Content="{TemplateBinding ContentControl.Content}"
  373. ContentStringFormat="{TemplateBinding ContentControl.ContentStringFormat}"
  374. ContentTemplate="{TemplateBinding ContentControl.ContentTemplate}"
  375. SnapsToDevicePixels="{TemplateBinding UIElement.SnapsToDevicePixels}" />
  376. </Border>
  377. <ControlTemplate.Triggers>
  378. <Trigger Property="UIElement.IsEnabled" Value="False">
  379. <Setter Property="Foreground" Value="{StaticResource color.sys.text.neutral.dis}" />
  380. </Trigger>
  381. <MultiTrigger>
  382. <MultiTrigger.Conditions>
  383. <Condition Property="Selector.IsSelected" Value="False" />
  384. <Condition Property="UIElement.IsMouseOver" Value="True" />
  385. <Condition Property="UIElement.IsKeyboardFocused" Value="False" />
  386. </MultiTrigger.Conditions>
  387. <Setter TargetName="Bd" Property="Panel.Background" Value="{StaticResource color.item-state.hov.bg}" />
  388. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#A826A0DA" />
  389. </MultiTrigger>
  390. <MultiTrigger>
  391. <MultiTrigger.Conditions>
  392. <Condition Property="Selector.IsSelected" Value="True" />
  393. <Condition Property="UIElement.IsMouseOver" Value="False" />
  394. <Condition Property="UIElement.IsKeyboardFocused" Value="True" />
  395. </MultiTrigger.Conditions>
  396. <Setter TargetName="Bd" Property="Panel.Background" Value="{StaticResource color.item-state.sel.bg.lv1}" />
  397. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#26A0DA" />
  398. <Setter Property="Foreground" Value="{StaticResource color.sys.text.accent.norm}" />
  399. </MultiTrigger>
  400. <MultiTrigger>
  401. <MultiTrigger.Conditions>
  402. <Condition Property="Selector.IsSelected" Value="True" />
  403. <Condition Property="UIElement.IsMouseOver" Value="True" />
  404. </MultiTrigger.Conditions>
  405. <Setter TargetName="Bd" Property="Panel.Background" Value="{StaticResource color.item-state.hov.bg}" />
  406. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#1A477EDE" />
  407. <Setter Property="Foreground" Value="{StaticResource color.sys.text.accent.norm}" />
  408. </MultiTrigger>
  409. <MultiTrigger>
  410. <MultiTrigger.Conditions>
  411. <Condition Property="Selector.IsSelected" Value="True" />
  412. <Condition Property="UIElement.IsMouseOver" Value="False" />
  413. <Condition Property="UIElement.IsKeyboardFocused" Value="False" />
  414. </MultiTrigger.Conditions>
  415. <Setter TargetName="Bd" Property="Panel.Background" Value="{StaticResource color.item-state.sel.bg.lv1}" />
  416. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#DADADA" />
  417. <Setter Property="Foreground" Value="{StaticResource color.sys.text.accent.norm}" />
  418. </MultiTrigger>
  419. <MultiTrigger>
  420. <MultiTrigger.Conditions>
  421. <Condition Property="Selector.IsSelected" Value="False" />
  422. <Condition Property="UIElement.IsMouseOver" Value="False" />
  423. <Condition Property="UIElement.IsKeyboardFocused" Value="True" />
  424. </MultiTrigger.Conditions>
  425. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#26A0DA" />
  426. </MultiTrigger>
  427. <MultiTrigger>
  428. <MultiTrigger.Conditions>
  429. <Condition Property="Selector.IsSelected" Value="False" />
  430. <Condition Property="UIElement.IsMouseOver" Value="True" />
  431. <Condition Property="UIElement.IsKeyboardFocused" Value="True" />
  432. </MultiTrigger.Conditions>
  433. <Setter TargetName="Bd" Property="Panel.Background" Value="{StaticResource color.item-state.hov.bg}" />
  434. <Setter TargetName="Bd" Property="Border.BorderBrush" Value="#1A000000" />
  435. </MultiTrigger>
  436. </ControlTemplate.Triggers>
  437. </ControlTemplate>
  438. </Setter.Value>
  439. </Setter>
  440. </Style>
  441. <Style x:Key="ComboBoxToggleButton" TargetType="{x:Type ToggleButton}">
  442. <Setter Property="OverridesDefaultStyle" Value="true" />
  443. <Setter Property="IsTabStop" Value="false" />
  444. <Setter Property="Focusable" Value="false" />
  445. <Setter Property="FocusVisualStyle" Value="{x:Null}" />
  446. <Setter Property="ClickMode" Value="Press" />
  447. <Setter Property="Template">
  448. <Setter.Value>
  449. <ControlTemplate TargetType="{x:Type ToggleButton}">
  450. <Border
  451. x:Name="templateRoot"
  452. Background="{TemplateBinding Background}"
  453. BorderBrush="{StaticResource color.field.border.norm}"
  454. BorderThickness="{TemplateBinding BorderThickness}"
  455. CornerRadius="{StaticResource border-radius.4}"
  456. SnapsToDevicePixels="true">
  457. <Border
  458. x:Name="splitBorder"
  459. Width="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}"
  460. Margin="8,0"
  461. HorizontalAlignment="Right"
  462. BorderBrush="Transparent"
  463. BorderThickness="0"
  464. SnapsToDevicePixels="true">
  465. <Path
  466. x:Name="arrow"
  467. Width="12"
  468. Height="12"
  469. Margin="0"
  470. HorizontalAlignment="Center"
  471. VerticalAlignment="Center"
  472. Data="M6 7.56434L2.03039 3.59473L0.969727 4.65539L5.46967 9.15533C5.76256 9.44822 6.23743 9.44822 6.53033 9.15533L11.0303 4.65539L9.9696 3.59473L6 7.56434Z"
  473. Fill="{StaticResource color.icon.arrow.gray.def}" />
  474. </Border>
  475. </Border>
  476. <ControlTemplate.Triggers>
  477. <MultiDataTrigger>
  478. <MultiDataTrigger.Conditions>
  479. <Condition Binding="{Binding IsEditable, RelativeSource={RelativeSource AncestorType={x:Type ComboBox}}}" Value="true" />
  480. <Condition Binding="{Binding IsMouseOver, RelativeSource={RelativeSource Self}}" Value="false" />
  481. <Condition Binding="{Binding IsPressed, RelativeSource={RelativeSource Self}}" Value="false" />
  482. <Condition Binding="{Binding IsEnabled, RelativeSource={RelativeSource Self}}" Value="true" />
  483. </MultiDataTrigger.Conditions>
  484. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.norm}" />
  485. </MultiDataTrigger>
  486. <Trigger Property="IsMouseOver" Value="true">
  487. <Setter TargetName="arrow" Property="Fill" Value="{StaticResource color.icon.arrow.accent.hov}" />
  488. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.hov}" />
  489. </Trigger>
  490. <MultiDataTrigger>
  491. <MultiDataTrigger.Conditions>
  492. <Condition Binding="{Binding IsMouseOver, RelativeSource={RelativeSource Self}}" Value="true" />
  493. <Condition Binding="{Binding IsEditable, RelativeSource={RelativeSource AncestorType={x:Type ComboBox}}}" Value="false" />
  494. </MultiDataTrigger.Conditions>
  495. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.hov}" />
  496. </MultiDataTrigger>
  497. <MultiDataTrigger>
  498. <MultiDataTrigger.Conditions>
  499. <Condition Binding="{Binding IsMouseOver, RelativeSource={RelativeSource Self}}" Value="true" />
  500. <Condition Binding="{Binding IsEditable, RelativeSource={RelativeSource AncestorType={x:Type ComboBox}}}" Value="true" />
  501. </MultiDataTrigger.Conditions>
  502. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.hov}" />
  503. </MultiDataTrigger>
  504. <Trigger Property="IsPressed" Value="true">
  505. <Setter TargetName="arrow" Property="Fill" Value="{StaticResource color.icon.arrow.accent.hov}" />
  506. </Trigger>
  507. <Trigger Property="IsFocused" Value="True">
  508. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.focus}" />
  509. <Setter TargetName="templateRoot" Property="Effect" Value="{StaticResource shadow.blue-0-4}" />
  510. </Trigger>
  511. <Trigger Property="IsChecked" Value="True">
  512. <Setter TargetName="arrow" Property="LayoutTransform">
  513. <Setter.Value>
  514. <RotateTransform Angle="180" />
  515. </Setter.Value>
  516. </Setter>
  517. </Trigger>
  518. <Trigger Property="IsEnabled" Value="false">
  519. <Setter TargetName="arrow" Property="Fill" Value="{StaticResource color.icon.arrow.gray.dis}" />
  520. <Setter TargetName="templateRoot" Property="Background" Value="{StaticResource color.field.bg.dis}" />
  521. <Setter TargetName="templateRoot" Property="BorderBrush" Value="{StaticResource color.field.border.dis}" />
  522. </Trigger>
  523. </ControlTemplate.Triggers>
  524. </ControlTemplate>
  525. </Setter.Value>
  526. </Setter>
  527. </Style>
  528. <ControlTemplate x:Key="ComboBoxTemplate" TargetType="{x:Type ComboBox}">
  529. <Grid
  530. x:Name="templateRoot"
  531. Background="Transparent"
  532. SnapsToDevicePixels="true">
  533. <Grid.ColumnDefinitions>
  534. <ColumnDefinition Width="*" />
  535. <ColumnDefinition Width="0" MinWidth="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}" />
  536. </Grid.ColumnDefinitions>
  537. <Popup
  538. x:Name="PART_Popup"
  539. Grid.ColumnSpan="2"
  540. Margin="1"
  541. AllowsTransparency="true"
  542. IsOpen="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
  543. Placement="Bottom"
  544. PopupAnimation="{DynamicResource {x:Static SystemParameters.ComboBoxPopupAnimationKey}}">
  545. <Themes:SystemDropShadowChrome
  546. x:Name="shadow"
  547. MinWidth="{Binding ActualWidth, ElementName=templateRoot}"
  548. MaxHeight="{TemplateBinding MaxDropDownHeight}"
  549. Color="Transparent">
  550. <Border
  551. x:Name="dropDownBorder"
  552. Margin="0,4,0,0"
  553. Background="{StaticResource color.sys.layout.anti}"
  554. BorderBrush="{DynamicResource {x:Static SystemColors.WindowFrameBrushKey}}"
  555. BorderThickness="0"
  556. CornerRadius="{StaticResource radius.base.m}"
  557. Effect="{StaticResource shadow.neutral.m}">
  558. <ScrollViewer x:Name="DropDownScrollViewer">
  559. <Grid HorizontalAlignment="Stretch" SnapsToDevicePixels="True">
  560. <!-- 圆角背景 -->
  561. <Border
  562. x:Name="Bd"
  563. HorizontalAlignment="Stretch"
  564. Background="{StaticResource color.sys.layout.anti}"
  565. BorderThickness="1"
  566. CornerRadius="7">
  567. <!-- 面板内容 -->
  568. <StackPanel
  569. Margin="4"
  570. HorizontalAlignment="Stretch"
  571. IsItemsHost="True"
  572. KeyboardNavigation.DirectionalNavigation="Contained" />
  573. </Border>
  574. </Grid>
  575. </ScrollViewer>
  576. </Border>
  577. </Themes:SystemDropShadowChrome>
  578. </Popup>
  579. <ToggleButton
  580. x:Name="toggleButton"
  581. Grid.ColumnSpan="2"
  582. Background="{TemplateBinding Background}"
  583. BorderBrush="{TemplateBinding BorderBrush}"
  584. BorderThickness="{TemplateBinding BorderThickness}"
  585. IsChecked="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
  586. Style="{StaticResource ComboBoxToggleButton}" />
  587. <ContentPresenter
  588. x:Name="contentPresenter"
  589. Margin="{TemplateBinding Padding}"
  590. HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
  591. VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
  592. Content="{TemplateBinding SelectionBoxItem}"
  593. ContentStringFormat="{TemplateBinding SelectionBoxItemStringFormat}"
  594. ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}"
  595. ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}"
  596. IsHitTestVisible="false"
  597. SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
  598. </Grid>
  599. <ControlTemplate.Triggers>
  600. <Trigger SourceName="PART_Popup" Property="HasDropShadow" Value="true">
  601. <Setter TargetName="shadow" Property="Margin" Value="5" />
  602. </Trigger>
  603. <Trigger Property="HasItems" Value="false">
  604. <Setter TargetName="dropDownBorder" Property="Height" Value="95" />
  605. </Trigger>
  606. <Trigger Property="IsEnabled" Value="false">
  607. <Setter Property="Foreground" Value="{StaticResource color.field.text.dis}" />
  608. </Trigger>
  609. <MultiTrigger>
  610. <MultiTrigger.Conditions>
  611. <Condition Property="IsGrouping" Value="true" />
  612. <Condition Property="VirtualizingPanel.IsVirtualizingWhenGrouping" Value="false" />
  613. </MultiTrigger.Conditions>
  614. <Setter Property="ScrollViewer.CanContentScroll" Value="false" />
  615. </MultiTrigger>
  616. </ControlTemplate.Triggers>
  617. </ControlTemplate>
  618. <SolidColorBrush x:Key="TextBox.Static.Background" Color="#FFFFFFFF" />
  619. <Style x:Key="ComboBoxEditableTextBox" TargetType="{x:Type TextBox}">
  620. <Setter Property="OverridesDefaultStyle" Value="true" />
  621. <Setter Property="AllowDrop" Value="true" />
  622. <Setter Property="MinWidth" Value="0" />
  623. <Setter Property="MinHeight" Value="0" />
  624. <Setter Property="FocusVisualStyle" Value="{x:Null}" />
  625. <Setter Property="ScrollViewer.PanningMode" Value="VerticalFirst" />
  626. <Setter Property="Stylus.IsFlicksEnabled" Value="False" />
  627. <Setter Property="Template">
  628. <Setter.Value>
  629. <ControlTemplate TargetType="{x:Type TextBox}">
  630. <ScrollViewer
  631. x:Name="PART_ContentHost"
  632. Background="Transparent"
  633. Focusable="false"
  634. HorizontalScrollBarVisibility="Hidden"
  635. VerticalScrollBarVisibility="Hidden" />
  636. </ControlTemplate>
  637. </Setter.Value>
  638. </Setter>
  639. </Style>
  640. <ControlTemplate x:Key="ComboBoxEditableTemplate" TargetType="{x:Type ComboBox}">
  641. <Grid x:Name="templateRoot" SnapsToDevicePixels="true">
  642. <Grid.ColumnDefinitions>
  643. <ColumnDefinition Width="*" />
  644. <ColumnDefinition Width="0" MinWidth="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}" />
  645. </Grid.ColumnDefinitions>
  646. <Popup
  647. x:Name="PART_Popup"
  648. Grid.ColumnSpan="2"
  649. AllowsTransparency="true"
  650. IsOpen="{Binding IsDropDownOpen, RelativeSource={RelativeSource TemplatedParent}}"
  651. Placement="Bottom"
  652. PopupAnimation="{DynamicResource {x:Static SystemParameters.ComboBoxPopupAnimationKey}}">
  653. <Themes:SystemDropShadowChrome
  654. x:Name="shadow"
  655. MinWidth="{Binding ActualWidth, ElementName=templateRoot}"
  656. MaxHeight="{TemplateBinding MaxDropDownHeight}"
  657. Color="Transparent">
  658. <Border
  659. x:Name="dropDownBorder"
  660. Background="{DynamicResource {x:Static SystemColors.WindowBrushKey}}"
  661. BorderBrush="{DynamicResource {x:Static SystemColors.WindowFrameBrushKey}}"
  662. BorderThickness="1">
  663. <ScrollViewer x:Name="DropDownScrollViewer">
  664. <Grid x:Name="grid" RenderOptions.ClearTypeHint="Enabled">
  665. <Canvas
  666. x:Name="canvas"
  667. Width="0"
  668. Height="0"
  669. HorizontalAlignment="Left"
  670. VerticalAlignment="Top">
  671. <Rectangle
  672. x:Name="opaqueRect"
  673. Width="{Binding ActualWidth, ElementName=dropDownBorder}"
  674. Height="{Binding ActualHeight, ElementName=dropDownBorder}"
  675. Fill="{Binding Background, ElementName=dropDownBorder}" />
  676. </Canvas>
  677. <ItemsPresenter
  678. x:Name="ItemsPresenter"
  679. KeyboardNavigation.DirectionalNavigation="Contained"
  680. SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
  681. </Grid>
  682. </ScrollViewer>
  683. </Border>
  684. </Themes:SystemDropShadowChrome>
  685. </Popup>
  686. <ToggleButton
  687. x:Name="toggleButton"
  688. Grid.ColumnSpan="2"
  689. Background="{TemplateBinding Background}"
  690. BorderBrush="{TemplateBinding BorderBrush}"
  691. BorderThickness="{TemplateBinding BorderThickness}"
  692. IsChecked="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
  693. Style="{StaticResource ComboBoxToggleButton}" />
  694. <Border
  695. x:Name="border"
  696. Margin="3,1,8,1"
  697. Background="{StaticResource TextBox.Static.Background}">
  698. <cus:TextBoxEx
  699. x:Name="PART_EditableTextBox"
  700. Padding="0"
  701. VerticalAlignment="Center"
  702. IsReadOnly="{Binding IsReadOnly, RelativeSource={RelativeSource TemplatedParent}}"
  703. PlaceholderText="eg.1,3-5,10"
  704. ShowClose="False"
  705. Style="{StaticResource InnerTextBox}" />
  706. </Border>
  707. </Grid>
  708. <ControlTemplate.Triggers>
  709. <Trigger Property="IsEnabled" Value="false">
  710. <Setter TargetName="border" Property="Opacity" Value="0.56" />
  711. </Trigger>
  712. <Trigger Property="IsKeyboardFocusWithin" Value="true">
  713. <Setter Property="Foreground" Value="Black" />
  714. </Trigger>
  715. <Trigger SourceName="PART_Popup" Property="HasDropShadow" Value="true">
  716. <Setter TargetName="shadow" Property="Margin" Value="0,0,5,5" />
  717. <Setter TargetName="shadow" Property="Color" Value="#71000000" />
  718. </Trigger>
  719. <Trigger Property="HasItems" Value="false">
  720. <Setter TargetName="dropDownBorder" Property="Height" Value="95" />
  721. </Trigger>
  722. <MultiTrigger>
  723. <MultiTrigger.Conditions>
  724. <Condition Property="IsGrouping" Value="true" />
  725. <Condition Property="VirtualizingPanel.IsVirtualizingWhenGrouping" Value="false" />
  726. </MultiTrigger.Conditions>
  727. <Setter Property="ScrollViewer.CanContentScroll" Value="false" />
  728. </MultiTrigger>
  729. <Trigger SourceName="DropDownScrollViewer" Property="ScrollViewer.CanContentScroll" Value="false">
  730. <Setter TargetName="opaqueRect" Property="Canvas.Top" Value="{Binding VerticalOffset, ElementName=DropDownScrollViewer}" />
  731. <Setter TargetName="opaqueRect" Property="Canvas.Left" Value="{Binding HorizontalOffset, ElementName=DropDownScrollViewer}" />
  732. </Trigger>
  733. </ControlTemplate.Triggers>
  734. </ControlTemplate>
  735. <!-- Design Token ComBobox -->
  736. <Style TargetType="{x:Type ComboBox}">
  737. <Setter Property="FocusVisualStyle" Value="{StaticResource FocusVisual}" />
  738. <Setter Property="Background" Value="{StaticResource color.field.bg.def}" />
  739. <Setter Property="BorderBrush" Value="{StaticResource color.field.border.norm}" />
  740. <Setter Property="Foreground" Value="{StaticResource color.field.text.act}" />
  741. <Setter Property="BorderThickness" Value="{StaticResource border-width.1}" />
  742. <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto" />
  743. <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto" />
  744. <Setter Property="VerticalContentAlignment" Value="Center" />
  745. <Setter Property="Padding" Value="8,3,9,3" />
  746. <Setter Property="ScrollViewer.CanContentScroll" Value="true" />
  747. <Setter Property="ScrollViewer.PanningMode" Value="Both" />
  748. <Setter Property="Stylus.IsFlicksEnabled" Value="False" />
  749. <Setter Property="Template" Value="{StaticResource ComboBoxTemplate}" />
  750. <Style.Triggers>
  751. <Trigger Property="IsEditable" Value="true">
  752. <Setter Property="IsTabStop" Value="false" />
  753. <Setter Property="Padding" Value="2,3,5,3" />
  754. <Setter Property="Template" Value="{StaticResource ComboBoxEditableTemplate}" />
  755. </Trigger>
  756. </Style.Triggers>
  757. </Style>
  758. <!-- Design Token RadionButton -->
  759. <Style TargetType="{x:Type RadioButton}">
  760. <Setter Property="FocusVisualStyle" Value="{x:Null}" />
  761. <Setter Property="Background" Value="{StaticResource color.icon.checkbox-radio.norm.bg}" />
  762. <Setter Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.norm.border}" />
  763. <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" />
  764. <Setter Property="BorderThickness" Value="1" />
  765. <Setter Property="Padding" Value="8,0,0,0" />
  766. <Setter Property="Template">
  767. <Setter.Value>
  768. <ControlTemplate TargetType="{x:Type RadioButton}">
  769. <Grid
  770. x:Name="templateRoot"
  771. Background="Transparent"
  772. SnapsToDevicePixels="True">
  773. <Grid.ColumnDefinitions>
  774. <ColumnDefinition Width="Auto" />
  775. <ColumnDefinition Width="*" />
  776. </Grid.ColumnDefinitions>
  777. <Border
  778. x:Name="radioButtonBorder"
  779. Width="14"
  780. Height="14"
  781. HorizontalAlignment="Center"
  782. VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
  783. Background="{TemplateBinding Background}"
  784. BorderBrush="{TemplateBinding BorderBrush}"
  785. BorderThickness="{TemplateBinding BorderThickness}"
  786. CornerRadius="100">
  787. <Grid x:Name="markGrid" Margin="1.8">
  788. <Ellipse
  789. x:Name="optionMark"
  790. MinWidth="6"
  791. MinHeight="6"
  792. Fill="{StaticResource color.icon.checkbox-radio.sel.bg}"
  793. Opacity="0" />
  794. </Grid>
  795. </Border>
  796. <ContentPresenter
  797. x:Name="contentPresenter"
  798. Grid.Column="1"
  799. Margin="{TemplateBinding Padding}"
  800. HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
  801. VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
  802. Focusable="False"
  803. RecognizesAccessKey="True"
  804. SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
  805. </Grid>
  806. <ControlTemplate.Triggers>
  807. <!--<Trigger Property="HasContent" Value="true">
  808. <Setter Property="Padding" Value="4,-1,0,0" />
  809. </Trigger>-->
  810. <Trigger Property="IsMouseOver" Value="true">
  811. <Setter TargetName="radioButtonBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.hov.border}" />
  812. </Trigger>
  813. <Trigger Property="IsEnabled" Value="false">
  814. <Setter TargetName="radioButtonBorder" Property="Background" Value="{StaticResource color.icon.checkbox-radio.dis.bg}" />
  815. <Setter TargetName="radioButtonBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.dis.border}" />
  816. <Setter TargetName="optionMark" Property="Fill" Value="{StaticResource color.icon.checkbox-radio.dis.fill}" />
  817. </Trigger>
  818. <!--<Trigger Property="IsPressed" Value="true">
  819. <Setter Property="Background" TargetName="radioButtonBorder" Value="{StaticResource RadioButton.Pressed.Background2}" />
  820. <Setter Property="BorderBrush" TargetName="radioButtonBorder" Value="{StaticResource RadioButton.Pressed.Border}" />
  821. <Setter Property="Fill" TargetName="optionMark" Value="{StaticResource RadioButton.Pressed.Glyph2}" />
  822. </Trigger>-->
  823. <Trigger Property="IsChecked" Value="true">
  824. <Setter TargetName="optionMark" Property="Opacity" Value="1" />
  825. <Setter TargetName="radioButtonBorder" Property="BorderBrush" Value="{StaticResource color.icon.checkbox-radio.hov.border}" />
  826. </Trigger>
  827. <Trigger Property="IsChecked" Value="{x:Null}">
  828. <Setter TargetName="optionMark" Property="Opacity" Value="0.56" />
  829. </Trigger>
  830. </ControlTemplate.Triggers>
  831. </ControlTemplate>
  832. </Setter.Value>
  833. </Setter>
  834. </Style>
  835. </ResourceDictionary>
  836. </Application.Resources>
  837. </prism:PrismApplication>