-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgramSettings.cs
More file actions
34 lines (27 loc) · 1.35 KB
/
ProgramSettings.cs
File metadata and controls
34 lines (27 loc) · 1.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
// Copyright (c) 2012-2026 The Hello World Writer (https://www.thehelloworldwriter.com).
// Licensed under the MIT License. See the LICENSE file in the project root for more information.
namespace GridlyDots;
using GridlyDots.Reuse;
/// <summary>The program settings class.</summary>
public class ProgramSettings
{
/// <summary>
/// Creates a new <see cref="JsonSettingsFile{T}"/> for program settings.
/// </summary>
/// <returns>A new settings file instance configured with portable and AppData paths.</returns>
public static JsonSettingsFile<ProgramSettings> CreateSettingsFile()
{
return new JsonSettingsFile<ProgramSettings>(
Path.ChangeExtension(Path.GetFileName(Application.ExecutablePath), "json"),
Path.GetDirectoryName(Application.ExecutablePath)!,
Path.Combine(Application.CompanyName!, Application.ProductName!));
}
/// <summary>Gets or sets the dot size setting value.</summary>
public int DotSize { get; set; } = 2;
/// <summary>Gets or sets the dot spacing setting value.</summary>
public int DotSpacing { get; set; } = 24;
/// <summary>Gets or sets the dot color code setting value.</summary>
public string? DotColorCode { get; set; } = "#038681";
/// <summary>Gets or sets the opacity setting value.</summary>
public double Opacity { get; set; } = 0.30;
}