├── .gitignore
├── LICENSE
├── README.md
├── screen.png
└── src
├── Styles.sln
└── Styles
├── App.config
├── App.xaml
├── App.xaml.cs
├── Controls
├── BaseUserControl.cs
├── Buttons.xaml
├── Buttons.xaml.cs
├── Check.xaml
├── Check.xaml.cs
├── Combobox.xaml
├── Combobox.xaml.cs
├── DataGrid.xaml
├── DataGrid.xaml.cs
├── Expander.xaml
├── Expander.xaml.cs
├── Group.xaml
├── Group.xaml.cs
├── ListBox.xaml
├── ListBox.xaml.cs
├── ListView.xaml
├── ListView.xaml.cs
├── Menu.xaml
├── Menu.xaml.cs
├── ProgressBar.xaml
├── ProgressBar.xaml.cs
├── RadioButtons.xaml
├── RadioButtons.xaml.cs
├── Scroll.xaml
├── Scroll.xaml.cs
├── Sprocket.cs
├── TabControls.xaml
├── TabControls.xaml.cs
├── TextBox.xaml
├── TextBox.xaml.cs
├── Toggles.xaml
├── Toggles.xaml.cs
├── TreeView.xaml
├── TreeView.xaml.cs
├── labels.xaml
└── labels.xaml.cs
├── MainWindow.xaml
├── MainWindow.xaml.cs
├── Properties
├── AssemblyInfo.cs
├── Resources.Designer.cs
├── Resources.resx
├── Settings.Designer.cs
└── Settings.settings
├── Styles.csproj
└── Themes
├── Converters
└── LeftMarginMultiplierConverter.cs
├── Extensions
├── ColorExtension.cs
└── TreeViewItemExtension.cs
└── Styles
├── Button.xaml
├── CheckBox.xaml
├── Colors.xaml
├── ComboBox.xaml
├── CommonControls.xaml
├── DataGrid.xaml
├── Expander.xaml
├── Generic.xaml
├── GroupBox.xaml
├── Label.xaml
├── ListBox.xaml
├── ListView.xaml
├── Menu.xaml
├── RadioButton.xaml
├── ScrollViewer.xaml
├── Separator.xaml
├── TabControl.xaml
├── TextBlock.xaml
├── TextBox.xaml
├── ToggleButton.xaml
└── TreeView.xaml
/.gitignore:
--------------------------------------------------------------------------------
1 | ## Ignore Visual Studio temporary files, build results, and
2 | ## files generated by popular Visual Studio add-ons.
3 | ##
4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
5 |
6 | # User-specific files
7 | *.suo
8 | *.user
9 | *.userosscache
10 | *.sln.docstates
11 |
12 | # User-specific files (MonoDevelop/Xamarin Studio)
13 | *.userprefs
14 |
15 | # Build results
16 | [Dd]ebug/
17 | [Dd]ebugPublic/
18 | [Rr]elease/
19 | [Rr]eleases/
20 | x64/
21 | x86/
22 | bld/
23 | [Bb]in/
24 | [Oo]bj/
25 | [Ll]og/
26 |
27 | # Visual Studio 2015/2017 cache/options directory
28 | .vs/
29 | # Uncomment if you have tasks that create the project's static files in wwwroot
30 | #wwwroot/
31 |
32 | # Visual Studio 2017 auto generated files
33 | Generated\ Files/
34 |
35 | # MSTest test Results
36 | [Tt]est[Rr]esult*/
37 | [Bb]uild[Ll]og.*
38 |
39 | # NUNIT
40 | *.VisualState.xml
41 | TestResult.xml
42 |
43 | # Build Results of an ATL Project
44 | [Dd]ebugPS/
45 | [Rr]eleasePS/
46 | dlldata.c
47 |
48 | # Benchmark Results
49 | BenchmarkDotNet.Artifacts/
50 |
51 | # .NET Core
52 | project.lock.json
53 | project.fragment.lock.json
54 | artifacts/
55 | **/Properties/launchSettings.json
56 |
57 | # StyleCop
58 | StyleCopReport.xml
59 |
60 | # Files built by Visual Studio
61 | *_i.c
62 | *_p.c
63 | *_i.h
64 | *.ilk
65 | *.meta
66 | *.obj
67 | *.iobj
68 | *.pch
69 | *.pdb
70 | *.ipdb
71 | *.pgc
72 | *.pgd
73 | *.rsp
74 | *.sbr
75 | *.tlb
76 | *.tli
77 | *.tlh
78 | *.tmp
79 | *.tmp_proj
80 | *.log
81 | *.vspscc
82 | *.vssscc
83 | .builds
84 | *.pidb
85 | *.svclog
86 | *.scc
87 |
88 | # Chutzpah Test files
89 | _Chutzpah*
90 |
91 | # Visual C++ cache files
92 | ipch/
93 | *.aps
94 | *.ncb
95 | *.opendb
96 | *.opensdf
97 | *.sdf
98 | *.cachefile
99 | *.VC.db
100 | *.VC.VC.opendb
101 |
102 | # Visual Studio profiler
103 | *.psess
104 | *.vsp
105 | *.vspx
106 | *.sap
107 |
108 | # Visual Studio Trace Files
109 | *.e2e
110 |
111 | # TFS 2012 Local Workspace
112 | $tf/
113 |
114 | # Guidance Automation Toolkit
115 | *.gpState
116 |
117 | # ReSharper is a .NET coding add-in
118 | _ReSharper*/
119 | *.[Rr]e[Ss]harper
120 | *.DotSettings.user
121 |
122 | # JustCode is a .NET coding add-in
123 | .JustCode
124 |
125 | # TeamCity is a build add-in
126 | _TeamCity*
127 |
128 | # DotCover is a Code Coverage Tool
129 | *.dotCover
130 |
131 | # AxoCover is a Code Coverage Tool
132 | .axoCover/*
133 | !.axoCover/settings.json
134 |
135 | # Visual Studio code coverage results
136 | *.coverage
137 | *.coveragexml
138 |
139 | # NCrunch
140 | _NCrunch_*
141 | .*crunch*.local.xml
142 | nCrunchTemp_*
143 |
144 | # MightyMoose
145 | *.mm.*
146 | AutoTest.Net/
147 |
148 | # Web workbench (sass)
149 | .sass-cache/
150 |
151 | # Installshield output folder
152 | [Ee]xpress/
153 |
154 | # DocProject is a documentation generator add-in
155 | DocProject/buildhelp/
156 | DocProject/Help/*.HxT
157 | DocProject/Help/*.HxC
158 | DocProject/Help/*.hhc
159 | DocProject/Help/*.hhk
160 | DocProject/Help/*.hhp
161 | DocProject/Help/Html2
162 | DocProject/Help/html
163 |
164 | # Click-Once directory
165 | publish/
166 |
167 | # Publish Web Output
168 | *.[Pp]ublish.xml
169 | *.azurePubxml
170 | # Note: Comment the next line if you want to checkin your web deploy settings,
171 | # but database connection strings (with potential passwords) will be unencrypted
172 | *.pubxml
173 | *.publishproj
174 |
175 | # Microsoft Azure Web App publish settings. Comment the next line if you want to
176 | # checkin your Azure Web App publish settings, but sensitive information contained
177 | # in these scripts will be unencrypted
178 | PublishScripts/
179 |
180 | # NuGet Packages
181 | *.nupkg
182 | # The packages folder can be ignored because of Package Restore
183 | **/[Pp]ackages/*
184 | # except build/, which is used as an MSBuild target.
185 | !**/[Pp]ackages/build/
186 | # Uncomment if necessary however generally it will be regenerated when needed
187 | #!**/[Pp]ackages/repositories.config
188 | # NuGet v3's project.json files produces more ignorable files
189 | *.nuget.props
190 | *.nuget.targets
191 |
192 | # Microsoft Azure Build Output
193 | csx/
194 | *.build.csdef
195 |
196 | # Microsoft Azure Emulator
197 | ecf/
198 | rcf/
199 |
200 | # Windows Store app package directories and files
201 | AppPackages/
202 | BundleArtifacts/
203 | Package.StoreAssociation.xml
204 | _pkginfo.txt
205 | *.appx
206 |
207 | # Visual Studio cache files
208 | # files ending in .cache can be ignored
209 | *.[Cc]ache
210 | # but keep track of directories ending in .cache
211 | !*.[Cc]ache/
212 |
213 | # Others
214 | ClientBin/
215 | ~$*
216 | *~
217 | *.dbmdl
218 | *.dbproj.schemaview
219 | *.jfm
220 | *.pfx
221 | *.publishsettings
222 | orleans.codegen.cs
223 |
224 | # Including strong name files can present a security risk
225 | # (https://github.com/github/gitignore/pull/2483#issue-259490424)
226 | #*.snk
227 |
228 | # Since there are multiple workflows, uncomment next line to ignore bower_components
229 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
230 | #bower_components/
231 |
232 | # RIA/Silverlight projects
233 | Generated_Code/
234 |
235 | # Backup & report files from converting an old project file
236 | # to a newer Visual Studio version. Backup files are not needed,
237 | # because we have git ;-)
238 | _UpgradeReport_Files/
239 | Backup*/
240 | UpgradeLog*.XML
241 | UpgradeLog*.htm
242 | ServiceFabricBackup/
243 | *.rptproj.bak
244 |
245 | # SQL Server files
246 | *.mdf
247 | *.ldf
248 | *.ndf
249 |
250 | # Business Intelligence projects
251 | *.rdl.data
252 | *.bim.layout
253 | *.bim_*.settings
254 | *.rptproj.rsuser
255 |
256 | # Microsoft Fakes
257 | FakesAssemblies/
258 |
259 | # GhostDoc plugin setting file
260 | *.GhostDoc.xml
261 |
262 | # Node.js Tools for Visual Studio
263 | .ntvs_analysis.dat
264 | node_modules/
265 |
266 | # Visual Studio 6 build log
267 | *.plg
268 |
269 | # Visual Studio 6 workspace options file
270 | *.opt
271 |
272 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
273 | *.vbw
274 |
275 | # Visual Studio LightSwitch build output
276 | **/*.HTMLClient/GeneratedArtifacts
277 | **/*.DesktopClient/GeneratedArtifacts
278 | **/*.DesktopClient/ModelManifest.xml
279 | **/*.Server/GeneratedArtifacts
280 | **/*.Server/ModelManifest.xml
281 | _Pvt_Extensions
282 |
283 | # Paket dependency manager
284 | .paket/paket.exe
285 | paket-files/
286 |
287 | # FAKE - F# Make
288 | .fake/
289 |
290 | # JetBrains Rider
291 | .idea/
292 | *.sln.iml
293 |
294 | # CodeRush
295 | .cr/
296 |
297 | # Python Tools for Visual Studio (PTVS)
298 | __pycache__/
299 | *.pyc
300 |
301 | # Cake - Uncomment if you are using it
302 | # tools/**
303 | # !tools/packages.config
304 |
305 | # Tabs Studio
306 | *.tss
307 |
308 | # Telerik's JustMock configuration file
309 | *.jmconfig
310 |
311 | # BizTalk build output
312 | *.btp.cs
313 | *.btm.cs
314 | *.odx.cs
315 | *.xsd.cs
316 |
317 | # OpenCover UI analysis results
318 | OpenCover/
319 |
320 | # Azure Stream Analytics local run output
321 | ASALocalRun/
322 |
323 | # MSBuild Binary and Structured Log
324 | *.binlog
325 |
326 | # NVidia Nsight GPU debugger configuration file
327 | *.nvuser
328 |
329 | # MFractors (Xamarin productivity tool) working folder
330 | .mfractor/
331 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # WpfStyles
2 | Styles for wpf controls
3 | 
4 |
--------------------------------------------------------------------------------
/screen.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Sharkboy-j/WpfStyles/4878880d137cd9a6ba8e5711f6e9d5128493834b/screen.png
--------------------------------------------------------------------------------
/src/Styles.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 16.0.30128.36
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Styles", "Styles\Styles.csproj", "{BCEC224F-5D5A-483D-B77C-CD91BD2381C5}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {BCEC224F-5D5A-483D-B77C-CD91BD2381C5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {BCEC224F-5D5A-483D-B77C-CD91BD2381C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {BCEC224F-5D5A-483D-B77C-CD91BD2381C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
17 | {BCEC224F-5D5A-483D-B77C-CD91BD2381C5}.Release|Any CPU.Build.0 = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(SolutionProperties) = preSolution
20 | HideSolutionNode = FALSE
21 | EndGlobalSection
22 | GlobalSection(ExtensibilityGlobals) = postSolution
23 | SolutionGuid = {6074937C-54DC-43D8-984A-1461FF773F05}
24 | EndGlobalSection
25 | EndGlobal
26 |
--------------------------------------------------------------------------------
/src/Styles/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/src/Styles/App.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/src/Styles/App.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Windows;
2 |
3 | namespace Styles
4 | {
5 | ///
6 | /// Interaction logic for App.xaml
7 | ///
8 | public partial class App : Application
9 | {
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/src/Styles/Controls/BaseUserControl.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Windows.Controls;
3 | using System.Windows.Media;
4 | using Styles.Themes.Extensions;
5 |
6 | namespace Styles.Controls
7 | {
8 | public partial class BaseUserControl :UserControl
9 | {
10 | public BaseUserControl()
11 | {
12 | DataContext = this;
13 | }
14 | public class User
15 | {
16 | public int Id { get; set; }
17 | public string Name { get; set; }
18 | public int PhoneNumber { get; set; }
19 | }
20 | public List Users { get; set; } = new List
21 | {
22 | new User {Id = 1, Name = "John", PhoneNumber = 777666880},
23 | new User {Id = 2, Name = "Jane", PhoneNumber = 777666881},
24 | new User {Id = 3, Name = "Jimmy", PhoneNumber = 777666882},
25 | new User {Id = 4, Name = "Mary", PhoneNumber = 777666883},
26 | new User {Id = 5, Name = "Simon", PhoneNumber = 777666884},
27 | new User {Id = 6, Name = "Ann", PhoneNumber = 777666885},
28 | new User {Id = 1, Name = "John", PhoneNumber = 777666880},
29 | new User {Id = 2, Name = "Jane", PhoneNumber = 777666881},
30 | new User {Id = 3, Name = "Jimmy", PhoneNumber = 777666882},
31 | new User {Id = 4, Name = "Mary", PhoneNumber = 777666883},
32 | new User {Id = 5, Name = "Simon", PhoneNumber = 777666884},
33 | new User {Id = 6, Name = "Ann", PhoneNumber = 777666885}
34 | };
35 |
36 |
37 | public override void OnApplyTemplate()
38 | {
39 | base.OnApplyTemplate();
40 | var accentBrush = TryFindResource("AccentColorBrush") as SolidColorBrush;
41 | accentBrush?.Color.CreateAccentColors();
42 | }
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Buttons.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
19 |
24 |
25 |
26 |
30 |
35 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Buttons.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Buttons.xaml
5 | ///
6 | public partial class Buttons
7 | {
8 | public Buttons()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Check.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
16 |
17 |
18 |
19 |
20 |
24 |
25 |
29 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Check.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Check.xaml
5 | ///
6 | public partial class Check
7 | {
8 | public Check()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Combobox.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
16 |
20 |
21 |
22 |
23 |
27 |
28 |
32 |
33 |
34 |
38 |
42 |
43 |
48 |
52 |
53 |
54 |
55 |
59 |
63 |
67 |
68 |
69 |
70 |
75 |
76 |
80 |
81 |
82 |
87 |
91 |
92 |
98 |
102 |
103 |
104 |
105 |
106 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Combobox.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Combobox.xaml
5 | ///
6 | public partial class Combobox
7 | {
8 | public Combobox()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/DataGrid.xaml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
13 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/src/Styles/Controls/DataGrid.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for DataGrid.xaml
5 | ///
6 | public partial class DataGrid
7 | {
8 | public DataGrid()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Expander.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
20 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Expander.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Expander.xaml
5 | ///
6 | public partial class Expander
7 | {
8 | public Expander()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Group.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
22 |
23 |
24 |
28 |
35 |
36 |
37 |
41 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Group.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Group.xaml
5 | ///
6 | public partial class Group
7 | {
8 | public Group()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ListBox.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
14 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ListBox.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for ListBox.xaml
5 | ///
6 | public partial class ListBox
7 | {
8 | public ListBox()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ListView.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
14 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ListView.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for ListView.xaml
5 | ///
6 | public partial class ListView
7 | {
8 |
9 | public ListView()
10 | {
11 | InitializeComponent();
12 | }
13 |
14 |
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Menu.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
14 |
61 |
62 |
63 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Menu.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Menu.xaml
5 | ///
6 | public partial class Menu
7 | {
8 | public Menu()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ProgressBar.xaml:
--------------------------------------------------------------------------------
1 |
11 |
12 |
16 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/src/Styles/Controls/ProgressBar.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows;
7 | using System.Windows.Controls;
8 | using System.Windows.Data;
9 | using System.Windows.Documents;
10 | using System.Windows.Input;
11 | using System.Windows.Media;
12 | using System.Windows.Media.Imaging;
13 | using System.Windows.Navigation;
14 | using System.Windows.Shapes;
15 |
16 | namespace Styles.Controls
17 | {
18 | ///
19 | /// Interaction logic for ProgressBar.xaml
20 | ///
21 | public partial class ProgressBar : UserControl
22 | {
23 | public ProgressBar()
24 | {
25 | InitializeComponent();
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/src/Styles/Controls/RadioButtons.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
12 |
16 |
17 |
21 |
22 |
23 |
24 |
29 |
33 |
34 |
35 |
36 |
40 |
41 |
46 |
50 |
51 |
52 |
57 |
61 |
62 |
63 |
64 |
65 |
66 |
70 |
71 |
76 |
80 |
81 |
82 |
88 |
93 |
94 |
95 |
96 |
97 |
98 |
--------------------------------------------------------------------------------
/src/Styles/Controls/RadioButtons.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for RadioButtons.xaml
5 | ///
6 | public partial class RadioButtons
7 | {
8 | public RadioButtons()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Scroll.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
14 |
20 |
24 | Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
25 | Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.
26 | Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim.
27 | Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
28 | Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.
29 | Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim.
30 | Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Scroll.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Scroll.xaml
5 | ///
6 | public partial class Scroll
7 | {
8 | public Scroll()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TabControls.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
44 |
45 |
50 |
51 |
52 |
53 |
54 |
59 |
60 |
61 |
66 |
67 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
94 |
99 |
100 |
101 |
102 |
103 |
104 |
108 |
109 |
110 |
111 |
112 |
113 |
119 |
124 |
125 |
126 |
127 |
128 |
132 |
133 |
134 |
135 |
136 |
137 |
143 |
148 |
149 |
150 |
151 |
152 |
153 |
157 |
158 |
159 |
160 |
161 |
162 |
168 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
184 |
185 |
190 |
191 |
192 |
193 |
194 |
195 |
196 |
197 |
198 |
199 |
200 |
201 |
202 |
209 |
217 |
218 |
224 |
230 |
235 |
236 |
237 |
238 |
239 |
240 |
241 |
242 |
243 |
244 |
248 |
252 |
253 |
254 |
255 |
260 |
261 |
262 |
266 |
270 |
275 |
276 |
277 |
281 |
282 |
283 |
284 |
285 |
286 |
287 |
288 |
289 |
290 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TabControls.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for TabControls.xaml
5 | ///
6 | public partial class TabControls
7 | {
8 | public TabControls()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TextBox.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
20 |
26 |
27 |
28 |
32 |
37 |
43 |
44 |
45 |
46 |
47 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TextBox.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for TextBox.xaml
5 | ///
6 | public partial class TextBox
7 | {
8 | public TextBox()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Toggles.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
19 |
24 |
29 |
30 |
31 |
35 |
40 |
46 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/src/Styles/Controls/Toggles.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for Toggles.xaml
5 | ///
6 | public partial class Toggles
7 | {
8 | public Toggles()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TreeView.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
14 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/src/Styles/Controls/TreeView.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for TreeView.xaml
5 | ///
6 | public partial class TreeView
7 | {
8 | public TreeView()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/Controls/labels.xaml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
15 |
16 |
17 |
18 |
19 |
23 |
24 |
25 |
26 |
30 |
31 |
32 |
36 |
37 |
38 |
39 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/src/Styles/Controls/labels.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace Styles.Controls
2 | {
3 | ///
4 | /// Interaction logic for labels.xaml
5 | ///
6 | public partial class labels
7 | {
8 | public labels()
9 | {
10 | InitializeComponent();
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Styles/MainWindow.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Windows;
2 |
3 | namespace Styles
4 | {
5 | ///
6 | /// Interaction logic for MainWindow.xaml
7 | ///
8 | public partial class MainWindow : Window
9 | {
10 | public MainWindow()
11 | {
12 | InitializeComponent();
13 |
14 | }
15 | }
16 |
17 |
18 | }
--------------------------------------------------------------------------------
/src/Styles/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 | using System.Windows;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Styles")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("")]
12 | [assembly: AssemblyProduct("Styles")]
13 | [assembly: AssemblyCopyright("Copyright © 2016")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | //In order to begin building localizable applications, set
23 | //CultureYouAreCodingWith in your .csproj file
24 | //inside a . For example, if you are using US english
25 | //in your source files, set the to en-US. Then uncomment
26 | //the NeutralResourceLanguage attribute below. Update the "en-US" in
27 | //the line below to match the UICulture setting in the project file.
28 |
29 | //[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
30 |
31 |
32 | [assembly: ThemeInfo(
33 | ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
34 | //(used if a resource is not found in the page,
35 | // or application resource dictionaries)
36 | ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
37 | //(used if a resource is not found in the page,
38 | // app, or any theme specific resource dictionaries)
39 | )]
40 |
41 |
42 | // Version information for an assembly consists of the following four values:
43 | //
44 | // Major Version
45 | // Minor Version
46 | // Build Number
47 | // Revision
48 | //
49 | // You can specify all the values or you can default the Build and Revision Numbers
50 | // by using the '*' as shown below:
51 | // [assembly: AssemblyVersion("1.0.*")]
52 | [assembly: AssemblyVersion("1.0.0.0")]
53 | [assembly: AssemblyFileVersion("1.0.0.0")]
54 |
--------------------------------------------------------------------------------
/src/Styles/Properties/Resources.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace Styles.Properties {
12 | using System;
13 |
14 |
15 | ///
16 | /// A strongly-typed resource class, for looking up localized strings, etc.
17 | ///
18 | // This class was auto-generated by the StronglyTypedResourceBuilder
19 | // class via a tool like ResGen or Visual Studio.
20 | // To add or remove a member, edit your .ResX file then rerun ResGen
21 | // with the /str option, or rebuild your VS project.
22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "16.0.0.0")]
23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
25 | internal class Resources {
26 |
27 | private static global::System.Resources.ResourceManager resourceMan;
28 |
29 | private static global::System.Globalization.CultureInfo resourceCulture;
30 |
31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
32 | internal Resources() {
33 | }
34 |
35 | ///
36 | /// Returns the cached ResourceManager instance used by this class.
37 | ///
38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
39 | internal static global::System.Resources.ResourceManager ResourceManager {
40 | get {
41 | if (object.ReferenceEquals(resourceMan, null)) {
42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Styles.Properties.Resources", typeof(Resources).Assembly);
43 | resourceMan = temp;
44 | }
45 | return resourceMan;
46 | }
47 | }
48 |
49 | ///
50 | /// Overrides the current thread's CurrentUICulture property for all
51 | /// resource lookups using this strongly typed resource class.
52 | ///
53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
54 | internal static global::System.Globalization.CultureInfo Culture {
55 | get {
56 | return resourceCulture;
57 | }
58 | set {
59 | resourceCulture = value;
60 | }
61 | }
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/src/Styles/Properties/Resources.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 | text/microsoft-resx
107 |
108 |
109 | 2.0
110 |
111 |
112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
113 |
114 |
115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
--------------------------------------------------------------------------------
/src/Styles/Properties/Settings.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace Styles.Properties {
12 |
13 |
14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.6.0.0")]
16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
17 |
18 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
19 |
20 | public static Settings Default {
21 | get {
22 | return defaultInstance;
23 | }
24 | }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/src/Styles/Properties/Settings.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/src/Styles/Styles.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Debug
6 | AnyCPU
7 | {BCEC224F-5D5A-483D-B77C-CD91BD2381C5}
8 | WinExe
9 | Properties
10 | Styles
11 | Styles
12 | v4.5
13 | 512
14 | {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
15 | 4
16 |
17 |
18 | AnyCPU
19 | true
20 | full
21 | false
22 | bin\Debug\
23 | DEBUG;TRACE
24 | prompt
25 | 4
26 |
27 |
28 | AnyCPU
29 | pdbonly
30 | true
31 | bin\Release\
32 | TRACE
33 | prompt
34 | 4
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 | 4.0
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 | MSBuild:Compile
55 | Designer
56 |
57 |
58 |
59 | Buttons.xaml
60 |
61 |
62 | Check.xaml
63 |
64 |
65 | Combobox.xaml
66 |
67 |
68 | DataGrid.xaml
69 |
70 |
71 | Expander.xaml
72 |
73 |
74 | Group.xaml
75 |
76 |
77 | labels.xaml
78 |
79 |
80 | ListBox.xaml
81 |
82 |
83 | ListView.xaml
84 |
85 |
86 | Menu.xaml
87 |
88 |
89 | ProgressBar.xaml
90 |
91 |
92 | RadioButtons.xaml
93 |
94 |
95 | Scroll.xaml
96 |
97 |
98 |
99 | TabControls.xaml
100 |
101 |
102 | TextBox.xaml
103 |
104 |
105 | Toggles.xaml
106 |
107 |
108 | TreeView.xaml
109 |
110 |
111 |
112 |
113 |
114 | Designer
115 | MSBuild:Compile
116 |
117 |
118 | Designer
119 | MSBuild:Compile
120 |
121 |
122 | Designer
123 | MSBuild:Compile
124 |
125 |
126 | Designer
127 | MSBuild:Compile
128 |
129 |
130 | Designer
131 | MSBuild:Compile
132 |
133 |
134 | Designer
135 | MSBuild:Compile
136 |
137 |
138 | Designer
139 | MSBuild:Compile
140 |
141 |
142 | Designer
143 | MSBuild:Compile
144 |
145 |
146 | Designer
147 | MSBuild:Compile
148 |
149 |
150 | Designer
151 | MSBuild:Compile
152 |
153 |
154 | Designer
155 | MSBuild:Compile
156 |
157 |
158 | Designer
159 | MSBuild:Compile
160 |
161 |
162 | Designer
163 | MSBuild:Compile
164 |
165 |
166 | Designer
167 | MSBuild:Compile
168 |
169 |
170 | Designer
171 | MSBuild:Compile
172 |
173 |
174 | Designer
175 | MSBuild:Compile
176 |
177 |
178 | Designer
179 | MSBuild:Compile
180 |
181 |
182 | MSBuild:Compile
183 | Designer
184 |
185 |
186 | App.xaml
187 | Code
188 |
189 |
190 | MainWindow.xaml
191 | Code
192 |
193 |
194 | MSBuild:Compile
195 | Designer
196 |
197 |
198 | MSBuild:Compile
199 | Designer
200 |
201 |
202 | MSBuild:Compile
203 | Designer
204 |
205 |
206 | Designer
207 | MSBuild:Compile
208 |
209 |
210 | Designer
211 | MSBuild:Compile
212 |
213 |
214 | MSBuild:Compile
215 | Designer
216 |
217 |
218 | MSBuild:Compile
219 | Designer
220 |
221 |
222 | MSBuild:Compile
223 | Designer
224 |
225 |
226 | MSBuild:Compile
227 | Designer
228 |
229 |
230 | MSBuild:Compile
231 | Designer
232 |
233 |
234 | MSBuild:Compile
235 | Designer
236 |
237 |
238 | MSBuild:Compile
239 | Designer
240 |
241 |
242 | MSBuild:Compile
243 | Designer
244 |
245 |
246 | MSBuild:Compile
247 | Designer
248 |
249 |
250 | MSBuild:Compile
251 | Designer
252 |
253 |
254 | MSBuild:Compile
255 | Designer
256 |
257 |
258 | MSBuild:Compile
259 | Designer
260 |
261 |
262 | MSBuild:Compile
263 | Designer
264 |
265 |
266 | Designer
267 | MSBuild:Compile
268 |
269 |
270 | Designer
271 | MSBuild:Compile
272 |
273 |
274 | Designer
275 | MSBuild:Compile
276 |
277 |
278 |
279 |
280 | Code
281 |
282 |
283 | True
284 | True
285 | Resources.resx
286 |
287 |
288 | True
289 | Settings.settings
290 | True
291 |
292 |
293 | ResXFileCodeGenerator
294 | Resources.Designer.cs
295 |
296 |
297 | SettingsSingleFileGenerator
298 | Settings.Designer.cs
299 |
300 |
301 |
302 |
303 |
304 |
305 |
306 |
307 |
314 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Converters/LeftMarginMultiplierConverter.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Globalization;
3 | using System.Windows;
4 | using System.Windows.Controls;
5 | using System.Windows.Data;
6 |
7 | namespace Styles
8 | {
9 | public class LeftMarginMultiplierConverter: IValueConverter
10 | {
11 | public double Length { get; set; }
12 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
13 | {
14 | var item = value as TreeViewItem;
15 | if(item == null) return new Thickness(0);
16 | return new Thickness(Length * item.GetDepth(), 0, 0, 0);
17 | }
18 |
19 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
20 | {
21 | throw new NotImplementedException();
22 | }
23 | }
24 | }
--------------------------------------------------------------------------------
/src/Styles/Themes/Extensions/ColorExtension.cs:
--------------------------------------------------------------------------------
1 | using System.Windows;
2 | using System.Windows.Media;
3 |
4 | namespace Styles.Themes.Extensions
5 | {
6 | public static class ColorExtension
7 | {
8 | private const string AccentBrush = "AccentBrush";
9 | private const string AccentColor = "AccentColor";
10 |
11 | private const string AccentBrush1 = "AccentBrush1";
12 | private const string AccentColor1 = "AccentColor1";
13 |
14 | private const string MouseOverBorderBrush = "MouseOver.BorderBrush";
15 | private const string MouseOverBorderColor = "MouseOver.BorderColor";
16 | private const string MouseOverBackgroundBrush = "MouseOver.BackgroundBrush";
17 | private const string MouseOverBackgroundColor = "MouseOver.BackgroundColor";
18 |
19 | private const string PressedBackgroundBrush = "Pressed.BackgroundBrush";
20 | private const string PressedBackgroundColor = "Pressed.BackgroundColor";
21 | private const string PressedBorderBrush = "Pressed.BorderBrush";
22 | private const string PressedBorderColor = "Pressed.BorderColor";
23 |
24 | private const string PressedBackgroundBrushDark = "Pressed.BackgroundBrushDark";
25 | private const string PressedBackgroundColorDark = "Pressed.BackgroundColorDark";
26 | private const string PressedBorderBrushDark = "Pressed.BorderBrushDark";
27 | private const string PressedBorderColorDark = "Pressed.BorderColorDark";
28 |
29 | private static ResourceDictionary _accentResources;
30 |
31 | public static void CreateAccentColors(this Color color)
32 | {
33 | var accentColor = Application.Current.TryFindResource(AccentBrush) as SolidColorBrush;
34 |
35 | if (accentColor != null) return;
36 |
37 | if (_accentResources != null)
38 | {
39 | _accentResources.AddResources(color);
40 | }
41 |
42 | var resources = new ResourceDictionary();
43 | resources.AddResources(color);
44 | var application = Application.Current;
45 | var applicationResources = application.Resources;
46 | applicationResources.MergedDictionaries.Insert(0, resources);
47 | _accentResources = resources;
48 | }
49 |
50 | private static void AddResources(this ResourceDictionary resources, Color color)
51 | {
52 | resources.Add(AccentColor, color);
53 | resources.Add(AccentColor1, color.GetAccentColor1());
54 | resources.Add(MouseOverBorderColor, color.GetMouseOverBorderColor());
55 | resources.Add(MouseOverBackgroundColor, color.GetMouseOverBackgroundColor());
56 | resources.Add(PressedBorderColor, color.GetPressedBorderColor());
57 | resources.Add(PressedBackgroundColor, color.GetPressedBackgroundColor());
58 | resources.Add(PressedBorderColorDark, color.GetPressedBorderColorDark());
59 | resources.Add(PressedBackgroundColorDark, color.GetPressedBackgroundColorDark());
60 |
61 | resources.Add(AccentBrush, new SolidColorBrush((Color) resources[AccentColor]));
62 | resources.Add(AccentBrush1, new SolidColorBrush((Color)resources[AccentColor1]));
63 | resources.Add(MouseOverBorderBrush, new SolidColorBrush((Color) resources[MouseOverBorderColor]));
64 | resources.Add(MouseOverBackgroundBrush, new SolidColorBrush((Color) resources[MouseOverBackgroundColor]));
65 | resources.Add(PressedBorderBrush, new SolidColorBrush((Color)resources[PressedBorderColor]));
66 | resources.Add(PressedBackgroundBrush, new SolidColorBrush((Color)resources[PressedBackgroundColor]));
67 | resources.Add(PressedBorderBrushDark, new SolidColorBrush((Color)resources[PressedBorderColorDark]));
68 | resources.Add(PressedBackgroundBrushDark, new SolidColorBrush((Color)resources[PressedBackgroundColorDark]));
69 | }
70 |
71 | private static Color GetAccentColor1(this Color color)
72 | {
73 | var c = Color.FromArgb(180, color.R, color.G, color.B);
74 | return c.MakeOpaque();
75 | }
76 |
77 | private static Color GetMouseOverBackgroundColor(this Color color)
78 | {
79 | var c = Color.FromArgb(30, color.R, color.G, color.B);
80 | return c.MakeOpaque();
81 | }
82 |
83 | private static Color GetMouseOverBorderColor(this Color color)
84 | {
85 | var c = Color.FromArgb(70, color.R, color.G, color.B);
86 | return c.MakeOpaque();
87 | }
88 |
89 | private static Color GetPressedBackgroundColor(this Color color)
90 | {
91 | var c = Color.FromArgb(70, color.R, color.G, color.B);
92 | return c.MakeOpaque();
93 | }
94 |
95 | private static Color GetPressedBorderColor(this Color color)
96 | {
97 | var c = Color.FromArgb(110, color.R, color.G, color.B);
98 | return c.MakeOpaque();
99 | }
100 |
101 | private static Color GetPressedBackgroundColorDark(this Color color)
102 | {
103 | var c = Color.FromArgb(180, color.R, color.G, color.B);
104 | return MixColors(c, Colors.Black);
105 | }
106 |
107 | private static Color GetPressedBorderColorDark(this Color color)
108 | {
109 | var c = Color.FromArgb(200, color.R, color.G, color.B);
110 | return MixColors(c, Colors.Black);
111 | }
112 |
113 | private static Color MakeOpaque(this Color color)
114 | {
115 | return MixColors(color, Colors.White);
116 | }
117 |
118 | private static Color MixColors(Color color1, Color color2)
119 | {
120 | var r = (color1.R * color1.A / 255) + (color2.R * color2.A * (255 - color1.A) / (255 * 255));
121 | var g = (color1.G * color1.A / 255) + (color2.G * color2.A * (255 - color1.A) / (255 * 255));
122 | var b = (color1.B * color1.A / 255) + (color2.B * color2.A * (255 - color1.A) / (255 * 255));
123 |
124 | return Color.FromRgb((byte)r, (byte)g, (byte)b);
125 | }
126 | }
127 | }
--------------------------------------------------------------------------------
/src/Styles/Themes/Extensions/TreeViewItemExtension.cs:
--------------------------------------------------------------------------------
1 | using System.Windows.Controls;
2 | using System.Windows.Media;
3 |
4 | namespace Styles
5 | {
6 | public static class TreeViewItemExtension
7 | {
8 | public static int GetDepth(this TreeViewItem item)
9 | {
10 | var parent = GetParent(item);
11 | while ((GetParent(item)) != null)
12 | {
13 | return GetDepth(parent) + 1;
14 | }
15 | return 0;
16 | }
17 |
18 | public static TreeViewItem GetParent(this TreeViewItem item)
19 | {
20 | var parent = VisualTreeHelper.GetParent(item);
21 | while (!(parent is TreeViewItem || parent is TreeView))
22 | {
23 | if (parent == null) return null;
24 | parent = VisualTreeHelper.GetParent(parent);
25 | }
26 |
27 | return parent as TreeViewItem;
28 | }
29 | }
30 | }
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/Button.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
58 |
59 |
106 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/CheckBox.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | F1 M 9.97498,1.22334L 4.6983,9.09834L 4.52164,9.09834L 0,5.19331L 1.27664,3.52165L 4.255,6.08833L 8.33331,1.52588e-005L 9.97498,1.22334 Z
8 |
9 |
100 |
101 |
183 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/CommonControls.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
17 |
18 |
32 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/Expander.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
22 |
23 |
79 |
80 |
136 |
137 |
193 |
194 |
239 |
318 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/Generic.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/GroupBox.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
82 |
83 |
116 |
117 |
124 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/Label.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
36 |
37 |
45 |
46 |
54 |
55 |
63 |
64 |
71 |
72 |
79 |
80 |
87 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/ListBox.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
63 |
64 |
107 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/ListView.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
63 |
64 |
107 |
108 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/RadioButton.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
85 |
86 |
159 |
160 |
251 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/Separator.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
10 |
11 |
27 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/TextBlock.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
10 |
11 |
19 |
20 |
28 |
29 |
37 |
38 |
45 |
46 |
53 |
54 |
61 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/TextBox.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
60 |
61 |
105 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/ToggleButton.xaml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
70 |
71 |
130 |
--------------------------------------------------------------------------------
/src/Styles/Themes/Styles/TreeView.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
22 |
23 |
72 |
73 |
154 |
155 |
209 |
--------------------------------------------------------------------------------