summaryrefslogtreecommitdiff
path: root/grapher/Models/Fields/FieldXY.cs
diff options
context:
space:
mode:
Diffstat (limited to 'grapher/Models/Fields/FieldXY.cs')
-rw-r--r--grapher/Models/Fields/FieldXY.cs17
1 files changed, 17 insertions, 0 deletions
diff --git a/grapher/Models/Fields/FieldXY.cs b/grapher/Models/Fields/FieldXY.cs
index 87e0b9c..83f6434 100644
--- a/grapher/Models/Fields/FieldXY.cs
+++ b/grapher/Models/Fields/FieldXY.cs
@@ -9,10 +9,16 @@ namespace grapher
{
public class FieldXY
{
+ #region Constants
+
public const int DefaultSeparation = 4;
public const string ShortenedFormatString = "0.###";
+ #endregion Constants
+
+ #region Constructors
+
public FieldXY(TextBox xBox, TextBox yBox, CheckBox lockCheckBox, Form containingForm, double defaultData)
{
XField = new Field(xBox, containingForm, defaultData);
@@ -32,6 +38,11 @@ namespace grapher
CombinedWidth = DefaultWidthX + DefaultWidthY + YField.Box.Left - (XField.Box.Left + DefaultWidthX);
SetCombined();
}
+
+ #endregion Constructors
+
+ #region Properties
+
public double X
{
get => XField.Data;
@@ -66,6 +77,10 @@ namespace grapher
private int CombinedWidth { get; }
+ #endregion Properties
+
+ #region Methods
+
private void CheckChanged(object sender, EventArgs e)
{
if (LockCheckBox.CheckState == CheckState.Checked)
@@ -126,5 +141,7 @@ namespace grapher
XField.Box.Hide();
YField.Box.Hide();
}
+
+ #endregion Methods
}
}