X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/blobdiff_plain/60aa1c7413ef8ba2c4889628170f00bf180039f0..cf212d59e2363e5c44ed41b39fbbb3ec29a5e261:/devel.but diff --git a/devel.but b/devel.but index 1df57cf..ea23d52 100644 --- a/devel.but +++ b/devel.but @@ -2671,6 +2671,11 @@ Calling this function is very likely to result in calls back to the front end's drawing API and/or \cw{activate_timer()} (\k{frontend-activate-timer}). +The return value from \cw{midend_process_key()} is non-zero, unless +the effect of the keypress was to request termination of the +program. A front end should shut down the puzzle in response to a +zero return. + \H{midend-colours} \cw{midend_colours()} \c float *midend_colours(midend *me, int *ncolours); @@ -2728,6 +2733,16 @@ are owned by the mid-end structure: the front end should not ever free them directly, because they will be freed automatically during \cw{midend_free()}. +\H{midend-which-preset} \cw{midend_which_preset()} + +\c int midend_which_preset(midend *me); + +Returns the numeric index of the preset game parameter structure +which matches the current game parameters, or a negative number if +no preset matches. Front ends could use this to maintain a tick +beside one of the items in the menu (or tick the \q{Custom} option +if the return value is less than zero). + \H{midend-wants-statusbar} \cw{midend_wants_statusbar()} \c int midend_wants_statusbar(midend *me);