Commit Graph

149 Commits

Author SHA1 Message Date
nick black
b3569b6aef
Initialize Readline on demand
Eliminate NCDIRECT_OPTION_NO_READLINE (it was only introduced in
Notcurses 2.1.6). Add a new function, ncdirect_readline(). Upon
first call to this function, initialize libreadline. Destroy
libreadline in ncdirect_stop() iff we initialized it. Add
hilodirect guessing game PoC from #1325. Rename
notcurses_directmode.3 to notcurses_direct.3. Closes #1326.
2021-02-03 00:18:10 -05:00
nick black
43dd0440f7
add raster timing stats #1324 2021-02-02 21:59:29 -05:00
nick black
cb58f45dd3 Write blit quadrants to channel
Reclaim the "blitted" and "full foreground" bits in the
channels. Instead, we now write four bits, encoding the
four quadrants we might occupy as the result of a blit.
These four imply the previous two, leaving us with four
free bits remaining in the channels. This opens a clear
path to O(1)-time, zero-space blitter stacking #1068.
w00t!
2021-02-02 00:57:58 -05:00
nick black
45c389a709 document *_core_init() #1301 2021-01-19 23:09:22 -05:00
Nick Black
9112185657
Split up notcurses/notcurses-core (#1297)
Extract `libnotcurses-core` from `libnotcurses`. The former contains everything except multimedia code. The latter contains multimedia stuff (a wrapper around FFmpeg or OIIO). If built with `-DUSE_MULTIMEDIA=none`, there will not be any `libnotcurses.so` generated. `libnotcurses.so` uses library constructors/destructors to insert its implementation into the `ncvisual` stack at runtime. Users linking `-lnotcurses` will get the full implementation; users linking `-lnotcurses-core` only will get the stack less multimedia code.

The upshot of this is that someone can compile/install only `libnotcurses-core`, and a program linked against it will work just fine. This eliminates the need to install the full (large) dependency stack of the multimedia code unless necessary. This will hopefully be useful for e.g. installers etc. Closes #339.
2021-01-18 14:10:04 -05:00
nick black
1108ebb5b6
Fix up some subtle pile issues
ncplane_destroy() needs to call ncplane_reparent_family(), not
ncplane_reparent() as it was doing (closes #1291). ->absy and
->absx actually are absolute; return them directly for an O(1)
ncplane_abs_yx() (down from O(N), huzzah). Add some unit tests
related to destroying and reparenting (#1286). Add ncplane_abs_y()
and ncplane_abs_x(), document them, etc.
2021-01-15 00:32:55 -05:00
nick black
1c0a623b8b
document new function ncplane_abs_yx() #1286 2021-01-14 23:06:43 -05:00
nick black
15386d57ce
nontrivial stacking unit test #1068 2021-01-08 04:59:24 -05:00
nick black
7e05d0438a
notcurses_init.3: fix up some syntax 2021-01-03 21:18:52 -05:00
nick black
18958e98cd update nccell def in docs 2021-01-03 19:20:19 -05:00
nick black
0c38728ceb Remove CELL_WIDEASIAN_MASK from docs #1277 2021-01-03 19:20:19 -05:00
nick black
af07822d35 Document base cell better
Improve the documentation for ncplane_set_base_cell() and
ncplane_set_base(). Go by render.c's authority (all three
channels are independently checked for transparency, and
replaced with the base cell if so--egc, fg, and bg). Add a
BASE CELL section to notcurses_plane.3. Check for, and reject,
an nccell which is secondary among a multicolumn EGC.

Closes #1238.
2021-01-02 13:28:15 -05:00
nick black
58bc9bd3bc
fix up writeout stats, report in shutdown banner 2020-12-28 04:50:20 -05:00
nick black
248dd1fff2
add dynamic linesig control #1228 2020-12-20 20:16:08 -05:00
nick black
d56ea8b5e7 progbar: remove egcs options 2020-12-13 09:12:08 -05:00
nick black
1d74979718 progbar core / poc #1202 2020-12-13 09:12:08 -05:00
nick black
6bff720122 initial API + documentation for ncprogbar #1202 2020-12-13 09:12:08 -05:00
nick black
33862979da
scan-build: remove dead stores 2020-12-13 02:43:49 -05:00
nick black
fd2acde1b1 rename cell->nccell, keep alias #1200 2020-12-13 00:49:37 -05:00
nick black
e60a7aa463
add stat for notcurses_refresh() 2020-12-06 13:45:35 -05:00
nick black
14fa544433
add NCPLOT_OPTION_PRINTSAMPLE #1183 2020-12-06 06:33:54 -05:00
nick black
6fb5c1e512 Fill out some API holes, improve some comments
- Disambiguate the docs for ncplane_erase()
- Add ncpile_top(), ncpile_bottom()
- Refuse attempts to modify the standard plane's resizecb
- Copy alignment and resizecb in ncplane_dup()
- Add cell_load_egc32()
2020-12-03 01:02:16 -05:00
nick black
53e905bb57 USAGE: fix up cell_{on, off}_styles as spotted by grendello 2020-11-28 20:45:16 -05:00
nick black
b7ea4e2359
run sgr-full and sgr-direct in test suite #1138 2020-11-27 15:38:36 -05:00
nick black
202e3535d5 document new NCSTYLE_STRUCK #1138 2020-11-25 20:04:14 -05:00
nick black
b33c780c88 document ncpile_render(), ncpile_rasterize() 2020-11-25 19:19:31 -05:00
nick black
b6e5b60374 ncpile_create() not NCPLANE_OPTION_NEWPILE #1078 2020-11-23 22:58:05 -05:00
nick black
b747af2ae8 drop NCPLANE_OPTION_NEWPILE #1078 2020-11-23 22:58:05 -05:00
nick black
0da6a8c44b add NCPLANE_OPTION_NEWPILE #1078 2020-11-23 22:58:05 -05:00
nick black
c0cb5c7ff9
add ncplane_resizecb() #1124 2020-11-18 08:00:02 -05:00
nick black
6084105c68
add ncplane_set_resizecb() #1124 2020-11-18 07:49:22 -05:00
nick black
1e6f8e4901 USAGE/python/man: update ncplane_options #1115 2020-11-17 23:42:36 -05:00
nick black
51d01b22c8
who knows how this happened 2020-11-13 20:10:39 -05:00
nick black
259b2b6012
make it clear that sixel is not yet supported 2020-11-11 03:12:37 -05:00
joseLuís
219bc34128 fix typo 2020-11-09 16:05:48 +01:00
joseLuís
00b5445418 fix typos 2020-11-04 18:27:36 +01:00
nick black
5647864745 update USAGE for new-skool blitter defs 2020-10-29 18:15:42 -04:00
nick black
b35c680f48 add LoopVideo unit test #1066 2020-10-21 00:47:21 -04:00
nick black
8919d6fe70 ncvisual_rewind 2020-10-21 00:47:21 -04:00
nick black
0b825c619e
add notcurses_stddim_yx_const() 2020-10-19 01:38:25 -04:00
nick black
a44090a7f7
s/notcurses/Notcurses/g 2020-10-12 09:44:03 -04:00
nick black
d101d2d2d9 add ncdirect_init() inhibit cbreak flag #1049 2020-10-07 07:43:50 -04:00
nick black
c6c157a5ad
notcurses_stats_alloc() everywhere 2020-10-07 04:24:10 -04:00
nick black
f9e2c7863b
add notcurses_stats_alloc #1043 2020-10-06 23:33:28 -04:00
nick black
270b1b20ee implement notcurses_render_to_buffer() #214 2020-10-04 11:43:25 -04:00
nick black
b4f1065f69 declare notcurses_render_to_buffer() #214 2020-10-04 11:43:25 -04:00
nick black
222861de13 add ncstats to USAGE.md 2020-10-04 10:04:02 -04:00
nick black
afa65f640f update notcurses_plane.3 and USAGE.md for new styles API 2020-09-29 13:09:44 -04:00
nick black
20bf1ae2d4
nctablet_ncplane() -> nctablet_plane() 2020-09-27 16:46:39 -04:00
nick black
ec85dd1c3b
ncreel_destroy: return void 2020-09-27 15:57:03 -04:00