[ncvisual_pixelgeom] document that results are invalidated by terminal resize #2141

This commit is contained in:
nick black 2021-10-07 00:53:12 -04:00
parent 8ec6e22b7c
commit 6d3c64a5c1
No known key found for this signature in database
GPG Key ID: 5F43400C21CBFACC
3 changed files with 5 additions and 1 deletions

View File

@ -3272,6 +3272,7 @@ it was built up:
// cols = (x / scalex) + !!(x % scalex) or (x + scalex - 1) / scalex
// Returns non-zero for an invalid 'vopts'. The blitter that will be used
// is returned in '*blitter'.
// These results are invalidated upon a terminal resize.
int ncvisual_blitter_geom(const struct notcurses* nc, const struct ncvisual* n,
const struct ncvisual_options* vopts, int* y, int* x,
int* scaley, int* scalex, ncblitter_e* blitter);

View File

@ -347,6 +347,8 @@ When using non-interpolative blitting together with scaling, unless your goal
includes minimizing the total area required, lower-resolution blitters will
generally look just as good as higher resolution blitters, and be faster.
The results of **ncvisual_blitter_geom** are invalidated by a terminal resize.
# BUGS
Functions which describe rendered state such as **ncplane_at_yx** and

View File

@ -1193,7 +1193,8 @@ ncplane_dim_x(const struct ncplane* n){
// Retrieve pixel geometry for the display region ('pxy', 'pxx'), each cell
// ('celldimy', 'celldimx'), and the maximum displayable bitmap ('maxbmapy',
// 'maxbmapx'). If bitmaps are not supported, 'maxbmapy' and 'maxbmapx' will
// be 0. Any of the geometry arguments may be NULL.
// be 0. Any of the geometry arguments may be NULL. These results are
// invalidated by a terminal resize.
API void ncplane_pixelgeom(const struct ncplane* n, int* RESTRICT pxy, int* RESTRICT pxx,
int* RESTRICT celldimy, int* RESTRICT celldimx,
int* RESTRICT maxbmapy, int* RESTRICT maxbmapx)