Index: branches/2971_named_intervals/HeuristicLab.Problems.DataAnalysis.Views/3.4/IntervalConstraintView.cs
===================================================================
--- branches/2971_named_intervals/HeuristicLab.Problems.DataAnalysis.Views/3.4/IntervalConstraintView.cs	(revision 16830)
+++ branches/2971_named_intervals/HeuristicLab.Problems.DataAnalysis.Views/3.4/IntervalConstraintView.cs	(revision 16862)
@@ -29,5 +29,5 @@
   [View("Interval Constraint Detail View")]
   [Content(typeof(IntervalConstraint), true)]
-  public partial class IntervalConstraintView : ItemView {
+  public sealed partial class IntervalConstraintView : ItemView {
 
     public new IntervalConstraint Content {
@@ -41,6 +41,4 @@
       expressionInput.ReadOnly = true;
       definitionInput.ReadOnly = true;
-      derivationInput.Enabled = false;
-      derivationInput.Checked = false;
       numberderivationInput.DataSource = items;
     }
@@ -57,11 +55,16 @@
 
     protected override void DeregisterContentEvents() {
+      Content.Changed -= new EventHandler(Content_Changed);
       base.DeregisterContentEvents();
-      Content.Changed -= new EventHandler(Content_Changed);
     }
 
     protected override void SetEnabledStateOfControls() {
       base.SetEnabledStateOfControls();
-      lowerboundInput.Enabled = Content != null && !Locked;
+      lowerboundInput.Enabled = Content != null && !Locked && !ReadOnly;
+      upperboundInput.Enabled = Content != null && !Locked && !ReadOnly;
+      expressionInput.Enabled = Content != null && !Locked && !ReadOnly;
+      definitionInput.Enabled = Content != null && !Locked && !ReadOnly;
+      definitionInput.ReadOnly = true;
+      expressionInput.ReadOnly = true;
     }
 
@@ -70,5 +73,5 @@
     #region helpers
 
-    private double ParseDoubleValue(string input, Control control) {
+    private static double ParseDoubleValue(string input, Control control, ErrorProvider errorProvider) {
       input = input.ToLower();
       switch (input) {
@@ -81,5 +84,5 @@
           return double.NegativeInfinity;
         default: {
-          if (double.TryParse(input, NumberStyles.Any, CultureInfo.InvariantCulture, out var value))
+          if (double.TryParse(input, out var value))
             return value;
           else {
@@ -98,23 +101,25 @@
         incllowerboundInput.Checked = true;
         inclupperboundInput.Checked = true;
+        return;
+      }
+
+      expressionInput.Text = Content.Expression;
+      definitionInput.Text = Content.Definition;
+      lowerboundInput.Text = Content.Interval.LowerBound.ToString();
+      upperboundInput.Text = Content.Interval.UpperBound.ToString();
+      incllowerboundInput.Checked = Content.InclusiveLowerBound;
+      inclupperboundInput.Checked = Content.InclusiveUpperBound;
+      variableInput.Text = Content.Variable;
+      if (!Content.IsDerivation) {
+        numberderivationInput.Visible = false;
+        numberderivationLabel.Visible = false;
       } else {
-        expressionInput.Text = Content.Expression;
-        definitionInput.Text = Content.Definition;
-        lowerboundInput.Text = Content.Interval.LowerBound.ToString(CultureInfo.InvariantCulture);
-        upperboundInput.Text = Content.Interval.UpperBound.ToString(CultureInfo.InvariantCulture);
-        incllowerboundInput.Checked = Content.InclusiveLowerBound;
-        inclupperboundInput.Checked = Content.InclusiveUpperBound;
-        derivationInput.Checked = Content.IsDerivation;
-        variableInput.Text = Content.Variable;
-        if (!Content.IsDerivation) {
-          numberderivationInput.Enabled = false;
-        } else {
-          numberderivationInput.Enabled = true;
-          numberderivationInput.SelectedItem = Content.NumberOfDerivation;
-        }
-
-        ischeckedCheckBox.Checked = Content.Enabled;
-      }
-      SetEnabledStateOfControls();
+        numberderivationLabel.Visible = true;
+        numberderivationInput.Visible = true;
+        numberderivationInput.Enabled = true;
+        numberderivationInput.SelectedItem = Content.NumberOfDerivation;
+      }
+
+      ischeckedCheckBox.Checked = Content.Enabled;
     }
 
@@ -136,6 +141,6 @@
           constraint.Interval.UpperBound,
           (constraint.InclusiveUpperBound) ? "]" : "[",
-          PrintNumberOfDerivation(constraint.numberOfDerivation),
-          PrintNumberOfDerivation(constraint.numberOfDerivation));
+          GetDerivationString(constraint.numberOfDerivation),
+          GetDerivationString(constraint.numberOfDerivation));
       }
 
@@ -143,5 +148,5 @@
     }
 
-    private static string PrintNumberOfDerivation(int derivation) {
+    private static string GetDerivationString(int derivation) {
       switch (derivation) {
         case 1:
@@ -160,5 +165,5 @@
     #region control event handlers
     private void lowerboundInput_Validating(object sender, CancelEventArgs e) {
-      var value = ParseDoubleValue(lowerboundInput.Text, lowerboundInput);
+      var value = ParseDoubleValue(lowerboundInput.Text, lowerboundInput, this.errorProvider);
       if (double.IsNaN(value)) {
         errorProvider.SetError(lowerboundInput, "Invalid Input: Lowerbound must be a double value!");
@@ -178,5 +183,5 @@
 
     private void lowerboundInput_Validated(object sender, EventArgs e) {
-      var value = ParseDoubleValue(lowerboundInput.Text, lowerboundInput);
+      var value = ParseDoubleValue(lowerboundInput.Text, lowerboundInput, this.errorProvider);
       if (!double.IsNaN(value)) {
         Content.Interval = new Interval(value, Content.Interval.UpperBound);
@@ -188,5 +193,5 @@
 
     private void upperboundInput_Validating(object sender, CancelEventArgs e) {
-      var value = ParseDoubleValue(upperboundInput.Text, upperboundInput);
+      var value = ParseDoubleValue(upperboundInput.Text, upperboundInput, this.errorProvider);
       if (double.IsNaN(value)) {
         errorProvider.SetError(upperboundInput, "Invalid Input: Upperbound must be a double value!");
@@ -206,5 +211,5 @@
 
     private void upperboundInput_Validated(object sender, EventArgs e) {
-      var value = ParseDoubleValue(upperboundInput.Text, upperboundInput);
+      var value = ParseDoubleValue(upperboundInput.Text, upperboundInput, this.errorProvider);
       if (!double.IsNaN(value)) {
         Content.Interval = new Interval(Content.Interval.LowerBound, value);
@@ -216,28 +221,19 @@
 
     private void incllowerboundInput_CheckedChanged(object sender, EventArgs e) {
-      if (Content.InclusiveLowerBound != incllowerboundInput.Checked) {
         Content.InclusiveLowerBound = incllowerboundInput.Checked;
         var exp = UpdateExpression(Content);
         Content.Name = exp;
         Content.Expression = exp;
-      }
-      
-      
     }
 
     private void inclupperboundInput_CheckedChanged(object sender, EventArgs e) {
-      if (Content.InclusiveUpperBound != inclupperboundInput.Checked) { 
         Content.InclusiveUpperBound = inclupperboundInput.Checked;
         var exp = UpdateExpression(Content);
         Content.Name = exp;
         Content.Expression = exp;
-      }
     }
 
     private void ischeckedCheckBox_CheckedChanged(object sender, EventArgs e) {
-      if (Content.Enabled != ischeckedCheckBox.Checked) {
         Content.Enabled = ischeckedCheckBox.Checked;
-        //UpdateControls();
-      }
     }
 
@@ -262,8 +258,5 @@
       UpdateControls();
     }
-
-
     #endregion
-
   }
 }
