| 202 | } |
| 203 | |
| 204 | af_err af_set_axes_titles(const af_window window, const char* const xtitle, |
| 205 | const char* const ytitle, const char* const ztitle, |
| 206 | const af_cell* const props) { |
| 207 | try { |
| 208 | if (window == 0) { AF_ERROR("Not a valid window", AF_ERR_INTERNAL); } |
| 209 | |
| 210 | ForgeManager& fgMngr = forgeManager(); |
| 211 | |
| 212 | fg_chart chart = nullptr; |
| 213 | |
| 214 | fg_chart_type ctype = (ztitle ? FG_CHART_3D : FG_CHART_2D); |
| 215 | |
| 216 | if (props->col > -1 && props->row > -1) { |
| 217 | chart = fgMngr.getChart(window, props->row, props->col, ctype); |
| 218 | } else { |
| 219 | chart = fgMngr.getChart(window, 0, 0, ctype); |
| 220 | } |
| 221 | |
| 222 | FG_CHECK(forgePlugin().fg_set_chart_axes_titles(chart, xtitle, ytitle, |
| 223 | ztitle)); |
| 224 | } |
| 225 | CATCHALL; |
| 226 | return AF_SUCCESS; |
| 227 | } |
| 228 | |
| 229 | af_err af_set_axes_label_format(const af_window window, |
| 230 | const char* const xformat, |