VOID_DataValue: Reworked the way DoGUIHorizontal works, particularly the flow around the variable precision version. Use clicks to the label now instead of GUILayout.Button()s.
VOID_DataValue: Reworked the way DoGUIHorizontal works, particularly the flow around the variable precision version. Use clicks to the label now instead of GUILayout.Button()s.

--- a/VOID_Core.cs
+++ b/VOID_Core.cs
@@ -434,6 +434,9 @@
 
 		protected void LoadGUIStyles()
 		{
+			this.LabelStyles["link"] = new GUIStyle(GUI.skin.label);
+			this.LabelStyles["link"].fontStyle = FontStyle.Bold;
+
 			this.LabelStyles["center"] = new GUIStyle(GUI.skin.label);
 			this.LabelStyles["center"].normal.textColor = Color.white;
 			this.LabelStyles["center"].alignment = TextAnchor.UpperCenter;
@@ -446,6 +449,10 @@
 			this.LabelStyles["right"] = new GUIStyle(GUI.skin.label);
 			this.LabelStyles["right"].normal.textColor = Color.white;
 			this.LabelStyles["right"].alignment = TextAnchor.UpperRight;
+
+			this.LabelStyles ["red"] = new GUIStyle(GUI.skin.label);
+			this.LabelStyles ["red"].normal.textColor = Color.red;
+			this.LabelStyles ["red"].alignment = TextAnchor.MiddleCenter;
 
 			this.GUIStylesLoaded = true;
 		}
@@ -508,10 +515,7 @@
 			}
 			else
 			{
-			    GUIStyle label_txt_red = new GUIStyle(GUI.skin.label);
-			    label_txt_red.normal.textColor = Color.red;
-			    label_txt_red.alignment = TextAnchor.MiddleCenter;
-			    GUILayout.Label("-- POWER LOST --", label_txt_red);
+			    GUILayout.Label("-- POWER LOST --", this.LabelStyles["red"]);
 			}
 
 			this.configWindowMinimized = !GUILayout.Toggle (!this.configWindowMinimized, "Configuration");
@@ -687,7 +691,7 @@
 
 			this.VOIDIconTexture = this.VOIDIconOff;  //icon off default
 			if (this.togglePower) this.VOIDIconTexture = this.VOIDIconOn;     //or on if power_toggle==true
-			if (GUI.Button(VOIDIconPos, VOIDIconTexture, new GUIStyle()) && this.VOIDIconLocked)
+			if (GUI.Button(VOIDIconPos, VOIDIconTexture) && this.VOIDIconLocked)
 			{
 				this.mainGuiMinimized = !this.mainGuiMinimized;
 			}

--- a/VOID_DataValue.cs
+++ b/VOID_DataValue.cs
@@ -123,11 +123,11 @@
 
 		public abstract string ValueUnitString(string format);
 		
-		public virtual string ValueUnitString(ushort digits) {
+		public virtual string ValueUnitString(int digits) {
 			return Tools.MuMech_ToSI(this.ToDouble(), digits) + this.Units;
 		}
 
-		public virtual string ValueUnitString(ushort digits, int MinMagnitude, int MaxMagnitude)
+		public virtual string ValueUnitString(int digits, int MinMagnitude, int MaxMagnitude)
 		{
 			return Tools.MuMech_ToSI(this.ToDouble(), digits, MinMagnitude, MaxMagnitude) + this.Units;
 		}
@@ -141,38 +141,61 @@
 			GUILayout.EndHorizontal ();
 		}
 
-		public virtual ushort DoGUIHorizontal(ushort digits, bool precisionButton = true)
-		{
-			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
-			GUILayout.Label(this.Label + ":", GUILayout.ExpandWidth(true));
-			GUILayout.FlexibleSpace();
+		public virtual int DoGUIHorizontal(int digits, bool precisionButton = true)
+		{
 			if (precisionButton)
 			{
-				float magnitude = (float)Math.Log10(Math.Abs(this.ToDouble()));
-				GUILayout.Label(this.ValueUnitString(3, int.MinValue, (int)magnitude - digits), GUILayout.ExpandWidth(false));
-				if (GUILayout.Button(digits.ToString()))
+				return this.DoGUIHorizontalPrec(digits);
+			}
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			GUILayout.Label(this.Label + " (P" + digits + "):", GUILayout.ExpandWidth(true));
+			GUILayout.FlexibleSpace();
+			GUILayout.Label(this.ValueUnitString(digits), GUILayout.ExpandWidth(false));
+			GUILayout.EndHorizontal();
+
+			return digits;
+		}
+
+		public virtual int DoGUIHorizontalPrec(int digits)
+		{
+			float magnitude;
+			float magLimit;
+
+			magnitude = (float)Math.Log10(Math.Abs(this.ToDouble()));
+
+			magLimit = Mathf.Max(magnitude, 6f);
+			magLimit = Mathf.Round((float)Math.Ceiling(magLimit / 3f) * 3f);
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			GUILayout.Label(this.Label + "ⁱ:", GUILayout.ExpandWidth(true));
+			GUILayout.FlexibleSpace();
+
+			GUILayout.Label(this.ValueUnitString(3, int.MinValue, (int)magnitude - digits), GUILayout.ExpandWidth(false));
+			GUILayout.EndHorizontal();
+
+			if (Event.current.type == EventType.mouseUp)
+			{
+				Rect lastRect = GUILayoutUtility.GetLastRect();
+				if (lastRect.Contains(Event.current.mousePosition))
 				{
-					float magLimit = Math.Max(magnitude, 6f);
-					magLimit = (float)Math.Ceiling(magLimit / 3f) * 3f;
 					if (Event.current.button == 0)
 					{
-						digits = (ushort)((digits + 3) % (int)magLimit);
+						digits = (digits + 3) % (int)magLimit;
 					}
 					else if (Event.current.button == 1)
 					{
-						digits = (ushort)((digits - 3) % (int)magLimit);
+						digits = (digits - 3) % (int)magLimit;
+						if (digits < 0)
+						{
+							digits = (int)magLimit - 3;
+						}
 					}
 				}
 			}
-			else
-			{
-				GUILayout.Label(this.ValueUnitString(digits), GUILayout.ExpandWidth(false));
-			}
-			GUILayout.EndHorizontal();
 
 			return digits;
 		}
-
 	}
 
 	public class VOID_DoubleValue : VOID_NumValue<double>, IVOID_NumericValue