* @brief Pin the y-axis to a fixed [min, max] range. * * The y-axis counterpart to `plot_set_xlim`; see that function for the full * contract. The two axes are independent — you may pin one and leave the * other auto-scaling. * * @param plot Plot to configure. Must be non-NULL. * @param min Lower bound of the y-axis. * @param max Upper bound of the y-axis. Must be strictly greater than @
| 2123 | const PlotSeries* ser = &plot->series[s]; |
| 2124 | if ((ser->xData == NULL) != (first->xData == NULL)) { |
| 2125 | sharedX = false; |
| 2126 | } |
| 2127 | for (size_t r = 0; sharedX && ser->xData && r < ser->dataSize; ++r) { |
| 2128 | sharedX = r < first->dataSize && ser->xData[r] == first->xData[r]; |
| 2129 | } |
| 2130 | } |
| 2131 | |
| 2132 | bool ok = true; |
| 2133 | /* Header. */ |
| 2134 | if (sharedX) { |
| 2135 | ok &= fputs("x", f) >= 0; |
| 2136 | } |
| 2137 | for (size_t s = 0; s < plot->seriesCount; ++s) { |
| 2138 | char fallback[32]; |
nothing calls this directly
no outgoing calls
no test coverage detected