Skip to content

Commit f935be6

Browse files
committed
Final decision on project/namespace name
I'm deciding on renaming the main project, namespace and assembly to "AGaugeClassic" to differentiate it from the previous iteration of AGauge. The control its self will now be AGauge instead of AGaugeControl. Also doing some small cleanup in files as I correct references. Applying changes to workflow files.
1 parent d82491f commit f935be6

19 files changed

+99
-194
lines changed

.github/workflows/build-debug.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
- name: Build Project
2626
run: >
27-
dotnet build ${{ env.PRIMARY_FOLDER }}\AGauge.csproj
27+
dotnet build ${{ env.PRIMARY_FOLDER }}\AGaugeClassic.csproj
2828
--nologo
2929
-c Debug
3030
-p:Version=1.0.0.0

.github/workflows/build-release.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
- name: Build Project
2626
run: >
27-
dotnet build ${{ env.PRIMARY_FOLDER }}\AGauge.csproj
27+
dotnet build ${{ env.PRIMARY_FOLDER }}\AGaugeClassic.csproj
2828
--nologo
2929
-c Release
3030
-p:Version=${{ steps.exVer.outputs.ASMVER }}

AGauge.sln

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio Version 17
44
VisualStudioVersion = 17.9.34728.123
55
MinimumVisualStudioVersion = 10.0.40219.1
6-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AGauge", "AGauge\AGauge.csproj", "{3CF36E77-CD6E-428A-89F9-31C8C8E595C7}"
6+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AGaugeClassic", "AGauge\AGaugeClassic.csproj", "{3CF36E77-CD6E-428A-89F9-31C8C8E595C7}"
77
EndProject
88
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AGaugeDemo", "AGaugeDemo\AGaugeDemo.csproj", "{B5DBBA7D-17B1-4688-AB92-E09208D7D3BB}"
99
EndProject

AGauge/AGaugeControl.Designer.cs AGauge/AGauge.Designer.cs

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

AGauge/AGaugeControl.cs AGauge/AGauge.cs

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@
77
using System.Drawing.Drawing2D;
88
using System.Windows.Forms;
99

10-
namespace AGauge
10+
namespace AGaugeClassic
1111
{
1212

1313
/// <summary>
1414
/// .NET Framework WinForms Gauge control
1515
/// </summary>
16-
[ToolboxBitmap(typeof(AGaugeControl), "AGaugeControl.AGaugeControl.bmp"),
16+
[ToolboxBitmap(typeof(AGauge), "AGaugeControl.AGaugeControl.bmp"),
1717
DefaultEvent("ValueInRangeChanged"),
1818
Description("Displays a value on an analog gauge. Raises an event if the value enters one of the definable ranges.")]
19-
public partial class AGaugeControl : Control
19+
public partial class AGauge : Control
2020
{
2121
#region Defaults/Constants
2222
private const int MINIMUM_RANGE = 1; // The smallest difference between max and min.
@@ -808,7 +808,7 @@ public int NeedleWidth
808808

809809
#endregion
810810

811-
public AGaugeControl()
811+
public AGauge()
812812
{
813813
_GaugeRanges = new AGaugeRangeCollection(this);
814814
_GaugeLabels = new AGaugeLabelCollection(this);
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,47 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
2-
<PropertyGroup>
3-
<TargetFramework>net472</TargetFramework>
4-
<UseWindowsForms>true</UseWindowsForms>
5-
<ImportWindowsDesktopTargets>true</ImportWindowsDesktopTargets>
6-
</PropertyGroup>
7-
<ItemGroup>
8-
<Compile Update="AGaugeControl.cs" />
9-
</ItemGroup>
10-
<ItemGroup>
11-
<None Include="..\LICENSE">
12-
<Pack>True</Pack>
13-
<PackagePath>\</PackagePath>
14-
</None>
15-
<None Include="..\README.md">
16-
<Pack>True</Pack>
17-
<PackagePath>\</PackagePath>
18-
</None>
19-
</ItemGroup>
20-
<ItemGroup>
21-
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
22-
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
23-
</ItemGroup>
24-
<ItemGroup>
25-
<None Update="AGauge.png">
26-
<Pack>True</Pack>
27-
<PackagePath>\</PackagePath>
28-
</None>
29-
</ItemGroup>
30-
<PropertyGroup>
31-
<Description>Customizable WinForms gauge control - maintained by the NUTDotNet organization.</Description>
32-
<Authors>A. J. Bauer, with further work by Code Artist and others.</Authors>
33-
<Version />
34-
<Company>NUTDotNet Organization</Company>
35-
<Copyright>Copyright © NUTDotNet 2023-2024</Copyright>
36-
<PackageProjectUrl>https://github.com/nutdotnet/AGauge</PackageProjectUrl>
37-
<PackageIcon>AGauge.png</PackageIcon>
38-
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
39-
<PackageReadmeFile>README.md</PackageReadmeFile>
40-
<RepositoryUrl>https://github.com/nutdotnet/AGauge.git</RepositoryUrl>
41-
<PackageTags>gauge, winforms, control</PackageTags>
42-
<PackageLicenseFile>LICENSE</PackageLicenseFile>
43-
<IncludeSymbols>True</IncludeSymbols>
44-
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
45-
<PackageId>AGauge.Classic</PackageId>
46-
</PropertyGroup>
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
<PropertyGroup>
3+
<TargetFramework>net472</TargetFramework>
4+
<UseWindowsForms>true</UseWindowsForms>
5+
<ImportWindowsDesktopTargets>true</ImportWindowsDesktopTargets>
6+
</PropertyGroup>
7+
<ItemGroup>
8+
<Compile Update="AGauge.cs" />
9+
</ItemGroup>
10+
<ItemGroup>
11+
<None Include="..\LICENSE">
12+
<Pack>True</Pack>
13+
<PackagePath>\</PackagePath>
14+
</None>
15+
<None Include="..\README.md">
16+
<Pack>True</Pack>
17+
<PackagePath>\</PackagePath>
18+
</None>
19+
</ItemGroup>
20+
<ItemGroup>
21+
<PackageReference Include="Microsoft.CSharp" Version="4.7.0" />
22+
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
23+
</ItemGroup>
24+
<ItemGroup>
25+
<None Update="AGauge.png">
26+
<Pack>True</Pack>
27+
<PackagePath>\</PackagePath>
28+
</None>
29+
</ItemGroup>
30+
<PropertyGroup>
31+
<Description>Customizable WinForms gauge control - maintained by the NUTDotNet organization.</Description>
32+
<Authors>A. J. Bauer, with further work by Code Artist and others.</Authors>
33+
<Version />
34+
<Company>NUTDotNet Organization</Company>
35+
<Copyright>Copyright © NUTDotNet 2023-2024</Copyright>
36+
<PackageProjectUrl>https://github.com/nutdotnet/AGauge</PackageProjectUrl>
37+
<PackageIcon>AGauge.png</PackageIcon>
38+
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
39+
<PackageReadmeFile>README.md</PackageReadmeFile>
40+
<RepositoryUrl>https://github.com/nutdotnet/AGauge.git</RepositoryUrl>
41+
<PackageTags>gauge, winforms, control</PackageTags>
42+
<PackageLicenseFile>LICENSE</PackageLicenseFile>
43+
<IncludeSymbols>True</IncludeSymbols>
44+
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
45+
<PackageId>AGauge.Classic</PackageId>
46+
</PropertyGroup>
4747
</Project>

AGauge/AGaugeLabel.cs

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using System;
22
using System.Drawing;
33

4-
namespace AGauge
4+
namespace AGaugeClassic
55
{
66
public class AGaugeLabel
77
{
@@ -13,24 +13,24 @@ public class AGaugeLabel
1313
private string _Name;
1414

1515
[System.ComponentModel.Browsable(false)]
16-
public void SetOwner(AGaugeControl value) { Owner = value; }
17-
private AGaugeControl Owner;
16+
public void SetOwner(AGauge value) { Owner = value; }
17+
private AGauge Owner;
1818

1919
private void NotifyOwner() { if (Owner != null) Owner.RepaintControl(); }
2020

2121
private void NotifyChanging()
2222
{
2323
if (Owner != null)
2424
{
25-
Owner.NotifyChanging(nameof(AGaugeControl.GaugeLabels));
25+
Owner.NotifyChanging(nameof(AGauge.GaugeLabels));
2626
}
2727
}
2828

2929
private void NotifyChanged()
3030
{
3131
if (Owner != null)
3232
{
33-
Owner.NotifyChanged(nameof(AGaugeControl.GaugeLabels));
33+
Owner.NotifyChanged(nameof(AGauge.GaugeLabels));
3434
}
3535
}
3636

AGauge/AGaugeLabelCollection.cs

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
using System.Collections;
22

3-
namespace AGauge
3+
namespace AGaugeClassic
44
{
55
public class AGaugeLabelCollection : CollectionBase
66
{
7-
private readonly AGaugeControl m_Owner;
7+
private readonly AGauge m_Owner;
88

9-
public AGaugeLabelCollection(AGaugeControl sender)
9+
public AGaugeLabelCollection(AGauge sender)
1010
{
1111
m_Owner = sender;
1212
}
@@ -15,15 +15,15 @@ private void NotifyChanging()
1515
{
1616
if (m_Owner != null)
1717
{
18-
m_Owner.NotifyChanging(nameof(AGaugeControl.GaugeLabels));
18+
m_Owner.NotifyChanging(nameof(AGauge.GaugeLabels));
1919
}
2020
}
2121

2222
private void NotifyChanged()
2323
{
2424
if (m_Owner != null)
2525
{
26-
m_Owner.NotifyChanged(nameof(AGaugeControl.GaugeLabels));
26+
m_Owner.NotifyChanged(nameof(AGauge.GaugeLabels));
2727
}
2828
}
2929

AGauge/AGaugeNeedleColor.cs

+1-26
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,4 @@
1-
// Copyright (C) 2007 A.J.Bauer
2-
//
3-
// This software is provided as-is, without any express or implied
4-
// warranty. In no event will the authors be held liable for any damages
5-
// arising from the use of this software.
6-
7-
// Permission is granted to anyone to use this software for any purpose,
8-
// including commercial applications, and to alter it and redistribute it
9-
// freely, subject to the following restrictions:
10-
// 1. The origin of this software must not be misrepresented; you must not
11-
// claim that you wrote the original software. if you use this software
12-
// in a product, an acknowledgment in the product documentation would be
13-
// appreciated but is not required.
14-
// 2. Altered source versions must be plainly marked as such, and must not be
15-
// misrepresented as being the original software.
16-
// 3. This notice may not be removed or altered from any source distribution.
17-
//
18-
// -----------------------------------------------------------------------------------
19-
// Copyright (C) 2012 Code Artist
20-
//
21-
// Added several improvement to original code created by A.J.Bauer.
22-
// Visit: http://codearteng.blogspot.com for more information on change history.
23-
//
24-
// -----------------------------------------------------------------------------------
25-
26-
namespace System.Windows.Forms
1+
namespace AGaugeClassic
272
{
283
/// <summary>
294
/// First needle color

AGauge/AGaugeRange.cs

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using System;
22
using System.Drawing;
33

4-
namespace AGauge
4+
namespace AGaugeClassic
55
{
66
public class AGaugeRange
77
{
@@ -33,23 +33,23 @@ public AGaugeRange(Color color, Single startValue, Single endValue, Int32 innerR
3333
[System.ComponentModel.Browsable(false)]
3434
public Boolean InRange { get; set; }
3535

36-
private AGaugeControl Owner;
36+
private AGauge Owner;
3737
[System.ComponentModel.Browsable(false)]
38-
public void SetOwner(AGaugeControl value) { Owner = value; }
38+
public void SetOwner(AGauge value) { Owner = value; }
3939
private void NotifyOwner() { if (Owner != null) Owner.RepaintControl(); }
4040
private void NotifyChanging()
4141
{
4242
if (Owner != null)
4343
{
44-
Owner.NotifyChanging(nameof(AGaugeControl.GaugeRanges));
44+
Owner.NotifyChanging(nameof(AGauge.GaugeRanges));
4545
}
4646
}
4747

4848
private void NotifyChanged()
4949
{
5050
if (Owner != null)
5151
{
52-
Owner.NotifyChanged(nameof(AGaugeControl.GaugeRanges));
52+
Owner.NotifyChanged(nameof(AGauge.GaugeRanges));
5353
}
5454
}
5555

AGauge/AGaugeRangeCollection.cs

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
using System.Collections;
22

3-
namespace AGauge
3+
namespace AGaugeClassic
44
{
55
public class AGaugeRangeCollection : CollectionBase
66
{
7-
private AGaugeControl m_Owner;
8-
public AGaugeRangeCollection(AGaugeControl sender) { m_Owner = sender; }
7+
private AGauge m_Owner;
8+
public AGaugeRangeCollection(AGauge sender) { m_Owner = sender; }
99
private void NotifyChanging()
1010
{
1111
if (m_Owner != null)
1212
{
13-
m_Owner.NotifyChanging(nameof(AGaugeControl.GaugeRanges));
13+
m_Owner.NotifyChanging(nameof(AGauge.GaugeRanges));
1414
}
1515
}
1616

1717
private void NotifyChanged()
1818
{
1919
if (m_Owner != null)
2020
{
21-
m_Owner.NotifyChanged(nameof(AGaugeControl.GaugeRanges));
21+
m_Owner.NotifyChanged(nameof(AGauge.GaugeRanges));
2222
}
2323
}
2424

AGauge/Categories.cs

+2-7
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,6 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Text;
5-
6-
namespace System.Windows.Forms
1+
namespace AGaugeClassic
72
{
8-
internal static class Categories
3+
internal static class Categories
94
{
105
public const string Appearance = "Appearance";
116

AGauge/NeedleType.cs

+1-26
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,4 @@
1-
// Copyright (C) 2007 A.J.Bauer
2-
//
3-
// This software is provided as-is, without any express or implied
4-
// warranty. In no event will the authors be held liable for any damages
5-
// arising from the use of this software.
6-
7-
// Permission is granted to anyone to use this software for any purpose,
8-
// including commercial applications, and to alter it and redistribute it
9-
// freely, subject to the following restrictions:
10-
// 1. The origin of this software must not be misrepresented; you must not
11-
// claim that you wrote the original software. if you use this software
12-
// in a product, an acknowledgment in the product documentation would be
13-
// appreciated but is not required.
14-
// 2. Altered source versions must be plainly marked as such, and must not be
15-
// misrepresented as being the original software.
16-
// 3. This notice may not be removed or altered from any source distribution.
17-
//
18-
// -----------------------------------------------------------------------------------
19-
// Copyright (C) 2012 Code Artist
20-
//
21-
// Added several improvement to original code created by A.J.Bauer.
22-
// Visit: http://codearteng.blogspot.com for more information on change history.
23-
//
24-
// -----------------------------------------------------------------------------------
25-
26-
namespace System.Windows.Forms
1+
namespace AGaugeClassic
272
{
283
public enum NeedleType
294
{

0 commit comments

Comments
 (0)