GlazeWM is a tiling window manager for macOS and Windows inspired by i3wm.
feat(domain): create class for bar component configs; move out shared `BarConfig` properties to new class
Lars Bergerdae22c71980e
diff --git a/GlazeWM.Domain/UserConfigs/BarComponentConfig.cs b/GlazeWM.Domain/UserConfigs/BarComponentConfig.csnew file mode 100644index 00000000..a9e5224a--- /dev/null+++ b/GlazeWM.Domain/UserConfigs/BarComponentConfig.cs@@ -0,0 +1,7 @@+namespace GlazeWM.Domain.UserConfigs+{+ public class BarComponentConfig : CommonBarAttributes+ {+ public string Margin { get; set; } = "0 10 0 0";+ }+}diff --git a/GlazeWM.Domain/UserConfigs/BarConfig.cs b/GlazeWM.Domain/UserConfigs/BarConfig.csindex 3372e2df..9ae7c912 100644--- a/GlazeWM.Domain/UserConfigs/BarConfig.cs+++ b/GlazeWM.Domain/UserConfigs/BarConfig.cs@@ -1,24 +1,8 @@namespace GlazeWM.Domain.UserConfigs{- public class BarConfig+ public class BarConfig : CommonBarAttributes{public uint Height { get; set; } = 25;- public string Background { get; set; } = "#101010";- public string FontFamily { get; set; } = "Segoe UI";- public string FontSize { get; set; } = "12";- public string BorderColor { get; set; } = "#8192B3";-- /// <summary>- /// Width of the border in pixels. To set a different border width for each side, specify four- /// values (eg. "5 0 5 0"). The borders widths apply to the top, right, bottom, and left in that- /// order.- /// </summary>- public string BorderWidth { get; set; } = "0 0 0 0";-- /// <summary>- /// Padding in pixels.- /// </summary>- public string Padding { get; set; } = "1 6 1 6";- public double Opacity { get; set; } = 1;+ public double Opacity { get; set; } = 0.9;}}diff --git a/GlazeWM.Domain/UserConfigs/CommonBarAttributes.cs b/GlazeWM.Domain/UserConfigs/CommonBarAttributes.csnew file mode 100644index 00000000..faf23923--- /dev/null+++ b/GlazeWM.Domain/UserConfigs/CommonBarAttributes.cs@@ -0,0 +1,23 @@+namespace GlazeWM.Domain.UserConfigs+{+ // TODO: Consider renaming to `SharedBarStyles`/`BarComponentConfig`.+ public class CommonBarAttributes+ {+ public string Background { get; set; } = "#101010";+ public string FontFamily { get; set; } = "Segoe UI";+ public string FontSize { get; set; } = "12";+ public string BorderColor { get; set; } = "#8192B3";++ /// <summary>+ /// Width of the border in pixels. To set a different border width for each side, specify four+ /// values (eg. "5 0 5 0"). The borders widths apply to the top, right, bottom, and left in that+ /// order.+ /// </summary>+ public string BorderWidth { get; set; } = "0 0 0 0";++ /// <summary>+ /// Padding in pixels.+ /// </summary>+ public string Padding { get; set; } = "1 6 1 6";+ }+}