1
0
Fork 0
mirror of https://github.com/gwm17/Specter.git synced 2024-11-22 18:28:52 -05:00

Small bugfix to the centering of text in the integral region

This commit is contained in:
Gordon McCann 2022-02-15 21:18:03 -05:00
parent 5b1dbb02f2
commit e9700170e7

View File

@ -10,9 +10,9 @@ namespace Navigator {
stream << "Region: " << name << "\n" << "Integral: " << results.integral << "\n"; stream << "Region: " << name << "\n" << "Integral: " << results.integral << "\n";
if (results.integral == 0.0) if (results.integral == 0.0)
return stream.str(); return stream.str();
stream << "Centroid X: " << results.cent_x << " Std. Dev. X: " << results.sigma_x << " FWHM X: " << 2.355 * results.sigma_x << "\n"; stream << "Centroid X: " << results.cent_x << "\nStd. Dev. X: " << results.sigma_x << "\nFWHM X: " << 2.355 * results.sigma_x << "\n";
if(is2D) if(is2D)
stream << "Centroid Y: " << results.cent_y << " Std. Dev. Y: " << results.sigma_y << " FWHM Y: " << 2.355 * results.sigma_y << "\n"; stream << "Centroid Y: " << results.cent_y << "\nStd. Dev. Y: " << results.sigma_y << "\nFWHM Y: " << 2.355 * results.sigma_y << "\n";
return stream.str(); return stream.str();
} }
@ -92,7 +92,7 @@ namespace Navigator {
} }
for (size_t i = 0; i < m_integralRegions.size(); i++) for (size_t i = 0; i < m_integralRegions.size(); i++)
{ {
auto& region = m_integralRegions[i]; auto region = m_integralRegions[i];
if (m_zoomedGram.name == region.histogram_name) if (m_zoomedGram.name == region.histogram_name)
{ {
ImPlot::DragRect(int(i), &region.region.X.Min, &region.region.Y.Min, &region.region.X.Max, &region.region.Y.Max, ImVec4(1, 0, 1, 1)); ImPlot::DragRect(int(i), &region.region.X.Min, &region.region.Y.Min, &region.region.X.Max, &region.region.Y.Max, ImVec4(1, 0, 1, 1));