Fixed ChartWindow
This commit is contained in:
@ -231,6 +231,7 @@ namespace Elwig.Windows {
|
|||||||
private void InitPlot() {
|
private void InitPlot() {
|
||||||
OechslePricePlotScatter = OechslePricePlot.Plot.AddScatter(Graph.DataX, Graph.DataY);
|
OechslePricePlotScatter = OechslePricePlot.Plot.AddScatter(Graph.DataX, Graph.DataY);
|
||||||
|
|
||||||
|
OechslePricePlot.Configuration.DoubleClickBenchmark = false;
|
||||||
OechslePricePlotScatter.LineColor = Color.Blue;
|
OechslePricePlotScatter.LineColor = Color.Blue;
|
||||||
OechslePricePlotScatter.MarkerColor = Color.Blue;
|
OechslePricePlotScatter.MarkerColor = Color.Blue;
|
||||||
OechslePricePlotScatter.MarkerSize = 9;
|
OechslePricePlotScatter.MarkerSize = 9;
|
||||||
@ -398,7 +399,7 @@ namespace Elwig.Windows {
|
|||||||
|
|
||||||
PriceInput.Text = Graph.DataY[PrimaryMarkedPointIndex].ToString();
|
PriceInput.Text = Graph.DataY[PrimaryMarkedPointIndex].ToString();
|
||||||
|
|
||||||
EnableActionButtons();
|
if (IsEditing || IsCreating) EnableActionButtons();
|
||||||
OechslePricePlot.Render();
|
OechslePricePlot.Render();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -430,6 +431,8 @@ namespace Elwig.Windows {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
FlattenGraph(0, PrimaryMarkedPointIndex, Graph.DataY[PrimaryMarkedPointIndex]);
|
FlattenGraph(0, PrimaryMarkedPointIndex, Graph.DataY[PrimaryMarkedPointIndex]);
|
||||||
|
SaveButton.IsEnabled = true;
|
||||||
|
ResetButton.IsEnabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void RightFlatButton_Click(object sender, RoutedEventArgs evt) {
|
private void RightFlatButton_Click(object sender, RoutedEventArgs evt) {
|
||||||
@ -437,6 +440,8 @@ namespace Elwig.Windows {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
FlattenGraph(PrimaryMarkedPointIndex, Graph.DataY.Length - 1, Graph.DataY[PrimaryMarkedPointIndex]);
|
FlattenGraph(PrimaryMarkedPointIndex, Graph.DataY.Length - 1, Graph.DataY[PrimaryMarkedPointIndex]);
|
||||||
|
SaveButton.IsEnabled = true;
|
||||||
|
ResetButton.IsEnabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void InterpolateButton_Click(object sender, RoutedEventArgs evt) {
|
private void InterpolateButton_Click(object sender, RoutedEventArgs evt) {
|
||||||
@ -451,6 +456,8 @@ namespace Elwig.Windows {
|
|||||||
for (int i = lowIndex; i < highIndex - 1; i++) {
|
for (int i = lowIndex; i < highIndex - 1; i++) {
|
||||||
Graph.DataY[i + 1] = Math.Round(Graph.DataY[i] + step, 4); // TODO richtig runden
|
Graph.DataY[i + 1] = Math.Round(Graph.DataY[i] + step, 4); // TODO richtig runden
|
||||||
}
|
}
|
||||||
|
SaveButton.IsEnabled = true;
|
||||||
|
ResetButton.IsEnabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LinearIncreaseButton_Click(object sender, RoutedEventArgs e) {
|
private void LinearIncreaseButton_Click(object sender, RoutedEventArgs e) {
|
||||||
@ -462,6 +469,8 @@ namespace Elwig.Windows {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
LinearIncreaseGraph(PrimaryMarkedPointIndex, Graph.DataY.Length - 1, priceIncrease.Value);
|
LinearIncreaseGraph(PrimaryMarkedPointIndex, Graph.DataY.Length - 1, priceIncrease.Value);
|
||||||
|
SaveButton.IsEnabled = true;
|
||||||
|
ResetButton.IsEnabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OechslePricePlot_MouseDown(object sender, MouseEventArgs e) {
|
private void OechslePricePlot_MouseDown(object sender, MouseEventArgs e) {
|
||||||
|
Reference in New Issue
Block a user