mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[python] Matplotlib: init store range depending on 'auto' parameter
This commit is contained in:
@@ -74,6 +74,7 @@ mp_obj_t modpyplot_axis(mp_obj_t arg) {
|
||||
sPlotStore->setXMax(mp_obj_get_float(items[1]));
|
||||
sPlotStore->setYMin(mp_obj_get_float(items[2]));
|
||||
sPlotStore->setYMax(mp_obj_get_float(items[3]));
|
||||
sPlotStore->setAxesAuto(false);
|
||||
}
|
||||
|
||||
// Build the return value
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
namespace Matplotlib {
|
||||
|
||||
void PlotController::viewWillAppear() {
|
||||
m_store->initRange();
|
||||
curveView()->reload();
|
||||
}
|
||||
|
||||
|
||||
@@ -121,6 +121,7 @@ public:
|
||||
|
||||
void setAxesRequested(bool b) { m_axesRequested = b; }
|
||||
bool axesRequested() const { return m_axesRequested; }
|
||||
void setAxesAuto(bool b) { m_axesAuto = b; }
|
||||
void initRange();
|
||||
|
||||
void setGridRequested(bool b) { m_gridRequested = b; }
|
||||
|
||||
Reference in New Issue
Block a user