1
0
Fork 0
mirror of https://github.com/gwm17/implot.git synced 2024-11-13 22:48:50 -05:00

fix axis constraints

This commit is contained in:
epezent 2020-09-06 21:04:36 -05:00
parent d14dd621e4
commit 2b46c3eac3

View File

@ -1145,6 +1145,12 @@ bool BeginPlot(const char* title, const char* x_label, const char* y_label, cons
gp.Scales[i] = ImPlotScale_LogLog; gp.Scales[i] = ImPlotScale_LogLog;
} }
// constraints
plot.XAxis.Constrain();
for (int i = 0; i < IMPLOT_Y_AXES; ++i)
plot.YAxis[i].Constrain();
// AXIS COLORS ----------------------------------------------------------------- // AXIS COLORS -----------------------------------------------------------------
UpdateAxisColors(ImPlotCol_XAxis, &gp.Col_X); UpdateAxisColors(ImPlotCol_XAxis, &gp.Col_X);