[C++] API sync

Added:
 * NotCurses: `stats_alloc` (`notcurses_stats_alloc`)
 * Plane: `set_resizecb` (`ncplane_set_resizecb`)
This commit is contained in:
Marek Habersack 2020-11-24 00:09:30 +01:00 committed by Nick Black
parent a2cc5f096a
commit c8eb3875ff
2 changed files with 10 additions and 0 deletions

View File

@ -283,6 +283,11 @@ namespace ncpp
return error_guard (notcurses_align (availcols, align, cols), -INT_MAX);
}
ncstats* stats_alloc () const noexcept
{
return notcurses_stats_alloc (nc);
}
static bool ucs32_to_utf8 (const char32_t *ucs32, unsigned ucs32count, unsigned char *resultbuf, size_t buflen) NOEXCEPT_MAYBE
{
return error_guard (notcurses_ucs32_to_utf8 (ucs32, ucs32count, resultbuf, buflen), -1);

View File

@ -1146,6 +1146,11 @@ namespace ncpp
return plane != nullptr;
}
void set_resizecb (int(*resizecb)(struct ncplane*)) const noexcept
{
ncplane_set_resizecb (plane, resizecb);
}
protected:
explicit Plane (ncplane *_plane, bool _is_stdplane)
: Root (nullptr),