mirror of
https://git.gfz-potsdam.de/naaice/iphreeqc.git
synced 2025-12-16 16:44:49 +01:00
Merge commit 'ca6b882bcab9708f90c8761e0d4a4d572c57fce7'
This commit is contained in:
commit
0bd8217516
@ -970,11 +970,22 @@ namespace zdg_ui2 {
|
|||||||
{
|
{
|
||||||
double max = -1e99;
|
double max = -1e99;
|
||||||
for (int i = 0; i < zg1->GraphPane->CurveList->Count; i++)
|
for (int i = 0; i < zg1->GraphPane->CurveList->Count; i++)
|
||||||
|
{
|
||||||
|
if (Curves[i]->Get_x().size() > 0)
|
||||||
{
|
{
|
||||||
if (Curves[i]->Get_x()[Curves[i]->Get_x().size() - 1] > max)
|
if (Curves[i]->Get_x()[Curves[i]->Get_x().size() - 1] > max)
|
||||||
max = Curves[i]->Get_x()[Curves[i]->Get_x().size() - 1];
|
max = Curves[i]->Get_x()[Curves[i]->Get_x().size() - 1];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
if (max > 0)
|
||||||
|
{
|
||||||
max += pow(10.0, log10(max / 3));
|
max += pow(10.0, log10(max / 3));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
zg1->GraphPane->XAxis->Scale->Min = 0;
|
||||||
|
max = zg1->GraphPane->XAxis->Scale->Min + 1.0;
|
||||||
|
}
|
||||||
zg1->GraphPane->XAxis->Scale->Max = max;
|
zg1->GraphPane->XAxis->Scale->Max = max;
|
||||||
}
|
}
|
||||||
if ((fabs(chart->Get_axis_scale_y()[1] - NA) < 1e-3) && zg1->GraphPane->YAxis->Type == AxisType::Log)
|
if ((fabs(chart->Get_axis_scale_y()[1] - NA) < 1e-3) && zg1->GraphPane->YAxis->Type == AxisType::Log)
|
||||||
@ -984,10 +995,21 @@ namespace zdg_ui2 {
|
|||||||
{
|
{
|
||||||
curve = (LineItem^)zg1->GraphPane->CurveList[i];
|
curve = (LineItem^)zg1->GraphPane->CurveList[i];
|
||||||
if (curve->IsY2Axis) continue;
|
if (curve->IsY2Axis) continue;
|
||||||
|
if (Curves[i]->Get_y().size() > 0)
|
||||||
|
{
|
||||||
if (Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1] > max)
|
if (Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1] > max)
|
||||||
max = Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1];
|
max = Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
if (max > 0)
|
||||||
|
{
|
||||||
max += pow(10.0, log10(max / 3));
|
max += pow(10.0, log10(max / 3));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
zg1->GraphPane->YAxis->Scale->Min = 0;
|
||||||
|
max = zg1->GraphPane->YAxis->Scale->Min + 1.0;
|
||||||
|
}
|
||||||
zg1->GraphPane->YAxis->Scale->Max = max;
|
zg1->GraphPane->YAxis->Scale->Max = max;
|
||||||
}
|
}
|
||||||
if ((fabs(chart->Get_axis_scale_y2()[1] - NA) < 1e-3) && zg1->GraphPane->Y2Axis->Type == AxisType::Log)
|
if ((fabs(chart->Get_axis_scale_y2()[1] - NA) < 1e-3) && zg1->GraphPane->Y2Axis->Type == AxisType::Log)
|
||||||
@ -997,10 +1019,21 @@ namespace zdg_ui2 {
|
|||||||
{
|
{
|
||||||
curve = (LineItem^)zg1->GraphPane->CurveList[i];
|
curve = (LineItem^)zg1->GraphPane->CurveList[i];
|
||||||
if (!curve->IsY2Axis) continue;
|
if (!curve->IsY2Axis) continue;
|
||||||
|
if (Curves[i]->Get_y().size() > 0)
|
||||||
|
{
|
||||||
if (Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1] > max)
|
if (Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1] > max)
|
||||||
max = Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1];
|
max = Curves[i]->Get_y()[Curves[i]->Get_y().size() - 1];
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
if (max > 0.0)
|
||||||
|
{
|
||||||
max += pow(10.0, log10(max / 3));
|
max += pow(10.0, log10(max / 3));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
zg1->GraphPane->Y2Axis->Scale->Min = 0;
|
||||||
|
max = zg1->GraphPane->Y2Axis->Scale->Min + 1.0;
|
||||||
|
}
|
||||||
zg1->GraphPane->Y2Axis->Scale->Max = max;
|
zg1->GraphPane->Y2Axis->Scale->Max = max;
|
||||||
}
|
}
|
||||||
zg1->AxisChange();
|
zg1->AxisChange();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user