[3.13] gh-152502: Detect optional curses functions with configure probes (GH-152504) (GH-152589) (GH-152602)
set_escdelay(), set_tabsize() and the ESCDELAY and TABSIZE variables were
gated only by the ncurses-specific NCURSES_EXT_FUNCS macro, which excluded
them when building against other curses implementations such as NetBSD curses
even when they provided them. Detect each with a configure capability probe
and gate on HAVE_CURSES_*.
(cherry picked from commit
0635e55b47e306aa6cc0610105775849b0699e2c)
(cherry picked from commit
2a4ffa6f2128308ba5ba81a7c8912fb781a271e0)
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>