Add project files.
This commit is contained in:
32
Display/Display.csproj
Normal file
32
Display/Display.csproj
Normal file
@@ -0,0 +1,32 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0-windows</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<RootNamespace>CMM.Display</RootNamespace>
|
||||
<Product>ControlMyMonitorManagement</Product>
|
||||
<UseWPF>true</UseWPF>
|
||||
<Company>Dang</Company>
|
||||
<Copyright>Copyright © DangWang $([System.DateTime]::Now.ToString(yyyy))</Copyright>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)'=='Release'">
|
||||
<Major>1</Major>
|
||||
<Minor>0</Minor>
|
||||
<ProjectStartedDate>$([System.DateTime]::op_Subtraction($([System.DateTime]::get_Now().get_Date()),$([System.DateTime]::new(2017,9,17))).get_TotalDays())</ProjectStartedDate>
|
||||
<DaysSinceProjectStarted>$([System.DateTime]::Now.ToString(Hmm))</DaysSinceProjectStarted>
|
||||
<DateTimeSuffix>$([System.DateTime]::Now.ToString(yyyyMMdd))</DateTimeSuffix>
|
||||
<VersionSuffix>$(Major).$(Minor).$(ProjectStartedDate).$(DaysSinceProjectStarted)</VersionSuffix>
|
||||
<AssemblyVersion Condition=" '$(DateTimeSuffix)' == '' ">0.0.0.1</AssemblyVersion>
|
||||
<AssemblyVersion Condition=" '$(DateTimeSuffix)' != '' ">$(VersionSuffix)</AssemblyVersion>
|
||||
<Version Condition=" '$(DateTimeSuffix)' == '' ">0.0.0.1</Version>
|
||||
<Version Condition=" '$(DateTimeSuffix)' != '' ">$(DateTimeSuffix)</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="Converter\" />
|
||||
<Folder Include="Form\" />
|
||||
<Folder Include="View\" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
71
Display/Images/icons.xaml
Normal file
71
Display/Images/icons.xaml
Normal file
@@ -0,0 +1,71 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
|
||||
|
||||
<Style x:Key="PathFill" TargetType="Path">
|
||||
<Setter Property="Stretch" Value="Uniform"/>
|
||||
<Setter Property="Fill" Value="{Binding RelativeSource={RelativeSource AncestorType=Button}, Path=Foreground}"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Frame-->
|
||||
<Style x:Key="PathFrame" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M94.22,0L417.79,0C441.21,0.19 464.38,9.46 481.47,25.48 500.23,42.75 511.5,67.76 512,93.26L512,420.97C510.85,442.12 502.78,462.87 488.82,478.86 471.32,499.41 444.76,511.82 417.76,512L94.27,512C73.21,511.75 52.27,504.36 35.88,491.09 14,473.85 0.5,446.62 0,418.76L0,93.25C0.49,68.71 10.9,44.57 28.49,27.46 45.77,10.27 69.85,0.21 94.22,0 M85.61,30.72C68.33,33.24 52.3,43.14 42.24,57.39 34.1,68.48 29.86,82.28 30,96 30,202.67 30,309.34 30,416.01 29.89,427.61 32.9,439.23 38.74,449.26 48.08,465.41 64.52,477.36 82.9,480.79 90.5,482.38 98.29,481.94 105.99,482 209.31,482 312.63,482 415.95,482 422.69,482.03 429.44,481.08 435.89,479.11 457.54,472.56 475.05,454 480.17,431.95 482.47,423.13 481.96,413.95 482,404.92 481.99,301.59 482.02,198.26 481.99,94.93 481.99,76.98 474.07,59.28 460.78,47.24 449.05,36.27 433.08,30.04 417.03,30.01 310.01,29.99 202.99,30.01 95.97,30 92.5,30 89.03,30.22 85.61,30.72z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Clear-->
|
||||
<Style x:Key="PathClear" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512.262,512.262z M0,0z M507.736,4.394C501.879,-1.464,492.381,-1.464,486.523,4.394L289.873,201.044C253.003,171.95,199.405,174.084,164.993,207.448L6.44799999999995,319.984C-1.14300000000005,325.372,-2.02300000000005,336.276,4.52399999999995,342.822L169.573,507.871C176.308,514.607,187.552,513.432,192.749,505.45L299.494,341.53C330.826,309.012,334.421,259.504,310.24,223.103L507.736,25.6070000000001C513.594,19.7490000000001,513.594,10.2520000000001,507.736,4.39400000000006z M231.09,210.647C281.881,210.647,313.086,266.533,286.424,309.767L196.958,220.301C207.115,214.011,218.844,210.647,231.09,210.647z M177.704,473.576L153.344,449.216 196.61,384.321C201.206,377.428 199.343,368.115 192.45,363.52 185.559,358.924 176.245,360.787 171.649,367.68L131.711,427.584 38.295,334.168 172.874,238.644 268.453,334.223z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Unlock-->
|
||||
<Style x:Key="PathUnlock" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M438.533,438.533z M0,0z M375.721,227.259C370.39,221.928,363.921,219.267,356.304,219.267L146.176,219.267 146.176,127.907C146.176,107.728 153.315,90.505 167.591,76.229 181.868,61.956 199.092,54.818 219.269,54.818 239.444,54.818 256.671,61.955 270.942,76.229 285.219,90.505 292.358,107.729 292.358,127.907 292.358,132.854 294.165,137.136 297.778,140.752 301.399,144.369 305.683,146.178 310.625,146.178L328.906,146.178C333.851,146.178 338.133,144.369 341.754,140.752 345.36,137.136 347.174,132.854 347.174,127.907 347.174,92.691 334.659,62.576 309.633,37.545 284.603,12.513 254.48,0 219.269,0 184.055,0 153.935,12.513 128.903,37.544 103.875,62.572 91.361,92.69 91.361,127.906L91.361,219.266 82.226,219.266C74.615,219.266 68.142,221.933 62.812,227.258 57.482,232.583 54.818,239.058 54.818,246.672L54.818,411.124C54.818,418.741 57.483,425.213 62.812,430.541 68.142,435.866 74.615,438.532 82.226,438.532L356.304,438.532C363.921,438.532 370.396,435.866 375.721,430.541 381.046,425.213 383.715,418.741 383.715,411.124L383.715,246.673C383.719,239.059,381.053,232.591,375.721,227.259z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Lock-->
|
||||
<Style x:Key="PathLock" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M384,512z M0,0z M174.95,0L209.07,0C224.28,2.59 239.57,5.85 253.68,12.31 300.63,34.12 336.58,80.78 340.89,132.98 340.88,138.35 341.93,143.64 342.03,149 341.97,184.67 342,220.33 342.01,256 349.9,256.34 358.3,254.71 365.7,258.28 374.66,262.65 381.66,271.03 384,280.78L384,487.24C381.12,499.22,371.21,509.14,359.22,512L24.76,512C12.78,509.12,2.87,499.21,0,487.22L0,280.76C2.35,271.02 9.34,262.65 18.3,258.28 25.7,254.71 34.09,256.34 41.99,256 41.99,220.33 42.03,184.67 41.97,149 42.07,143.64 43.12,138.35 43.11,132.97 47.42,80.78 83.37,34.12 130.32,12.31 144.43,5.85 159.73,2.59 174.95,0 M107.18,144.03C106.76,181.33 107.12,218.67 107.01,255.99 163.67,256.01 220.33,256 276.99,255.99 277.02,221.33 276.97,186.66 277.02,152 277.29,133.15 271.81,113.9 260.01,99 244.53,77.81 218.55,63.57 192,65.01 148.56,62.76 109.21,101.17 107.18,144.03z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Log-->
|
||||
<Style x:Key="PathLog1" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M551.13,551.13z M0,0z M275.531,172.228L275.481,292.721C275.481,297.296,277.297,301.669,280.527,304.898L366.725,391.079 391.079,366.725 309.926,285.589 309.976,172.228z"/>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="PathLog2" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M551.13,551.13z M0,0z M310.011,34.445C188.781,34.445,88.448,124.478,71.644,241.119L2.8421709430404E-14,241.119 86.114,327.233 172.228,241.119 106.448,241.119C122.925,143.53 207.803,68.891 310.011,68.891 423.977,68.891 516.685,161.598 516.685,275.565 516.685,389.532 423.978,482.239 310.011,482.239 245.947,482.239 186.542,453.243 147.033,402.684L119.887,423.876C165.971,482.844 235.266,516.684 310.011,516.684 442.966,516.684 551.13,408.503 551.13,275.565 551.13,142.627 442.966,34.4460000000001 310.011,34.4450000000001z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path General-->
|
||||
<Style x:Key="PathGeneral" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M452,36L60,36C26.916,36,0,62.916,0,96L0,336C0,369.084,26.916,396,60,396L236,396 236,436 132,436 132,476 380,476 380,436 276,436 276,396 452,396C485.084,396,512,369.084,512,336L512,96C512,62.916,485.084,36,452,36z M472,336C472,347.028,463.028,356,452,356L60,356C48.972,356,40,347.028,40,336L40,96C40,84.972,48.972,76,60,76L452,76C463.028,76,472,84.972,472,96L472,336z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Setting-->
|
||||
<Style x:Key="PathSetting" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Stretch" Value="UniformToFill"/>
|
||||
<Setter Property="Data" Value="F1 M24,24z M0,0z M22.683,9.394L20.803,9.155C20.648,8.678,20.457,8.218,20.234,7.781L21.395,6.286C21.865,5.681,21.81,4.827,21.273,4.307L19.698,2.732C19.173,2.19,18.319,2.136,17.713,2.605L16.22,3.766C15.783,3.543,15.323,3.352,14.845,3.197L14.606,1.32C14.516,0.566999999999999,13.877,-1.33226762955019E-15,13.12,-1.33226762955019E-15L10.88,-1.33226762955019E-15C10.123,-1.33226762955019E-15,9.48400000000001,0.566999999999999,9.394,1.317L9.155,3.197C8.677,3.352,8.217,3.542,7.78,3.766L6.286,2.605C5.682,2.136,4.828,2.19,4.307,2.727L2.732,4.301C2.19,4.827,2.135,5.681,2.605,6.287L3.766,7.781C3.542,8.218,3.352,8.678,3.197,9.155L1.32,9.394C0.567000000000003,9.484,3.10862446895044E-15,10.123,3.10862446895044E-15,10.88L3.10862446895044E-15,13.12C3.10862446895044E-15,13.877,0.567000000000003,14.516,1.317,14.606L3.197,14.845C3.352,15.322,3.543,15.782,3.766,16.219L2.605,17.714C2.135,18.319,2.19,19.173,2.727,19.693L4.302,21.268C4.828,21.809,5.681,21.863,6.287,21.394L7.781,20.233C8.218,20.457,8.678,20.648,9.155,20.802L9.394,22.678C9.484,23.433,10.123,24,10.88,24L13.12,24C13.877,24,14.516,23.433,14.606,22.683L14.845,20.803C15.322,20.648,15.782,20.457,16.219,20.234L17.714,21.395C18.319,21.865,19.173,21.81,19.693,21.273L21.268,19.698C21.81,19.172,21.865,18.319,21.395,17.713L20.234,16.219C20.458,15.782,20.649,15.322,20.803,14.845L22.679,14.606C23.432,14.516,23.999,13.877,23.999,13.12L23.999,10.88C24,10.123,23.433,9.484,22.683,9.394z M12,17C9.243,17 7,14.757 7,12 7,9.243 9.243,7 12,7 14.757,7 17,9.243 17,12 17,14.757 14.757,17 12,17z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Frame-->
|
||||
<Style x:Key="PathFrame" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M94.22,0L417.79,0C441.21,0.19 464.38,9.46 481.47,25.48 500.23,42.75 511.5,67.76 512,93.26L512,420.97C510.85,442.12 502.78,462.87 488.82,478.86 471.32,499.41 444.76,511.82 417.76,512L94.27,512C73.21,511.75 52.27,504.36 35.88,491.09 14,473.85 0.5,446.62 0,418.76L0,93.25C0.49,68.71 10.9,44.57 28.49,27.46 45.77,10.27 69.85,0.21 94.22,0 M85.61,30.72C68.33,33.24 52.3,43.14 42.24,57.39 34.1,68.48 29.86,82.28 30,96 30,202.67 30,309.34 30,416.01 29.89,427.61 32.9,439.23 38.74,449.26 48.08,465.41 64.52,477.36 82.9,480.79 90.5,482.38 98.29,481.94 105.99,482 209.31,482 312.63,482 415.95,482 422.69,482.03 429.44,481.08 435.89,479.11 457.54,472.56 475.05,454 480.17,431.95 482.47,423.13 481.96,413.95 482,404.92 481.99,301.59 482.02,198.26 481.99,94.93 481.99,76.98 474.07,59.28 460.78,47.24 449.05,36.27 433.08,30.04 417.03,30.01 310.01,29.99 202.99,30.01 95.97,30 92.5,30 89.03,30.22 85.61,30.72z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Cancel-->
|
||||
<Style x:Key="PathCancel" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M140.12,139.14C143.16,135.89 148.82,135.93 151.84,139.19 186.95,174.18 221.94,209.28 257.01,244.31 292.08,209.28 327.09,174.2 362.17,139.18 365.35,135.72 371.42,135.97 374.34,139.64 377.33,142.99 376.7,148.52 373.32,151.38 338.46,186.26 303.57,221.12 268.71,256 302.75,290.06 336.8,324.1 370.86,358.15 372.76,360.13 375.18,361.97 375.82,364.8 376.9,368.58 374.74,372.93 371.1,374.4 367.94,375.84 364.03,374.92 361.71,372.38 326.81,337.48 291.93,302.57 257.01,267.69 222.11,302.57 187.25,337.49 152.32,372.35 149.49,375.62 144.11,376.17 140.81,373.3 137.14,370.45 136.79,364.43 140.16,361.21 175.17,326.1 210.28,291.08 245.32,256 210.29,220.92 175.2,185.9 140.18,150.82 136.94,147.81 136.9,142.18 140.12,139.14z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Minimized-->
|
||||
<Style x:Key="PathMinimized" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M107.38,241.56C108.86,241.12 110.41,241.03 111.95,241 207.98,241 304.01,241 400.05,241 407.85,240.59 415.24,247.15 415.52,255.01 416.16,261.91 411.26,268.64 404.62,270.43 401.48,271.29 398.2,270.94 395,271.01 300.65,270.99 206.3,271.01 111.95,271 104.15,271.4 96.76,264.84 96.48,256.99 95.83,250.08 100.74,243.35 107.38,241.56z"/>
|
||||
</Style>
|
||||
|
||||
<!--Path Tick-->
|
||||
<Style x:Key="PathTick" TargetType="Path" BasedOn="{StaticResource PathFill}">
|
||||
<Setter Property="Data" Value="F1 M512,512z M0,0z M467.87,75.93C474.86,68.5 486.42,65.9 495.87,69.83 504.86,73.26 511.2,82.14 512,91.67L512,94.74C511.77,102.86 507.06,109.91 501.13,115.11 394.1,222.11 287.11,329.15 180.07,436.14 173.06,443.53 161.52,446.07 152.09,442.16 147.71,440.52 144.16,437.35 140.99,434.01 96.51,389.49 51.98,345.02 7.5,300.49 3.03,296.06 0.4,289.97 0,283.71L0,281.25C0.38,270.52 8.2,260.69 18.52,257.82 27.27,255.24 37.31,257.78 43.69,264.32 83.02,303.59 122.28,342.92 161.6,382.19 263.7,280.11 365.77,178.01 467.87,75.93z"/>
|
||||
</Style>
|
||||
|
||||
</ResourceDictionary>
|
||||
59
Display/Style/Btn.xaml
Normal file
59
Display/Style/Btn.xaml
Normal file
@@ -0,0 +1,59 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
<!--<Style x:Key="ImageButton" TargetType="{x:Type ButtonBase}" BasedOn="{x:Null}">
|
||||
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsEnabled" Value="false">
|
||||
<Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="True">
|
||||
<Setter Property="Cursor" Value="Hand" />
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>-->
|
||||
|
||||
<!--<Style x:Key="GeometryButton" TargetType="{x:Type ButtonBase}" BasedOn="{StaticResource ImageButton}">
|
||||
<Setter Property="Foreground" Value="White" />
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsMouseOver" Value="True">
|
||||
<Setter Property="Foreground" Value="{StaticResource H1}"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
||||
--><!--Btn Cancel--><!--
|
||||
<Style x:Key="CancelButton" TargetType="{x:Type ButtonBase}" BasedOn="{StaticResource GeometryButton}">
|
||||
<Setter Property="Margin" Value="3,0,0,0"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="Button">
|
||||
<Border>
|
||||
<Grid Background="{StaticResource AlphaBrush}">
|
||||
<Path Style="{StaticResource PathCancel}"/>
|
||||
<Path Style="{StaticResource PathFrame}"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
--><!--Btn Minimized--><!--
|
||||
<Style x:Key="MinimizedButton" TargetType="{x:Type ButtonBase}" BasedOn="{StaticResource GeometryButton}">
|
||||
<Setter Property="Margin" Value="3,0,0,0"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="Button">
|
||||
<Border>
|
||||
<Grid Background="{StaticResource AlphaBrush}">
|
||||
<Path Style="{StaticResource PathMinimized}"/>
|
||||
<Path Style="{StaticResource PathFrame}"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>-->
|
||||
|
||||
</ResourceDictionary>
|
||||
39
Display/Style/Color.xaml
Normal file
39
Display/Style/Color.xaml
Normal file
@@ -0,0 +1,39 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
<Color x:Key="H1Color">#C1272C</Color>
|
||||
<Color x:Key="H2Color">#66424242</Color>
|
||||
<Color x:Key="H3Color">#535353</Color>
|
||||
|
||||
<Color x:Key="F1Color">#232323</Color>
|
||||
<Color x:Key="F2Color">#8A3D40</Color>
|
||||
<Color x:Key="F3Color">#FFFFFF</Color>
|
||||
|
||||
<Color x:Key="DisableColor">#B2626262</Color>
|
||||
<Color x:Key="DisableH2Color">#CCADADAD</Color>
|
||||
|
||||
<Color x:Key="NormalGray">#FF686868</Color>
|
||||
|
||||
<SolidColorBrush x:Key="NormalForeground" Color="White" />
|
||||
<SolidColorBrush x:Key="Unexplainable" Color="{StaticResource F2Color}" />
|
||||
<SolidColorBrush x:Key="Unnecessary" Color="#a08b72" />
|
||||
<SolidColorBrush x:Key="Selected" Color="{StaticResource H2Color}" />
|
||||
|
||||
<SolidColorBrush x:Key="Title" Color="White" />
|
||||
|
||||
<SolidColorBrush x:Key="H1" Color="{StaticResource H1Color}" />
|
||||
<SolidColorBrush x:Key="H2" Color="{StaticResource H2Color}" />
|
||||
<SolidColorBrush x:Key="H3" Color="{StaticResource H3Color}" />
|
||||
|
||||
<SolidColorBrush x:Key="F1" Color="{StaticResource F1Color}" />
|
||||
<SolidColorBrush x:Key="F2" Color="{StaticResource F2Color}" />
|
||||
<SolidColorBrush x:Key="F3" Color="{StaticResource F3Color}" />
|
||||
|
||||
<SolidColorBrush x:Key="BlurBrush" Color="#CC6C6161" />
|
||||
<SolidColorBrush x:Key="AlphaBrush" Color="#00FFFFFF" />
|
||||
|
||||
<SolidColorBrush x:Key="NormalBrush" Color="{StaticResource NormalGray}" />
|
||||
|
||||
<SolidColorBrush x:Key="DisabledForegroundBrush" Color="{StaticResource DisableColor}" />
|
||||
|
||||
</ResourceDictionary>
|
||||
4
Display/Style/Main.xaml
Normal file
4
Display/Style/Main.xaml
Normal file
@@ -0,0 +1,4 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
</ResourceDictionary>
|
||||
278
Display/Style/Slider.xaml
Normal file
278
Display/Style/Slider.xaml
Normal file
@@ -0,0 +1,278 @@
|
||||
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
<!--<Style x:Key="SliderRepeatButton" TargetType="RepeatButton">
|
||||
<Setter Property="SnapsToDevicePixels" Value="true" />
|
||||
<Setter Property="OverridesDefaultStyle" Value="true" />
|
||||
<Setter Property="IsTabStop" Value="false" />
|
||||
<Setter Property="Focusable" Value="false" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="RepeatButton">
|
||||
<Border BorderThickness="1" BorderBrush="{x:Null}" Background="#CCB9B6B6" Height="4"/>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="SliderRepeatButton1" TargetType="RepeatButton">
|
||||
<Setter Property="SnapsToDevicePixels" Value="true" />
|
||||
<Setter Property="OverridesDefaultStyle" Value="true" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="RepeatButton">
|
||||
<Border SnapsToDevicePixels="True" BorderThickness="1" Height="4">
|
||||
<Border.Background>
|
||||
<LinearGradientBrush EndPoint="1,0" StartPoint="0,0">
|
||||
<GradientStop Color="{DynamicResource H2Color}"/>
|
||||
<GradientStop Color="{DynamicResource H3Color}" Offset="1"/>
|
||||
</LinearGradientBrush>
|
||||
</Border.Background>
|
||||
</Border>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="SliderThumb" TargetType="Thumb">
|
||||
<Setter Property="SnapsToDevicePixels" Value="true" />
|
||||
<Setter Property="OverridesDefaultStyle" Value="true" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="Thumb">
|
||||
<Ellipse Height="12" Width="12" Fill="#99FFFFFF"></Ellipse>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<ControlTemplate x:Key="Slider" TargetType="Slider">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto" MinHeight="{TemplateBinding MinHeight}"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Track Grid.Row="1" x:Name="PART_Track">
|
||||
<Track.DecreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource SliderRepeatButton1}" Command="Slider.DecreaseLarge" />
|
||||
</Track.DecreaseRepeatButton>
|
||||
<Track.Thumb>
|
||||
<Thumb Style="{StaticResource SliderThumb}"/>
|
||||
</Track.Thumb>
|
||||
<Track.IncreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource SliderRepeatButton}" Command="Slider.IncreaseLarge" />
|
||||
</Track.IncreaseRepeatButton>
|
||||
</Track>
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
|
||||
<Style x:Key="Horizontal_Slider" TargetType="Slider">
|
||||
<Setter Property="Focusable" Value="False"/>
|
||||
<Setter Property="SnapsToDevicePixels" Value="true"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Setter Property="HorizontalAlignment" Value="Left"/>
|
||||
<Setter Property="VerticalAlignment" Value="Center"/>
|
||||
<Setter Property="Width" Value="205"/>
|
||||
<Setter Property="Height" Value="21"/>
|
||||
<Setter Property="Foreground" Value="{x:Null}"/>
|
||||
<Setter Property="FontSize" Value="8"/>
|
||||
<Setter Property="Margin" Value="5,0,10,0"/>
|
||||
|
||||
<Style.Triggers>
|
||||
<Trigger Property="Orientation" Value="Horizontal">
|
||||
<Setter Property="MinHeight" Value="21"/>
|
||||
<Setter Property="MinWidth" Value="104"/>
|
||||
<Setter Property="Template" Value="{StaticResource Slider}"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
|
||||
</Style>
|
||||
|
||||
<LinearGradientBrush x:Key="ListBoxBackgroundBrush" StartPoint="0,0" EndPoint="1,0.001">
|
||||
<GradientBrush.GradientStops>
|
||||
<GradientStopCollection>
|
||||
<GradientStop Color="White" Offset="0.0"/>
|
||||
<GradientStop Color="White" Offset="0.6"/>
|
||||
<GradientStop Color="#DDDDDD" Offset="1.2"/>
|
||||
</GradientStopCollection>
|
||||
</GradientBrush.GradientStops>
|
||||
</LinearGradientBrush>
|
||||
|
||||
<LinearGradientBrush x:Key="StandardBrush" StartPoint="0,0" EndPoint="0,1">
|
||||
<GradientBrush.GradientStops>
|
||||
<GradientStopCollection>
|
||||
<GradientStop Color="#FFF" Offset="0.0"/>
|
||||
<GradientStop Color="#CCC" Offset="1.0"/>
|
||||
</GradientStopCollection>
|
||||
</GradientBrush.GradientStops>
|
||||
</LinearGradientBrush>
|
||||
|
||||
<LinearGradientBrush x:Key="PressedBrush" StartPoint="0,0" EndPoint="0,1">
|
||||
<GradientBrush.GradientStops>
|
||||
<GradientStopCollection>
|
||||
<GradientStop Color="#BBB" Offset="0.0"/>
|
||||
<GradientStop Color="#EEE" Offset="0.1"/>
|
||||
<GradientStop Color="#EEE" Offset="0.9"/>
|
||||
<GradientStop Color="#FFF" Offset="1.0"/>
|
||||
</GradientStopCollection>
|
||||
</GradientBrush.GradientStops>
|
||||
</LinearGradientBrush>
|
||||
|
||||
<Style x:Key="ScrollBarBackground" TargetType="{x:Type Border}">
|
||||
<Setter Property="Margin" Value="2"/>
|
||||
<Setter Property="CornerRadius" Value="6"/>
|
||||
<Setter Property="Background" Value="{DynamicResource H2}"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="IsEnabled" Value="False">
|
||||
<Setter Property="Background" Value="{x:Null}"/>
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="ScrollBarLineButton" TargetType="{x:Type RepeatButton}">
|
||||
--><!--上下按鈕 不顯示--><!--
|
||||
<Setter Property="Visibility" Value="Hidden"/>
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Setter Property="Focusable" Value="false"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
||||
<Border Name="Border" Margin="1" CornerRadius="2" Background="{DynamicResource H2}" BorderBrush="{DynamicResource H2}" BorderThickness="1">
|
||||
<Path HorizontalAlignment="Center" VerticalAlignment="Center" Fill="{DynamicResource H2}" Data="{Binding Path=Content, RelativeSource={RelativeSource TemplatedParent}}" />
|
||||
</Border>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsPressed" Value="true">
|
||||
<Setter TargetName="Border" Property="Background" Value="{StaticResource PressedBrush}" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsEnabled" Value="false">
|
||||
<Setter Property="Foreground" Value="{StaticResource DisabledForegroundBrush}"/>
|
||||
</Trigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="ScrollBarPageButton" TargetType="{x:Type RepeatButton}">
|
||||
<Setter Property="Visibility" Value="Visible"/>
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Setter Property="IsTabStop" Value="false"/>
|
||||
<Setter Property="Focusable" Value="false"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
||||
<Border Background="{x:Null}" Margin="1"/>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="ScrollBarThumb" TargetType="{x:Type Thumb}">
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Setter Property="IsTabStop" Value="false"/>
|
||||
<Setter Property="Focusable" Value="false"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type Thumb}">
|
||||
<Border CornerRadius="4" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="0" Width="7"/>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<ControlTemplate x:Key="VerticalScrollBar" TargetType="{x:Type ScrollBar}">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition MaxHeight="5"/>
|
||||
<RowDefinition Height="0.00001*"/>
|
||||
<RowDefinition MaxHeight="5"/>
|
||||
</Grid.RowDefinitions>
|
||||
--><!--直向拉竿背景--><!--
|
||||
<Border Grid.RowSpan="4" Style="{StaticResource ScrollBarBackground}"/>
|
||||
--><!--往上按鈕 ※隱藏--><!--
|
||||
<RepeatButton Grid.Row="0" Style="{StaticResource ScrollBarLineButton}" Height="18" Command="ScrollBar.LineUpCommand" Content="M 0 4 L 8 4 L 4 0 Z" />
|
||||
<Track Name="PART_Track" Grid.Row="1" IsDirectionReversed="true" IsEnabled="{TemplateBinding IsMouseOver}" >
|
||||
<Track.DecreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource ScrollBarPageButton}" Command="ScrollBar.PageUpCommand" />
|
||||
</Track.DecreaseRepeatButton>
|
||||
<Track.Thumb>
|
||||
<Thumb Style="{StaticResource ScrollBarThumb}" Margin="1,0,1,0" Background="{DynamicResource H3}" BorderBrush="{DynamicResource H3}" />
|
||||
</Track.Thumb>
|
||||
<Track.IncreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource ScrollBarPageButton}" Command="ScrollBar.PageDownCommand" />
|
||||
</Track.IncreaseRepeatButton>
|
||||
</Track>
|
||||
--><!--往下按鈕 ※隱藏--><!--
|
||||
<RepeatButton Grid.Row="3" Style="{StaticResource ScrollBarLineButton}" Height="18" Command="ScrollBar.LineDownCommand" Content="M 0 0 L 4 4 L 8 0 Z"/>
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
|
||||
<ControlTemplate x:Key="HorizontalScrollBar" TargetType="{x:Type ScrollBar}">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition MaxWidth="18"/>
|
||||
<ColumnDefinition Width="0.00001*"/>
|
||||
<ColumnDefinition MaxWidth="18"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
--><!--橫向拉竿背景--><!--
|
||||
<Border Grid.ColumnSpan="3" CornerRadius="2" Background="{x:Null}"/>
|
||||
<RepeatButton Grid.Column="0" Style="{StaticResource ScrollBarLineButton}" Width="18" Command="ScrollBar.LineLeftCommand" Content="M 4 0 L 4 8 L 0 4 Z" />
|
||||
<Track Name="PART_Track" Grid.Column="1" IsDirectionReversed="False">
|
||||
<Track.DecreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource ScrollBarPageButton}" Command="ScrollBar.PageLeftCommand" />
|
||||
</Track.DecreaseRepeatButton>
|
||||
<Track.Thumb>
|
||||
<Thumb Style="{StaticResource ScrollBarThumb}" Margin="0,1,0,1" Background="{DynamicResource H3}" BorderBrush="{DynamicResource H3}" />
|
||||
</Track.Thumb>
|
||||
<Track.IncreaseRepeatButton>
|
||||
<RepeatButton Style="{StaticResource ScrollBarPageButton}" Command="ScrollBar.PageRightCommand" />
|
||||
</Track.IncreaseRepeatButton>
|
||||
</Track>
|
||||
<RepeatButton Grid.Column="3" Style="{StaticResource ScrollBarLineButton}" Width="18" Command="ScrollBar.LineRightCommand" Content="M 0 0 L 4 4 L 0 8 Z"/>
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
|
||||
<Style x:Key="{x:Type ScrollBar}" TargetType="{x:Type ScrollBar}">
|
||||
<Setter Property="SnapsToDevicePixels" Value="True"/>
|
||||
<Setter Property="OverridesDefaultStyle" Value="true"/>
|
||||
<Style.Triggers>
|
||||
<Trigger Property="Orientation" Value="Horizontal">
|
||||
<Setter Property="Width" Value="Auto"/>
|
||||
<Setter Property="Height" Value="18" />
|
||||
<Setter Property="Template" Value="{StaticResource HorizontalScrollBar}" />
|
||||
</Trigger>
|
||||
<Trigger Property="Orientation" Value="Vertical">
|
||||
<Setter Property="Width" Value="18"/>
|
||||
<Setter Property="Height" Value="Auto" />
|
||||
<Setter Property="Template" Value="{StaticResource VerticalScrollBar}" />
|
||||
</Trigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="FavsScrollViewer" TargetType="{x:Type ScrollViewer}">
|
||||
<Setter Property="OverridesDefaultStyle" Value="True"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type ScrollViewer}">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<ScrollContentPresenter Grid.Column="1"/>
|
||||
<ScrollBar Name="PART_VerticalScrollBar" Value="{TemplateBinding VerticalOffset}" Maximum="{TemplateBinding ScrollableHeight}" ViewportSize="{TemplateBinding ViewportHeight}" Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}"/>
|
||||
<ScrollBar Name="PART_HorizontalScrollBar" Orientation="Horizontal" Grid.Row="1" Grid.Column="1" Value="{TemplateBinding HorizontalOffset}" Maximum="{TemplateBinding ScrollableWidth}" ViewportSize="{TemplateBinding ViewportWidth}" Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}"/>
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>-->
|
||||
</ResourceDictionary>
|
||||
Reference in New Issue
Block a user