curses: factor out chstr and window objects.

* ext/posix/curses.c: Factor out chstr and window objects,
methods and support functions from here...
* ext/posix/curses/chstr.c, ext/posix/curses/window.c: ...to
here.
* ext/posix/curses.c, ext/posix/curses/chstr.c,
ext/posix/curses/window.c: Add rudimentary LDocs to every API.
* build-aux/config.ld.in (file): Add ext/posix/curses/window.c,
ext/posix/curses/chstr.c and ext/posix/curses.c.
* ext/posix/curses/chstr.c: Add __call metamethod for creating
new objects.
* ext/posix/curses/chstr.c, ext/posix/curses/window.c: Add _type
field for compatibility with `std.object.type`.
* local.mk (EXTRA_ext_posix_posix_la_SOURCES): Add
ext/posix/curses/chstr.c and ext/posix/curses/window.c.
(posix_submodules): Add ext/posix/curses/chstr.la and
ext/posix/curses/window.la.
* build-aux/config.ld.in (custom_see_handler): Adjust to create
working URLs for curses 3X manual pages.

Signed-off-by: Gary V. Vaughan <gary@gnu.org>