summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Palecki <[email protected]>2021-07-10 15:35:21 -0700
committerJacob Palecki <[email protected]>2021-07-10 15:35:21 -0700
commitaa04d5a61f89225a03dc3b155d4f3a93ffe4c5b8 (patch)
tree17a28ab918de1372de6bfd6548421972812fb50f
parentFix truncated sensitivity legend (diff)
downloadrawaccel-aa04d5a61f89225a03dc3b155d4f3a93ffe4c5b8.tar.xz
rawaccel-aa04d5a61f89225a03dc3b155d4f3a93ffe4c5b8.zip
Fixed default values by splitting into unique text boxes
-rw-r--r--grapher/Form1.Designer.cs292
-rw-r--r--grapher/Form1.cs18
-rw-r--r--grapher/Layouts/ClassicLayout.cs3
-rw-r--r--grapher/Layouts/DefaultLayout.cs3
-rw-r--r--grapher/Layouts/JumpLayout.cs5
-rw-r--r--grapher/Layouts/LUTLayout.cs3
-rw-r--r--grapher/Layouts/LayoutBase.cs25
-rw-r--r--grapher/Layouts/LinearLayout.cs3
-rw-r--r--grapher/Layouts/MotivityLayout.cs5
-rw-r--r--grapher/Layouts/NaturalLayout.cs5
-rw-r--r--grapher/Layouts/OffLayout.cs3
-rw-r--r--grapher/Layouts/PowerLayout.cs3
-rw-r--r--grapher/Layouts/UnsupportedLayout.cs3
-rw-r--r--grapher/Models/AccelGUIFactory.cs60
-rw-r--r--grapher/Models/Options/AccelTypeOptions.cs46
15 files changed, 408 insertions, 69 deletions
diff --git a/grapher/Form1.Designer.cs b/grapher/Form1.Designer.cs
index 7cb19fc..181c3e2 100644
--- a/grapher/Form1.Designer.cs
+++ b/grapher/Form1.Designer.cs
@@ -71,6 +71,24 @@ namespace grapher
System.Windows.Forms.DataVisualization.Charting.Title title6 = new System.Windows.Forms.DataVisualization.Charting.Title();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(RawAcceleration));
this.optionsPanel = new System.Windows.Forms.Panel();
+ this.GrowthRateActiveYLabel = new System.Windows.Forms.Label();
+ this.GrowthRateActiveXLabel = new System.Windows.Forms.Label();
+ this.DecayRateActiveYLabel = new System.Windows.Forms.Label();
+ this.DecayRateActiveXLabel = new System.Windows.Forms.Label();
+ this.growthRateLabelY = new System.Windows.Forms.Label();
+ this.growthRateLabelX = new System.Windows.Forms.Label();
+ this.decayRateLabelY = new System.Windows.Forms.Label();
+ this.decayRateLabelX = new System.Windows.Forms.Label();
+ this.growthRateBoxY = new System.Windows.Forms.TextBox();
+ this.growthRateBoxX = new System.Windows.Forms.TextBox();
+ this.decayRateBoxY = new System.Windows.Forms.TextBox();
+ this.decayRateBoxX = new System.Windows.Forms.TextBox();
+ this.PowerClassicActiveYLabel = new System.Windows.Forms.Label();
+ this.PowerClassicActiveXLabel = new System.Windows.Forms.Label();
+ this.powerLabelY = new System.Windows.Forms.Label();
+ this.powerLabelX = new System.Windows.Forms.Label();
+ this.powerBoxY = new System.Windows.Forms.TextBox();
+ this.powerBoxX = new System.Windows.Forms.TextBox();
this.YLutActiveValuesBox = new System.Windows.Forms.RichTextBox();
this.XLutActiveValuesBox = new System.Windows.Forms.RichTextBox();
this.LutApplyActiveYLabel = new System.Windows.Forms.Label();
@@ -199,12 +217,12 @@ namespace grapher
this.GainChart = new System.Windows.Forms.DataVisualization.Charting.Chart();
this.VelocityChart = new System.Windows.Forms.DataVisualization.Charting.Chart();
this.AccelerationChart = new System.Windows.Forms.DataVisualization.Charting.Chart();
- this.powerBoxX = new System.Windows.Forms.TextBox();
- this.powerBoxY = new System.Windows.Forms.TextBox();
- this.powerLabelX = new System.Windows.Forms.Label();
- this.powerLabelY = new System.Windows.Forms.Label();
- this.PowerClassicActiveXLabel = new System.Windows.Forms.Label();
- this.PowerClassicActiveYLabel = new System.Windows.Forms.Label();
+ this.smoothBoxX = new System.Windows.Forms.TextBox();
+ this.smoothBoxY = new System.Windows.Forms.TextBox();
+ this.smoothLabelX = new System.Windows.Forms.Label();
+ this.SmoothActiveXLabel = new System.Windows.Forms.Label();
+ this.smoothLabelY = new System.Windows.Forms.Label();
+ this.SmoothActiveYLabel = new System.Windows.Forms.Label();
this.optionsPanel.SuspendLayout();
this.DirectionalityPanel.SuspendLayout();
this.menuStrip1.SuspendLayout();
@@ -220,6 +238,24 @@ namespace grapher
// optionsPanel
//
this.optionsPanel.AutoSize = true;
+ this.optionsPanel.Controls.Add(this.SmoothActiveYLabel);
+ this.optionsPanel.Controls.Add(this.smoothLabelY);
+ this.optionsPanel.Controls.Add(this.SmoothActiveXLabel);
+ this.optionsPanel.Controls.Add(this.smoothLabelX);
+ this.optionsPanel.Controls.Add(this.smoothBoxY);
+ this.optionsPanel.Controls.Add(this.smoothBoxX);
+ this.optionsPanel.Controls.Add(this.GrowthRateActiveYLabel);
+ this.optionsPanel.Controls.Add(this.GrowthRateActiveXLabel);
+ this.optionsPanel.Controls.Add(this.DecayRateActiveYLabel);
+ this.optionsPanel.Controls.Add(this.DecayRateActiveXLabel);
+ this.optionsPanel.Controls.Add(this.growthRateLabelY);
+ this.optionsPanel.Controls.Add(this.growthRateLabelX);
+ this.optionsPanel.Controls.Add(this.decayRateLabelY);
+ this.optionsPanel.Controls.Add(this.decayRateLabelX);
+ this.optionsPanel.Controls.Add(this.growthRateBoxY);
+ this.optionsPanel.Controls.Add(this.growthRateBoxX);
+ this.optionsPanel.Controls.Add(this.decayRateBoxY);
+ this.optionsPanel.Controls.Add(this.decayRateBoxX);
this.optionsPanel.Controls.Add(this.PowerClassicActiveYLabel);
this.optionsPanel.Controls.Add(this.PowerClassicActiveXLabel);
this.optionsPanel.Controls.Add(this.powerLabelY);
@@ -322,6 +358,156 @@ namespace grapher
this.optionsPanel.Size = new System.Drawing.Size(483, 956);
this.optionsPanel.TabIndex = 34;
//
+ // GrowthRateActiveYLabel
+ //
+ this.GrowthRateActiveYLabel.AutoSize = true;
+ this.GrowthRateActiveYLabel.Location = new System.Drawing.Point(417, 647);
+ this.GrowthRateActiveYLabel.Name = "GrowthRateActiveYLabel";
+ this.GrowthRateActiveYLabel.Size = new System.Drawing.Size(13, 13);
+ this.GrowthRateActiveYLabel.TabIndex = 187;
+ this.GrowthRateActiveYLabel.Text = "0";
+ //
+ // GrowthRateActiveXLabel
+ //
+ this.GrowthRateActiveXLabel.AutoSize = true;
+ this.GrowthRateActiveXLabel.Location = new System.Drawing.Point(200, 647);
+ this.GrowthRateActiveXLabel.Name = "GrowthRateActiveXLabel";
+ this.GrowthRateActiveXLabel.Size = new System.Drawing.Size(13, 13);
+ this.GrowthRateActiveXLabel.TabIndex = 186;
+ this.GrowthRateActiveXLabel.Text = "0";
+ //
+ // DecayRateActiveYLabel
+ //
+ this.DecayRateActiveYLabel.AutoSize = true;
+ this.DecayRateActiveYLabel.Location = new System.Drawing.Point(417, 626);
+ this.DecayRateActiveYLabel.Name = "DecayRateActiveYLabel";
+ this.DecayRateActiveYLabel.Size = new System.Drawing.Size(13, 13);
+ this.DecayRateActiveYLabel.TabIndex = 185;
+ this.DecayRateActiveYLabel.Text = "0";
+ //
+ // DecayRateActiveXLabel
+ //
+ this.DecayRateActiveXLabel.AutoSize = true;
+ this.DecayRateActiveXLabel.Location = new System.Drawing.Point(200, 622);
+ this.DecayRateActiveXLabel.Name = "DecayRateActiveXLabel";
+ this.DecayRateActiveXLabel.Size = new System.Drawing.Size(13, 13);
+ this.DecayRateActiveXLabel.TabIndex = 184;
+ this.DecayRateActiveXLabel.Text = "0";
+ //
+ // growthRateLabelY
+ //
+ this.growthRateLabelY.AutoSize = true;
+ this.growthRateLabelY.Location = new System.Drawing.Point(262, 648);
+ this.growthRateLabelY.Name = "growthRateLabelY";
+ this.growthRateLabelY.Size = new System.Drawing.Size(67, 13);
+ this.growthRateLabelY.TabIndex = 183;
+ this.growthRateLabelY.Text = "Growth Rate";
+ //
+ // growthRateLabelX
+ //
+ this.growthRateLabelX.AutoSize = true;
+ this.growthRateLabelX.Location = new System.Drawing.Point(37, 648);
+ this.growthRateLabelX.Name = "growthRateLabelX";
+ this.growthRateLabelX.Size = new System.Drawing.Size(67, 13);
+ this.growthRateLabelX.TabIndex = 182;
+ this.growthRateLabelX.Text = "Growth Rate";
+ //
+ // decayRateLabelY
+ //
+ this.decayRateLabelY.AutoSize = true;
+ this.decayRateLabelY.Location = new System.Drawing.Point(262, 626);
+ this.decayRateLabelY.Name = "decayRateLabelY";
+ this.decayRateLabelY.Size = new System.Drawing.Size(64, 13);
+ this.decayRateLabelY.TabIndex = 181;
+ this.decayRateLabelY.Text = "Decay Rate";
+ //
+ // decayRateLabelX
+ //
+ this.decayRateLabelX.AutoSize = true;
+ this.decayRateLabelX.Location = new System.Drawing.Point(37, 622);
+ this.decayRateLabelX.Name = "decayRateLabelX";
+ this.decayRateLabelX.Size = new System.Drawing.Size(64, 13);
+ this.decayRateLabelX.TabIndex = 180;
+ this.decayRateLabelX.Text = "Decay Rate";
+ //
+ // growthRateBoxY
+ //
+ this.growthRateBoxY.Location = new System.Drawing.Point(332, 644);
+ this.growthRateBoxY.Name = "growthRateBoxY";
+ this.growthRateBoxY.Size = new System.Drawing.Size(76, 20);
+ this.growthRateBoxY.TabIndex = 179;
+ //
+ // growthRateBoxX
+ //
+ this.growthRateBoxX.Location = new System.Drawing.Point(106, 645);
+ this.growthRateBoxX.Name = "growthRateBoxX";
+ this.growthRateBoxX.Size = new System.Drawing.Size(76, 20);
+ this.growthRateBoxX.TabIndex = 178;
+ //
+ // decayRateBoxY
+ //
+ this.decayRateBoxY.Location = new System.Drawing.Point(332, 619);
+ this.decayRateBoxY.Name = "decayRateBoxY";
+ this.decayRateBoxY.Size = new System.Drawing.Size(76, 20);
+ this.decayRateBoxY.TabIndex = 177;
+ //
+ // decayRateBoxX
+ //
+ this.decayRateBoxX.Location = new System.Drawing.Point(106, 619);
+ this.decayRateBoxX.Name = "decayRateBoxX";
+ this.decayRateBoxX.Size = new System.Drawing.Size(76, 20);
+ this.decayRateBoxX.TabIndex = 176;
+ //
+ // PowerClassicActiveYLabel
+ //
+ this.PowerClassicActiveYLabel.AutoSize = true;
+ this.PowerClassicActiveYLabel.Location = new System.Drawing.Point(417, 599);
+ this.PowerClassicActiveYLabel.Name = "PowerClassicActiveYLabel";
+ this.PowerClassicActiveYLabel.Size = new System.Drawing.Size(13, 13);
+ this.PowerClassicActiveYLabel.TabIndex = 175;
+ this.PowerClassicActiveYLabel.Text = "0";
+ //
+ // PowerClassicActiveXLabel
+ //
+ this.PowerClassicActiveXLabel.AutoSize = true;
+ this.PowerClassicActiveXLabel.Location = new System.Drawing.Point(200, 599);
+ this.PowerClassicActiveXLabel.Name = "PowerClassicActiveXLabel";
+ this.PowerClassicActiveXLabel.Size = new System.Drawing.Size(13, 13);
+ this.PowerClassicActiveXLabel.TabIndex = 174;
+ this.PowerClassicActiveXLabel.Text = "0";
+ //
+ // powerLabelY
+ //
+ this.powerLabelY.AutoSize = true;
+ this.powerLabelY.Location = new System.Drawing.Point(263, 599);
+ this.powerLabelY.Name = "powerLabelY";
+ this.powerLabelY.Size = new System.Drawing.Size(37, 13);
+ this.powerLabelY.TabIndex = 173;
+ this.powerLabelY.Text = "Power";
+ //
+ // powerLabelX
+ //
+ this.powerLabelX.AutoSize = true;
+ this.powerLabelX.Location = new System.Drawing.Point(35, 595);
+ this.powerLabelX.Name = "powerLabelX";
+ this.powerLabelX.Size = new System.Drawing.Size(37, 13);
+ this.powerLabelX.TabIndex = 172;
+ this.powerLabelX.Text = "Power";
+ //
+ // powerBoxY
+ //
+ this.powerBoxY.Location = new System.Drawing.Point(332, 594);
+ this.powerBoxY.Name = "powerBoxY";
+ this.powerBoxY.Size = new System.Drawing.Size(76, 20);
+ this.powerBoxY.TabIndex = 171;
+ //
+ // powerBoxX
+ //
+ this.powerBoxX.Location = new System.Drawing.Point(106, 595);
+ this.powerBoxX.Name = "powerBoxX";
+ this.powerBoxX.Size = new System.Drawing.Size(76, 20);
+ this.powerBoxX.TabIndex = 170;
+ //
// YLutActiveValuesBox
//
this.YLutActiveValuesBox.Location = new System.Drawing.Point(397, 369);
@@ -1640,55 +1826,55 @@ namespace grapher
title6.Text = "Sensitivity";
this.AccelerationChart.Titles.Add(title6);
//
- // powerBoxX
+ // smoothBoxX
//
- this.powerBoxX.Location = new System.Drawing.Point(106, 595);
- this.powerBoxX.Name = "powerBoxX";
- this.powerBoxX.Size = new System.Drawing.Size(76, 20);
- this.powerBoxX.TabIndex = 170;
+ this.smoothBoxX.Location = new System.Drawing.Point(106, 672);
+ this.smoothBoxX.Name = "smoothBoxX";
+ this.smoothBoxX.Size = new System.Drawing.Size(76, 20);
+ this.smoothBoxX.TabIndex = 188;
//
- // powerBoxY
+ // smoothBoxY
//
- this.powerBoxY.Location = new System.Drawing.Point(332, 594);
- this.powerBoxY.Name = "powerBoxY";
- this.powerBoxY.Size = new System.Drawing.Size(76, 20);
- this.powerBoxY.TabIndex = 171;
+ this.smoothBoxY.Location = new System.Drawing.Point(332, 671);
+ this.smoothBoxY.Name = "smoothBoxY";
+ this.smoothBoxY.Size = new System.Drawing.Size(76, 20);
+ this.smoothBoxY.TabIndex = 189;
//
- // powerLabelX
+ // smoothLabelX
//
- this.powerLabelX.AutoSize = true;
- this.powerLabelX.Location = new System.Drawing.Point(41, 594);
- this.powerLabelX.Name = "powerLabelX";
- this.powerLabelX.Size = new System.Drawing.Size(35, 13);
- this.powerLabelX.TabIndex = 172;
- this.powerLabelX.Text = "label1";
+ this.smoothLabelX.AutoSize = true;
+ this.smoothLabelX.Location = new System.Drawing.Point(38, 677);
+ this.smoothLabelX.Name = "smoothLabelX";
+ this.smoothLabelX.Size = new System.Drawing.Size(43, 13);
+ this.smoothLabelX.TabIndex = 190;
+ this.smoothLabelX.Text = "Smooth";
//
- // powerLabelY
+ // SmoothActiveXLabel
//
- this.powerLabelY.AutoSize = true;
- this.powerLabelY.Location = new System.Drawing.Point(266, 600);
- this.powerLabelY.Name = "powerLabelY";
- this.powerLabelY.Size = new System.Drawing.Size(35, 13);
- this.powerLabelY.TabIndex = 173;
- this.powerLabelY.Text = "label2";
+ this.SmoothActiveXLabel.AutoSize = true;
+ this.SmoothActiveXLabel.Location = new System.Drawing.Point(200, 677);
+ this.SmoothActiveXLabel.Name = "SmoothActiveXLabel";
+ this.SmoothActiveXLabel.Size = new System.Drawing.Size(13, 13);
+ this.SmoothActiveXLabel.TabIndex = 191;
+ this.SmoothActiveXLabel.Text = "0";
//
- // PowerClassicActiveXLabel
+ // smoothLabelY
//
- this.PowerClassicActiveXLabel.AutoSize = true;
- this.PowerClassicActiveXLabel.Location = new System.Drawing.Point(200, 599);
- this.PowerClassicActiveXLabel.Name = "PowerClassicActiveXLabel";
- this.PowerClassicActiveXLabel.Size = new System.Drawing.Size(13, 13);
- this.PowerClassicActiveXLabel.TabIndex = 174;
- this.PowerClassicActiveXLabel.Text = "0";
+ this.smoothLabelY.AutoSize = true;
+ this.smoothLabelY.Location = new System.Drawing.Point(266, 677);
+ this.smoothLabelY.Name = "smoothLabelY";
+ this.smoothLabelY.Size = new System.Drawing.Size(43, 13);
+ this.smoothLabelY.TabIndex = 192;
+ this.smoothLabelY.Text = "Smooth";
//
- // PowerClassicActiveYLabel
+ // SmoothActiveYLabel
//
- this.PowerClassicActiveYLabel.AutoSize = true;
- this.PowerClassicActiveYLabel.Location = new System.Drawing.Point(417, 599);
- this.PowerClassicActiveYLabel.Name = "PowerClassicActiveYLabel";
- this.PowerClassicActiveYLabel.Size = new System.Drawing.Size(13, 13);
- this.PowerClassicActiveYLabel.TabIndex = 175;
- this.PowerClassicActiveYLabel.Text = "0";
+ this.SmoothActiveYLabel.AutoSize = true;
+ this.SmoothActiveYLabel.Location = new System.Drawing.Point(420, 678);
+ this.SmoothActiveYLabel.Name = "SmoothActiveYLabel";
+ this.SmoothActiveYLabel.Size = new System.Drawing.Size(13, 13);
+ this.SmoothActiveYLabel.TabIndex = 193;
+ this.SmoothActiveYLabel.Text = "0";
//
// RawAcceleration
//
@@ -1854,6 +2040,24 @@ namespace grapher
private System.Windows.Forms.TextBox powerBoxX;
private System.Windows.Forms.Label PowerClassicActiveYLabel;
private System.Windows.Forms.Label PowerClassicActiveXLabel;
+ private System.Windows.Forms.Label growthRateLabelY;
+ private System.Windows.Forms.Label growthRateLabelX;
+ private System.Windows.Forms.Label decayRateLabelY;
+ private System.Windows.Forms.Label decayRateLabelX;
+ private System.Windows.Forms.TextBox growthRateBoxY;
+ private System.Windows.Forms.TextBox growthRateBoxX;
+ private System.Windows.Forms.TextBox decayRateBoxY;
+ private System.Windows.Forms.TextBox decayRateBoxX;
+ private System.Windows.Forms.Label GrowthRateActiveYLabel;
+ private System.Windows.Forms.Label GrowthRateActiveXLabel;
+ private System.Windows.Forms.Label DecayRateActiveYLabel;
+ private System.Windows.Forms.Label DecayRateActiveXLabel;
+ private System.Windows.Forms.Label SmoothActiveYLabel;
+ private System.Windows.Forms.Label smoothLabelY;
+ private System.Windows.Forms.Label SmoothActiveXLabel;
+ private System.Windows.Forms.Label smoothLabelX;
+ private System.Windows.Forms.TextBox smoothBoxY;
+ private System.Windows.Forms.TextBox smoothBoxX;
}
}
diff --git a/grapher/Form1.cs b/grapher/Form1.cs
index a9a18fb..ba16a23 100644
--- a/grapher/Form1.cs
+++ b/grapher/Form1.cs
@@ -73,6 +73,12 @@ namespace grapher
offsetBoxY,
accelerationBoxX,
accelerationBoxY,
+ decayRateBoxX,
+ decayRateBoxY,
+ growthRateBoxX,
+ growthRateBoxY,
+ smoothBoxX,
+ smoothBoxY,
scaleBoxX,
scaleBoxY,
limitBoxX,
@@ -110,6 +116,12 @@ namespace grapher
offsetLabelY,
constantOneLabelX,
constantOneLabelY,
+ decayRateLabelX,
+ decayRateLabelY,
+ growthRateLabelX,
+ growthRateLabelY,
+ smoothLabelX,
+ smoothLabelY,
scaleLabelX,
scaleLabelY,
limitLabelX,
@@ -135,6 +147,12 @@ namespace grapher
OffsetActiveYLabel,
AccelerationActiveLabelX,
AccelerationActiveLabelY,
+ DecayRateActiveXLabel,
+ DecayRateActiveYLabel,
+ GrowthRateActiveXLabel,
+ GrowthRateActiveYLabel,
+ SmoothActiveXLabel,
+ SmoothActiveYLabel,
ScaleActiveXLabel,
ScaleActiveYLabel,
LimitActiveXLabel,
diff --git a/grapher/Layouts/ClassicLayout.cs b/grapher/Layouts/ClassicLayout.cs
index dd1a7d3..86756c9 100644
--- a/grapher/Layouts/ClassicLayout.cs
+++ b/grapher/Layouts/ClassicLayout.cs
@@ -12,6 +12,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(true, Gain);
AccelLayout = new OptionLayout(true, Acceleration);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(true, Cap);
WeightLayout = new OptionLayout(true, Weight);
diff --git a/grapher/Layouts/DefaultLayout.cs b/grapher/Layouts/DefaultLayout.cs
index d6a5f45..29d28f7 100644
--- a/grapher/Layouts/DefaultLayout.cs
+++ b/grapher/Layouts/DefaultLayout.cs
@@ -13,6 +13,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(true, Gain);
AccelLayout = new OptionLayout(true, Acceleration);
+ DecayRateLayout = new OptionLayout(true, DecayRate);
+ GrowthRateLayout = new OptionLayout(true, GrowthRate);
+ SmoothLayout = new OptionLayout(true, Smooth);
ScaleLayout = new OptionLayout(true, Scale);
CapLayout = new OptionLayout(true, Cap);
WeightLayout = new OptionLayout(true, Weight);
diff --git a/grapher/Layouts/JumpLayout.cs b/grapher/Layouts/JumpLayout.cs
index afb0d72..277297c 100644
--- a/grapher/Layouts/JumpLayout.cs
+++ b/grapher/Layouts/JumpLayout.cs
@@ -12,7 +12,10 @@ namespace grapher.Layouts
LogarithmicCharts = false;
GainSwitchOptionLayout = new OptionLayout(true, Gain);
- AccelLayout = new OptionLayout(true, Smooth);
+ AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(true, Smooth);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(true, Cap);
WeightLayout = new OptionLayout(false, Weight);
diff --git a/grapher/Layouts/LUTLayout.cs b/grapher/Layouts/LUTLayout.cs
index cf4d383..5848adb 100644
--- a/grapher/Layouts/LUTLayout.cs
+++ b/grapher/Layouts/LUTLayout.cs
@@ -21,6 +21,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(false, string.Empty);
AccelLayout = new OptionLayout(false, Acceleration);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, Cap);
WeightLayout = new OptionLayout(false, Weight);
diff --git a/grapher/Layouts/LayoutBase.cs b/grapher/Layouts/LayoutBase.cs
index bc95d8d..66260eb 100644
--- a/grapher/Layouts/LayoutBase.cs
+++ b/grapher/Layouts/LayoutBase.cs
@@ -5,6 +5,8 @@ namespace grapher.Layouts
public abstract class LayoutBase
{
public const string Acceleration = "Acceleration";
+ public const string GrowthRate = "Growth Rate";
+ public const string DecayRate = "Decay Rate";
public const string Scale = "Scale";
public const string Exponent = "Exponent";
public const string PowerClassic = "Power";
@@ -16,12 +18,13 @@ namespace grapher.Layouts
public const string Weight = "Weight";
public const string Smooth = "Smooth";
public const string Gain = "Gain";
- public const string GrowthRate = "Growth Rate";
- public const string DecayRate = "Decay Rate";
public LayoutBase()
{
AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, string.Empty);
WeightLayout = new OptionLayout(false, string.Empty);
@@ -48,6 +51,12 @@ namespace grapher.Layouts
protected OptionLayout AccelLayout { get; set; }
+ protected OptionLayout DecayRateLayout { get; set; }
+
+ protected OptionLayout GrowthRateLayout { get; set; }
+
+ protected OptionLayout SmoothLayout { get; set; }
+
protected OptionLayout ScaleLayout { get; set; }
protected OptionLayout CapLayout { get; set; }
@@ -80,6 +89,9 @@ namespace grapher.Layouts
public void Layout(
IOption gainSwitchOption,
IOption accelOption,
+ IOption decayRateOption,
+ IOption growthRateOption,
+ IOption smoothOption,
IOption scaleOption,
IOption capOption,
IOption weightOption,
@@ -99,6 +111,9 @@ namespace grapher.Layouts
foreach (var option in new (OptionLayout, IOption)[] {
(GainSwitchOptionLayout, gainSwitchOption),
(AccelLayout, accelOption),
+ (DecayRateLayout, decayRateOption),
+ (GrowthRateLayout, growthRateOption),
+ (SmoothLayout, smoothOption),
(ScaleLayout, scaleOption),
(CapLayout, capOption),
(WeightLayout, weightOption),
@@ -132,6 +147,9 @@ namespace grapher.Layouts
public void Layout(
IOption gainSwitchOption,
IOption accelOption,
+ IOption decayRateOption,
+ IOption growthRateOption,
+ IOption smoothOption,
IOption scaleOption,
IOption capOption,
IOption weightOption,
@@ -146,6 +164,9 @@ namespace grapher.Layouts
{
Layout(gainSwitchOption,
accelOption,
+ decayRateOption,
+ growthRateOption,
+ smoothOption,
scaleOption,
capOption,
weightOption,
diff --git a/grapher/Layouts/LinearLayout.cs b/grapher/Layouts/LinearLayout.cs
index 62d6f77..6108a0b 100644
--- a/grapher/Layouts/LinearLayout.cs
+++ b/grapher/Layouts/LinearLayout.cs
@@ -15,6 +15,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(true, Gain);
AccelLayout = new OptionLayout(true, Acceleration);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(true, Cap);
WeightLayout = new OptionLayout(false, Weight);
diff --git a/grapher/Layouts/MotivityLayout.cs b/grapher/Layouts/MotivityLayout.cs
index 17b4369..5443715 100644
--- a/grapher/Layouts/MotivityLayout.cs
+++ b/grapher/Layouts/MotivityLayout.cs
@@ -17,7 +17,10 @@ namespace grapher.Layouts
LogarithmicCharts = true;
GainSwitchOptionLayout = new OptionLayout(true, Gain);
- AccelLayout = new OptionLayout(true, GrowthRate);
+ AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(true, GrowthRate);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, string.Empty);
WeightLayout = new OptionLayout(false, string.Empty);
diff --git a/grapher/Layouts/NaturalLayout.cs b/grapher/Layouts/NaturalLayout.cs
index 97aef34..4702f50 100644
--- a/grapher/Layouts/NaturalLayout.cs
+++ b/grapher/Layouts/NaturalLayout.cs
@@ -12,7 +12,10 @@ namespace grapher.Layouts
LogarithmicCharts = false;
GainSwitchOptionLayout = new OptionLayout(true, Gain);
- AccelLayout = new OptionLayout(true, DecayRate);
+ AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(true, DecayRate);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, string.Empty);
WeightLayout = new OptionLayout(true, Weight);
diff --git a/grapher/Layouts/OffLayout.cs b/grapher/Layouts/OffLayout.cs
index e8f8565..d742ef8 100644
--- a/grapher/Layouts/OffLayout.cs
+++ b/grapher/Layouts/OffLayout.cs
@@ -13,6 +13,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(false, string.Empty);
AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, string.Empty);
WeightLayout = new OptionLayout(false, string.Empty);
diff --git a/grapher/Layouts/PowerLayout.cs b/grapher/Layouts/PowerLayout.cs
index a09bf9f..d11480f 100644
--- a/grapher/Layouts/PowerLayout.cs
+++ b/grapher/Layouts/PowerLayout.cs
@@ -11,6 +11,9 @@
GainSwitchOptionLayout = new OptionLayout(true, Gain);
AccelLayout = new OptionLayout(false, string.Empty);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(true, Scale);
CapLayout = new OptionLayout(true, Cap);
WeightLayout = new OptionLayout(true, Weight);
diff --git a/grapher/Layouts/UnsupportedLayout.cs b/grapher/Layouts/UnsupportedLayout.cs
index 04f0e55..4a401a4 100644
--- a/grapher/Layouts/UnsupportedLayout.cs
+++ b/grapher/Layouts/UnsupportedLayout.cs
@@ -18,6 +18,9 @@ namespace grapher.Layouts
GainSwitchOptionLayout = new OptionLayout(false, string.Empty);
AccelLayout = new OptionLayout(false, Acceleration);
+ DecayRateLayout = new OptionLayout(false, string.Empty);
+ GrowthRateLayout = new OptionLayout(false, string.Empty);
+ SmoothLayout = new OptionLayout(false, string.Empty);
ScaleLayout = new OptionLayout(false, string.Empty);
CapLayout = new OptionLayout(false, Cap);
WeightLayout = new OptionLayout(false, Weight);
diff --git a/grapher/Models/AccelGUIFactory.cs b/grapher/Models/AccelGUIFactory.cs
index 39119e7..c584773 100644
--- a/grapher/Models/AccelGUIFactory.cs
+++ b/grapher/Models/AccelGUIFactory.cs
@@ -50,6 +50,12 @@ namespace grapher.Models
TextBox offsetBoxY,
TextBox accelerationBoxX,
TextBox accelerationBoxY,
+ TextBox decayRateBoxX,
+ TextBox decayRateBoxY,
+ TextBox growthRateBoxX,
+ TextBox growthRateBoxY,
+ TextBox smoothBoxX,
+ TextBox smoothBoxY,
TextBox scaleBoxX,
TextBox scaleBoxY,
TextBox limitBoxX,
@@ -87,6 +93,12 @@ namespace grapher.Models
Label offsetLabelY,
Label constantOneLabelX,
Label constantOneLabelY,
+ Label decayRateLabelX,
+ Label decayRateLabelY,
+ Label growthRateLabelX,
+ Label growthRateLabelY,
+ Label smoothLabelX,
+ Label smoothLabelY,
Label scaleLabelX,
Label scaleLabelY,
Label limitLabelX,
@@ -112,6 +124,12 @@ namespace grapher.Models
Label offsetActiveLabelY,
Label accelerationActiveLabelX,
Label accelerationActiveLabelY,
+ Label decayRateActiveLabelX,
+ Label decayRateActiveLabelY,
+ Label growthRateActiveLabelX,
+ Label growthRateActiveLabelY,
+ Label smoothActiveLabelX,
+ Label smoothActiveLabelY,
Label scaleActiveLabelX,
Label scaleActiveLabelY,
Label limitActiveLabelX,
@@ -255,6 +273,42 @@ namespace grapher.Models
new ActiveValueLabel(accelerationActiveLabelY, activeValueTitleY),
optionSetYLeft);
+ var decayRateX = new Option(
+ new Field(decayRateBoxX, form, 0),
+ decayRateLabelX,
+ new ActiveValueLabel(decayRateActiveLabelX, activeValueTitleX),
+ 0);
+
+ var decayRateY = new Option(
+ new Field(decayRateBoxY, form, 0),
+ decayRateLabelY,
+ new ActiveValueLabel(decayRateActiveLabelY, activeValueTitleY),
+ 0);
+
+ var growthRateX = new Option(
+ new Field(growthRateBoxX, form, 0),
+ growthRateLabelX,
+ new ActiveValueLabel(growthRateActiveLabelX, activeValueTitleX),
+ 0);
+
+ var growthRateY = new Option(
+ new Field(growthRateBoxY, form, 0),
+ growthRateLabelY,
+ new ActiveValueLabel(growthRateActiveLabelY, activeValueTitleY),
+ 0);
+
+ var smoothX = new Option(
+ new Field(smoothBoxX, form, 0),
+ smoothLabelX,
+ new ActiveValueLabel(smoothActiveLabelX, activeValueTitleX),
+ 0);
+
+ var smoothY = new Option(
+ new Field(smoothBoxY, form, 0),
+ smoothLabelY,
+ new ActiveValueLabel(smoothActiveLabelY, activeValueTitleY),
+ 0);
+
var scaleX = new Option(
new Field(scaleBoxX, form, 0),
scaleLabelX,
@@ -359,6 +413,9 @@ namespace grapher.Models
accelTypeDropX,
gainSwitchOptionX,
accelerationX,
+ decayRateX,
+ growthRateX,
+ smoothX,
scaleX,
capX,
weightX,
@@ -380,6 +437,9 @@ namespace grapher.Models
accelTypeDropY,
gainSwitchOptionY,
accelerationY,
+ decayRateY,
+ growthRateY,
+ smoothY,
scaleY,
capY,
weightY,
diff --git a/grapher/Models/Options/AccelTypeOptions.cs b/grapher/Models/Options/AccelTypeOptions.cs
index 169426d..9d94787 100644
--- a/grapher/Models/Options/AccelTypeOptions.cs
+++ b/grapher/Models/Options/AccelTypeOptions.cs
@@ -31,6 +31,9 @@ namespace grapher
ComboBox accelDropdown,
CheckBoxOption gainSwitch,
Option acceleration,
+ Option decayRate,
+ Option growthRate,
+ Option smooth,
Option scale,
Option cap,
Option weight,
@@ -64,6 +67,9 @@ namespace grapher
GainSwitch = gainSwitch;
Acceleration = acceleration;
+ DecayRate = decayRate;
+ GrowthRate = growthRate;
+ Smooth = smooth;
Scale = scale;
Cap = cap;
Weight = weight;
@@ -105,6 +111,12 @@ namespace grapher
public Option Acceleration { get; }
+ public Option DecayRate { get; }
+
+ public Option GrowthRate { get; }
+
+ public Option Smooth { get; }
+
public Option Scale { get; }
public Option Cap { get; }
@@ -218,6 +230,9 @@ namespace grapher
GainSwitch.Hide();
Acceleration.Hide();
+ DecayRate.Hide();
+ GrowthRate.Hide();
+ Smooth.Hide();
Scale.Hide();
Cap.Hide();
Weight.Hide();
@@ -251,7 +266,10 @@ namespace grapher
Weight.SetActiveValue(args.weight);
Cap.SetActiveValue(args.cap);
Offset.SetActiveValue(args.offset);
- Acceleration.SetActiveValue(AccelerationParameterFromArgs(ref args));
+ Acceleration.SetActiveValue(args.accelClassic);
+ DecayRate.SetActiveValue(args.decayRate);
+ GrowthRate.SetActiveValue(args.growthRate);
+ Smooth.SetActiveValue(args.smooth);
Scale.SetActiveValue(args.scale);
Limit.SetActiveValue(args.limit);
PowerClassic.SetActiveValue(args.power);
@@ -293,27 +311,12 @@ namespace grapher
if (AccelerationType == Unsupported) throw new NotImplementedException();
args.mode = AccelerationType.Mode;
-
- if (Acceleration.Visible)
- {
- if (args.mode == AccelMode.natural)
- {
- args.decayRate = Acceleration.Field.Data;
- }
- else if (args.mode == AccelMode.motivity)
- {
- args.growthRate = Acceleration.Field.Data;
- }
- else
- {
- args.accelClassic = Acceleration.Field.Data;
- }
-
- args.smooth = Acceleration.Field.Data;
- }
-
args.legacy = !GainSwitch.CheckBox.Checked;
+ if (Acceleration.Visible) args.accelClassic = Acceleration.Field.Data;
+ if (DecayRate.Visible) args.decayRate = DecayRate.Field.Data;
+ if (GrowthRate.Visible) args.growthRate = DecayRate.Field.Data;
+ if (Smooth.Visible) args.smooth = DecayRate.Field.Data;
if (Scale.Visible) args.scale = Scale.Field.Data;
if (Cap.Visible) args.cap = Cap.Field.Data;
if (Limit.Visible) args.limit = Limit.Field.Data;
@@ -372,6 +375,9 @@ namespace grapher
AccelerationType.Layout(
GainSwitch,
Acceleration,
+ DecayRate,
+ GrowthRate,
+ Smooth,
Scale,
Cap,
Weight,