mirror of
https://github.com/dankamongmen/notcurses
synced 2025-03-09 09:09:03 -04:00
[docs] rename plane/visual sections to regions
This commit is contained in:
parent
a4d7bd5670
commit
b1f636a2d9
12
USAGE.md
12
USAGE.md
@ -961,7 +961,7 @@ It is an error to invoke these functions on the standard plane.
|
||||
```c
|
||||
// Resize the specified ncplane. The four parameters 'keepy', 'keepx',
|
||||
// 'keepleny', and 'keeplenx' define a subset of the ncplane to keep,
|
||||
// unchanged. This may be a section of size 0, though none of these four
|
||||
// unchanged. This may be a region of size 0, though none of these four
|
||||
// parameters may be negative. 'keepx' and 'keepy' are relative to the ncplane.
|
||||
// They must specify a coordinate within the ncplane's totality. 'yoff' and
|
||||
// 'xoff' are relative to 'keepy' and 'keepx', and place the upper-left corner
|
||||
@ -3321,8 +3321,8 @@ typedef struct ncvgeom {
|
||||
unsigned rpixy, rpixx; // rendered pixel geometry (per visual_options)
|
||||
unsigned rcelly, rcellx; // rendered cell geometry (per visual_options)
|
||||
unsigned scaley, scalex; // pixels per filled cell (scale == c for bitmaps)
|
||||
unsigned begy, begx; // upper-left corner of used section
|
||||
unsigned leny, lenx; // geometry of used section
|
||||
unsigned begy, begx; // upper-left corner of used region
|
||||
unsigned leny, lenx; // geometry of used region
|
||||
unsigned maxpixely, maxpixelx; // only defined for NCBLIT_PIXEL
|
||||
ncblitter_e blitter; // blitter that will be used
|
||||
} ncvgeom;
|
||||
@ -3439,12 +3439,12 @@ struct ncvisual_options {
|
||||
// value if NCVISUAL_OPTION_HORALIGNED is provided. y is an ncalign_e
|
||||
// value if NCVISUAL_OPTION_VERALIGNED is provided.
|
||||
int y, x;
|
||||
// the section of the visual that ought be rendered. for the entire visual,
|
||||
// the region of the visual that ought be rendered. for the entire visual,
|
||||
// pass an origin of 0, 0 and a size of 0, 0 (or the true height and width).
|
||||
// these numbers are all in terms of ncvisual pixels. negative values are
|
||||
// prohibited.
|
||||
int begy, begx; // origin of rendered section
|
||||
int leny, lenx; // size of rendered section
|
||||
int begy, begx; // origin of rendered region
|
||||
int leny, lenx; // size of rendered region
|
||||
// use NCBLIT_DEFAULT if you don't care, an appropriate blitter will be
|
||||
// chosen for your terminal, given your scaling. NCBLIT_PIXEL is never
|
||||
// chosen for NCBLIT_DEFAULT.
|
||||
|
@ -42,8 +42,8 @@ struct ncvisual_options {
|
||||
struct ncplane* n;
|
||||
ncscale_e scaling;
|
||||
int y, x;
|
||||
int begy, begx; // origin of rendered section
|
||||
int leny, lenx; // size of rendered section
|
||||
int begy, begx; // origin of rendered region
|
||||
int leny, lenx; // size of rendered region
|
||||
ncblitter_e blitter; // glyph set to use
|
||||
uint64_t flags; // bitmask over NCVISUAL_OPTION_*
|
||||
uint32_t transcolor; // use this color for ADDALPHA
|
||||
@ -58,8 +58,8 @@ typedef struct ncvgeom {
|
||||
unsigned rpixy, rpixx; // rendered pixel geometry (per visual_options)
|
||||
unsigned rcelly, rcellx; // rendered cell geometry (per visual_options)
|
||||
unsigned scaley, scalex; // pixels per filled cell (scale == c for bitmaps)
|
||||
unsigned begy, begx; // upper-left corner of used section
|
||||
unsigned leny, lenx; // geometry of used section
|
||||
unsigned begy, begx; // upper-left corner of used region
|
||||
unsigned leny, lenx; // geometry of used region
|
||||
unsigned maxpixely, maxpixelx; // only defined for NCBLIT_PIXEL
|
||||
ncblitter_e blitter;i // blitter that will be used
|
||||
} ncvgeom;
|
||||
@ -176,7 +176,7 @@ of its **struct ncvisual_options**. If ***n*** is not **NULL**, it specifies the
|
||||
plane on which to render, and ***y***/***x*** specify a location within that plane.
|
||||
Otherwise, a new plane will be created, and placed at ***y***/***x*** relative to
|
||||
the rendering area. ***begy***/***begx*** specify the upper left corner of a
|
||||
subsection of the **ncvisual** to render, while ***leny***/***lenx*** specify the
|
||||
subregion of the **ncvisual** to render, while ***leny***/***lenx*** specify the
|
||||
geometry of same. ***flags*** is a bitfield over:
|
||||
|
||||
* **NCVISUAL_OPTION_NODEGRADE** If the specified blitter is not available, fail rather than degrading.
|
||||
@ -211,7 +211,7 @@ through the bottom right corner of the image.
|
||||
|
||||
The ***n*** field specifies the plane to use. If this is **NULL**, a new plane
|
||||
will be created, having the precise geometry necessary to blit the specified
|
||||
section of the image. This might be larger (or smaller) than the visual area.
|
||||
region of the image. This might be larger (or smaller) than the visual area.
|
||||
|
||||
***y*** and ***x*** have different meanings depending on whether or not
|
||||
***n*** is **NULL**. If not (drawing onto a preexisting plane), they specify
|
||||
|
@ -1615,7 +1615,7 @@ API void notcurses_stats_reset(struct notcurses* nc, ncstats* stats)
|
||||
|
||||
// Resize the specified ncplane. The four parameters 'keepy', 'keepx',
|
||||
// 'keepleny', and 'keeplenx' define a subset of the ncplane to keep,
|
||||
// unchanged. This may be a section of size 0, though none of these four
|
||||
// unchanged. This may be a region of size 0, though none of these four
|
||||
// parameters may be negative. 'keepx' and 'keepy' are relative to the ncplane.
|
||||
// They must specify a coordinate within the ncplane's totality. 'yoff' and
|
||||
// 'xoff' are relative to 'keepy' and 'keepx', and place the upper-left corner
|
||||
@ -3065,12 +3065,12 @@ struct ncvisual_options {
|
||||
// value if NCVISUAL_OPTION_HORALIGNED is provided. y is an ncalign_e if
|
||||
// NCVISUAL_OPTION_VERALIGNED is provided.
|
||||
int y, x;
|
||||
// the section of the visual that ought be rendered. for the entire visual,
|
||||
// the region of the visual that ought be rendered. for the entire visual,
|
||||
// pass an origin of 0, 0 and a size of 0, 0 (or the true height and width).
|
||||
// these numbers are all in terms of ncvisual pixels. negative values are
|
||||
// prohibited.
|
||||
unsigned begy, begx; // origin of rendered section in pixels
|
||||
unsigned leny, lenx; // size of rendered section in pixels
|
||||
unsigned begy, begx; // origin of rendered region in pixels
|
||||
unsigned leny, lenx; // size of rendered region in pixels
|
||||
// use NCBLIT_DEFAULT if you don't care, an appropriate blitter will be
|
||||
// chosen for your terminal, given your scaling. NCBLIT_PIXEL is never
|
||||
// chosen for NCBLIT_DEFAULT.
|
||||
@ -3107,8 +3107,8 @@ typedef struct ncvgeom {
|
||||
unsigned rpixy, rpixx; // rendered pixel geometry (per visual_options)
|
||||
unsigned rcelly, rcellx; // rendered cell geometry (per visual_options)
|
||||
unsigned scaley, scalex; // pixels per filled cell (scale == c for bitmaps)
|
||||
unsigned begy, begx; // upper-left corner of used section
|
||||
unsigned leny, lenx; // geometry of used section
|
||||
unsigned begy, begx; // upper-left corner of used region
|
||||
unsigned leny, lenx; // geometry of used region
|
||||
unsigned maxpixely, maxpixelx; // only defined for NCBLIT_PIXEL
|
||||
ncblitter_e blitter; // blitter that will be used
|
||||
} ncvgeom;
|
||||
|
@ -28,7 +28,7 @@ zoom_map(struct notcurses* nc, const char* map, int* ret){
|
||||
struct ncplane* n = notcurses_stdplane(nc);
|
||||
*ret = -1;
|
||||
// determine size that will be represented on screen at once, and how
|
||||
// large that section has been rendered in the outzoomed map. take the map
|
||||
// large that region has been rendered in the outzoomed map. take the map
|
||||
// and begin opening it on larger and larger planes that fit on the screen
|
||||
// less and less. eventually, reach our natural NCSCALE_NONE size and begin
|
||||
// scrolling through the map, whooooooooosh.
|
||||
|
Loading…
x
Reference in New Issue
Block a user