diff --git a/CSharpImageLibrary/CSharpImageLibrary.csproj b/CSharpImageLibrary/CSharpImageLibrary.csproj
index 79686f0..df7e0fe 100644
--- a/CSharpImageLibrary/CSharpImageLibrary.csproj
+++ b/CSharpImageLibrary/CSharpImageLibrary.csproj
@@ -82,8 +82,8 @@
4.0
-
- ..\packages\UsefulCSharpThings.1.7.1\lib\net462\UsefulThings.dll
+
+ ..\packages\UsefulCSharpThings.1.7.2\lib\net462\UsefulThings.dll
diff --git a/CSharpImageLibrary/Properties/AssemblyInfo.cs b/CSharpImageLibrary/Properties/AssemblyInfo.cs
index d4ef740..c21952e 100644
--- a/CSharpImageLibrary/Properties/AssemblyInfo.cs
+++ b/CSharpImageLibrary/Properties/AssemblyInfo.cs
@@ -51,5 +51,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("4.0.1.0")]
-[assembly: AssemblyFileVersion("4.0.1.0")]
+[assembly: AssemblyVersion("4.0.2.0")]
+[assembly: AssemblyFileVersion("4.0.2.0")]
diff --git a/CSharpImageLibrary/packages.config b/CSharpImageLibrary/packages.config
index 151f583..7fc015d 100644
--- a/CSharpImageLibrary/packages.config
+++ b/CSharpImageLibrary/packages.config
@@ -2,5 +2,5 @@
-
+
\ No newline at end of file
diff --git a/UI_Project/App.config b/UI_Project/App.config
index 673dc0f..c94c5cf 100644
--- a/UI_Project/App.config
+++ b/UI_Project/App.config
@@ -27,6 +27,18 @@
-1
+
+ 0
+
+
+ 0
+
+
+ 0
+
+
+ 158
+
\ No newline at end of file
diff --git a/UI_Project/NewMainWindow.xaml b/UI_Project/NewMainWindow.xaml
index 7dbbf78..b37fb45 100644
--- a/UI_Project/NewMainWindow.xaml
+++ b/UI_Project/NewMainWindow.xaml
@@ -13,7 +13,7 @@
xmlns:Library="clr-namespace:CSharpImageLibrary;assembly=CSharpImageLibrary"
xmlns:UsefulWPF="clr-namespace:UsefulThings.WPF;assembly=UsefulThings"
mc:Ignorable="d"
- Title="NewMainWindow" Height="900" Width="1100" AllowsTransparency="True" Background="#9F000000" WindowStyle="None" ResizeMode="CanResizeWithGrip"
+ Title="NewMainWindow" Height="900" Width="1100" AllowsTransparency="True" Background="{Binding WindowBackgroundColour}" WindowStyle="None" ResizeMode="CanResizeWithGrip"
Loaded="Window_Loaded" d:DataContext="{d:DesignInstance Type=local:Design_ViewModel, IsDesignTimeCreatable=True}"
AllowDrop="True" DragOver="TOPWINDOW_DragOver" Drop="TOPWINDOW_Drop" KeyDown="TOPWINDOW_KeyDown" MouseLeftButtonDown="TOPWINDOW_MouseLeftButtonDown" MouseDown="TOPWINDOW_MouseDown" Closing="TOPWINDOW_Closing">
@@ -22,6 +22,7 @@
+
True
@@ -1021,13 +1022,9 @@
-
+
-
-
-
-
+
@@ -1038,6 +1035,39 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/UI_Project/NewMainWindow.xaml.cs b/UI_Project/NewMainWindow.xaml.cs
index 17c51e7..4e5c840 100644
--- a/UI_Project/NewMainWindow.xaml.cs
+++ b/UI_Project/NewMainWindow.xaml.cs
@@ -602,14 +602,27 @@ private void UseWindowTransparencyChecker_Checked(object sender, RoutedEventArgs
private void UseWindowTransparencyChecker_Unchecked(object sender, RoutedEventArgs e)
{
- //UsefulThings.WPF.WindowBlur.DisableBlur(this);
+ UsefulThings.WPF.WindowBlur.DisableBlur(this);
Properties.Settings.Default.IsWindowBlurred = false;
}
private void TOPWINDOW_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
Properties.Settings.Default.NumThreads = ImageEngine.NumThreads;
+ Properties.Settings.Default.BackgroundAlpha = vm.WindowBackground_Alpha;
+ Properties.Settings.Default.BackgroundRed = vm.WindowBackground_Red;
+ Properties.Settings.Default.BackgroundGreen = vm.WindowBackground_Green;
+ Properties.Settings.Default.BackgroundBlue = vm.WindowBackground_Blue;
Properties.Settings.Default.Save();
}
+
+ private void Settings_ColoursDefaultButton_Click(object sender, RoutedEventArgs e)
+ {
+ vm.WindowBackground_Alpha = 158;
+ vm.WindowBackground_Red = 0;
+ vm.WindowBackground_Green = 0;
+ vm.WindowBackground_Blue = 0;
+ UseWindowTransparencyChecker_Checked(null, null); // Blur background
+ }
}
}
diff --git a/UI_Project/NewViewModel.cs b/UI_Project/NewViewModel.cs
index 4b2d990..e522010 100644
--- a/UI_Project/NewViewModel.cs
+++ b/UI_Project/NewViewModel.cs
@@ -289,6 +289,70 @@ public bool MergeChannelsReady
#endregion Merge Channels Properties
#region General Properties
+ byte windowBackground_Red = 0;
+ public byte WindowBackground_Red
+ {
+ get
+ {
+ return windowBackground_Red;
+ }
+ set
+ {
+ SetProperty(ref windowBackground_Red, value);
+ OnPropertyChanged(nameof(WindowBackgroundColour));
+ }
+ }
+
+ byte windowBackground_Green = 0;
+ public byte WindowBackground_Green
+ {
+ get
+ {
+ return windowBackground_Green;
+ }
+ set
+ {
+ SetProperty(ref windowBackground_Green, value);
+ OnPropertyChanged(nameof(WindowBackgroundColour));
+ }
+ }
+
+ byte windowBackground_Blue = 0;
+ public byte WindowBackground_Blue
+ {
+ get
+ {
+ return windowBackground_Blue;
+ }
+ set
+ {
+ SetProperty(ref windowBackground_Blue, value);
+ OnPropertyChanged(nameof(WindowBackgroundColour));
+ }
+ }
+
+ byte windowBackground_Alpha = 158;
+ public byte WindowBackground_Alpha
+ {
+ get
+ {
+ return windowBackground_Alpha;
+ }
+ set
+ {
+ SetProperty(ref windowBackground_Alpha, value);
+ OnPropertyChanged(nameof(WindowBackgroundColour));
+ }
+ }
+
+ public Brush WindowBackgroundColour
+ {
+ get
+ {
+ return new SolidColorBrush(Color.FromArgb(WindowBackground_Alpha, WindowBackground_Red, WindowBackground_Green, WindowBackground_Blue));
+ }
+ }
+
bool splitChannels = false;
public bool SplitChannels
{
@@ -928,6 +992,7 @@ public int JPG_CompressionSetting
#endregion General Properties
+
public NewViewModel() : base()
{
// Space out the Output Window a bit
@@ -942,6 +1007,12 @@ public NewViewModel() : base()
};
MergeChannelsImages.CollectionChanged += (sender, args) => OnPropertyChanged(nameof(MergeChannelsReady));
+
+ // Set background colour
+ WindowBackground_Alpha = Properties.Settings.Default.BackgroundAlpha;
+ WindowBackground_Red = Properties.Settings.Default.BackgroundRed;
+ WindowBackground_Green = Properties.Settings.Default.BackgroundGreen;
+ WindowBackground_Blue = Properties.Settings.Default.BackgroundBlue;
}
internal async Task LoadImage(string path)
diff --git a/UI_Project/Properties/AssemblyInfo.cs b/UI_Project/Properties/AssemblyInfo.cs
index d0e059e..3e776b8 100644
--- a/UI_Project/Properties/AssemblyInfo.cs
+++ b/UI_Project/Properties/AssemblyInfo.cs
@@ -51,5 +51,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("1.1.0.0")]
-[assembly: AssemblyFileVersion("1.1.0.0")]
+[assembly: AssemblyVersion("1.1.1.0")]
+[assembly: AssemblyFileVersion("1.1.1.0")]
diff --git a/UI_Project/Properties/Settings.Designer.cs b/UI_Project/Properties/Settings.Designer.cs
index 7b7d9d7..39c02a3 100644
--- a/UI_Project/Properties/Settings.Designer.cs
+++ b/UI_Project/Properties/Settings.Designer.cs
@@ -58,5 +58,53 @@ public int NumThreads {
this["NumThreads"] = value;
}
}
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public byte BackgroundRed {
+ get {
+ return ((byte)(this["BackgroundRed"]));
+ }
+ set {
+ this["BackgroundRed"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public byte BackgroundGreen {
+ get {
+ return ((byte)(this["BackgroundGreen"]));
+ }
+ set {
+ this["BackgroundGreen"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public byte BackgroundBlue {
+ get {
+ return ((byte)(this["BackgroundBlue"]));
+ }
+ set {
+ this["BackgroundBlue"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("158")]
+ public byte BackgroundAlpha {
+ get {
+ return ((byte)(this["BackgroundAlpha"]));
+ }
+ set {
+ this["BackgroundAlpha"] = value;
+ }
+ }
}
}
diff --git a/UI_Project/Properties/Settings.settings b/UI_Project/Properties/Settings.settings
index e6f75b9..4b182e2 100644
--- a/UI_Project/Properties/Settings.settings
+++ b/UI_Project/Properties/Settings.settings
@@ -11,5 +11,17 @@
-1
+
+ 0
+
+
+ 0
+
+
+ 0
+
+
+ 158
+
\ No newline at end of file
diff --git a/UI_Project/UI_Project.csproj b/UI_Project/UI_Project.csproj
index 6e51a58..38b29ac 100644
--- a/UI_Project/UI_Project.csproj
+++ b/UI_Project/UI_Project.csproj
@@ -71,8 +71,8 @@
4.0
-
- ..\packages\UsefulCSharpThings.1.7.1\lib\net462\UsefulThings.dll
+
+ ..\packages\UsefulCSharpThings.1.7.2\lib\net462\UsefulThings.dll
diff --git a/UI_Project/packages.config b/UI_Project/packages.config
index 64700a3..c5f5db2 100644
--- a/UI_Project/packages.config
+++ b/UI_Project/packages.config
@@ -3,5 +3,5 @@
-
+
\ No newline at end of file