Remove the pre-rendered model.png, a generated output. Add a
dot target to CMake, predicated on USE_DOXYGEN (since we have
REQUIRED dot in our Doxygen spec). Generate the png in the
output path. Rename stacks to piles in model.dot.
Partially reverts: c5c9432ac0
Context: https://github.com/dankamongmen/notcurses/pull/1146
The above commit implemented the much more convenient way of finding and
using a package from CMake, however it broke compatibility with the way
id had been before, which defined various `Notcurses_*` variables.
Revert the `Notcurses` component to the old way and add support for
`Notcurses++` in the same fashion.
Perhaps one day we should think of implementing `find_package` support
by way of a module, which should make it possible to have the cake and
eat the cake. One day.
CMake:
Simplify cmake target+version config generation and make it actually
work. With the changes it is now possible to detect and use
`Notcurses` in the following way:
find_package(Notcurses REQUIRED)
...
target_link_libraries(myapp PRIVATE notcurses::notcurses)
Also, added the same CMake configuration for `Notcurses++`, to be used
in the following way:
find_package(Notcurses REQUIRED
find_package(Notcurses++ REQUIRED)
...
target_link_libraries(myapp PRIVATE notcurses++::notcurses++)
Docs:
`notcurses_cell(3)`: `cell_styles_{on,off} -> cell_{on,off}_styles`
and `cell_load_simple` -> `cell_load_char`
C++ API:
* Plane: added constructors taking `ncplane_options const&` instead of
the multitude of individual parameters
* Plane: drop `struct` when `ncplane_options` is used.
* Plane: added `strdup` (`cell_strdup`)
* Plane: added `extract` (`cell_extract`)
New reel layout algorithm based on trimming and sifting. Fixes the original issue of #818, though I'm not marking that bug fixed until I've resolved the little issues remaining with this one.
Back off CMake version dependency, see if we can get by with 3.11.4 for EPEL8 #851
Simplify tablet drawing tremendously by separating tablet border and data planes. Callbacks no longer need worry about the borders; they can simply fill the plane they're handed. #833
Improve notcurses_debug() a bit
Add ncplane_new_named() and friends to expose plane naming to the user.
Add internal ncplane_genocide() to kill a plane and all its bound descendents
New industrial-strength ncreel unit testing
notcurses-ncreel now accepts -ln for log level n
Add ncplane_parent() and ncplane_parent_const()
If we're fed a word that in and of itself is wider than
the text layout area, and it is not the first word on the
row on which it starts, go ahead and start it there, as
opposed to breaking the line. #720
Also, remove sgr from test suite, as it's not a notcurses
application.
Add back the USE_DOCTEST CMake option, but make it conditional
upon BUILD_TESTING. If BUILD_TESTING is provided without
USE_DOCTEST, we build and run the PoC tests, just not
notcurses-tester. If neither is defined, no tests are available
(the PoC binaries are still built). If both are defined, build
the PoCs plus notcurses-tester, and run them all in make test.
* Some things go to the FILE* we're provided. Some can only go to a controlling terminal. Check to see if the FILE we're given is a TTY. If not, open up /dev/tty #752.
* term_emit(): fflush() can return EAGAIN. Loop on it to eliminate a rare error on shutdown that particularly affected unit tests (where we start and shut down Notcurses many times in a row).
* sgr poc: check return value of setlocale()
* drone: run all unit tests
* CMake: add some tests using PoCs
* ncneofetch: print even small palettes
Fixes: https://github.com/dankamongmen/notcurses/issues/722
`-Wpedantic` is dropped because C code uses designated structure
initializers which are available in C++20 onward (and we use C++17
ATM). Once we switch to C++20 we should re-enable the flag.
`-fno-exceptions` is dropped because we do have exceptions, so...