Commit Graph

711 Commits (66725909961fc790298ba4dd5b2a8a49cc2027a7)

Author SHA1 Message Date
nick black 6693e5f386
pass tcache down through visual blit stack #1095 3 years ago
nick black 7b61395ec4 sixel: set egc width properly based off tcache #1380 3 years ago
nick black 7592d0c4a3 rendered mode: properly scale pixel graphics #1380 3 years ago
nick black 0ffbba3365 restore stashed stats for closing banner #1374 3 years ago
nick black 100a89291b hide cell_{b,f}channel(), cell_set_{b,f}channel() 3 years ago
nick black 53c52e30ff remove c++/rust channel wholesalers 3 years ago
nick black 6c7c9be6d2 require explicit check for pixel support
Add `notcurses_check_pixel_support()` and
`ncdirect_check_pixel_support()` per #1367. Removes
NCOPTION_VERIFY_SIXEL, again per #1367. Adds
`free_terminfo_cache()`, and calls it from both
`notcurses_stop_minimal()` and `ncdirect_stop()`.
Update all documentation. Closes #1371 and #1367.
3 years ago
nick black 40746e76e6 s/nonehi/hires/g 3 years ago
nick black 391fef3a3f cell pixel defines / inlines #200 3 years ago
nick black 036d0a8697 s/NCBLIT_SIXEL/NCBLIT_PIXEL/g #1095 3 years ago
nick black aa4da3f335
nctree: drop bchannels from options 3 years ago
Nick Black e30b12a480
nctree (#1361)
The nctree widget, PoC, and unitt rs #1164.
3 years ago
nick black 2221120543 add SIGILL to documented fatal signals #1357 3 years ago
nick black 8a7ff8a317 signals: restore them on exit #1357 3 years ago
nick black 925870bd7a
update some definitions in USAGE.md 3 years ago
nick black 4951ea3d88
update comment on notcurses_lex_scalemode() 3 years ago
nick black d845e979c2
tighten up CELL_BG_ALPHA_MASK 3 years ago
nick black 2741b049cb
don't expose nctree in 2.2.2 3 years ago
nick black 1df9d85f28
Lock accesses to notcurses_stats #1139
notcurses_stats() and notcurses_stats_reset() now take the
new statlock member, as do stat modifications from render,
raster, writeout, resize, plane creation, and plane
destruction. Add nonnull attributes to stats API. Initialize
and destroy statlock as part of notcurses struct. Update
documentation. Free pilelock on error paths. Closes #1139.
3 years ago
nick black bb14694000 add nctree movement api #1164 3 years ago
nick black 3eb42d6c0c implment nctree_create()/free() #1164 3 years ago
nick black 7a698310b6 ncinput is not opaque 3 years ago
nick black 2348546932 nctree API cut 1 #1164 3 years ago
nick black e88875c4a7 nctree: add nctreecb to options #1164 3 years ago
nick black 7e56c8e1c2 nctree_options definition #1164 3 years ago
nick black 1b1e0b88be
ncplane_qrcode: drop blitter argument, update docs 3 years ago
nick black e63ca5f704 use ALLOC in ncdirect.h 3 years ago
nick black 602531ff33 include warn_unused_result in ALLOC 3 years ago
nick black 1b61786694 apply ((alloc)) attributes to API 3 years ago
Marek Habersack d32bef358d [C++] API sync
After a long delay, apologies :)

Added:
  * NotCurses: `can_sextant` (`notcurses_cansextant`)
  * Notcurses: `linesigs_enable` (`notcurses_linesigs_enable`)
  * Notcurses: `linesigs_disable` (`notcurses_linesigs_disable`)
  * Pile: `top_with` (`ncpile_top`)
  * Pile: `bottom_with` (`ncpile_bottom`)
  * Plane: `resize_maximize` (`ncplane_resize_maximize`)
  * Plane: `get_abs_x` (`ncplane_abs_x`)
  * Plane: `get_abs_y` (`ncplane_abs_y`)
  * Plane: `get_abs_yx` (`ncplane_abs_yx`)
  * Plane: `load_egc32` (`cell_load_egc32`)
  * Plane: `is_descendant_of` (`ncplane_descendant_p`)
  * Progbar: new class, wraps `ncprogbar_*`

Changed:
  * Plane (ABI break): `at_cursor` overloads now return `int` where
    before they returned `bool` because the underlying Notcurses API
    only signalled the operation status with the return value while now
    it returns actual information.
3 years ago
nick black 6b126f4049
add notcurses_canbraille() capability test 3 years ago
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.
3 years ago
nick black 43dd0440f7
add raster timing stats #1324 3 years ago
nick black 2491b693ba
Add missing channel_set_palindex()
Implement channels_set_fg_palindex() and channels_set_bg_palindex()
in terms of channel_set_palindex(). Add missing entries to
notcurses_channels.3 man page. Use uint32_t in place of unsigned
when dealing with channels in notcurses.h.
3 years ago
nick black b112b93901 use byteswap.h on GNU/Hurd #1320 3 years ago
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!
3 years ago
nick black f37ebba78d Add CELL_BLITTEDMASK to track ncvisual cells
For properly stacking transparent blittings (#1068), we
need tag those cells which both (1) originated in an
ncvisual operation and (2) have some transparency. For
the three affected blitters (halfblock, quadrant, and
sexblitter), call cell_set_blitted().
3 years ago
nick black 6bd288f056 Workable split of library
Rather than trying to force things in via library constructors
and weak symbols and --whole-archive and pkg-config tricks, just
add new functions ncdirect_core_init() and notcurses_core_init().
libnotcurses has ncdirect_init() and notcurses_init(), which pass
through to these. apps linking against notcurses-core ought use
the _core_ variants directly. This gets exactly the linkage we
want, everywhere. Convert many PoCs to _core_ variants. #1301

Signed-off-by: nick black <dankamongmen@gmail.com>
4 years ago
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.
4 years ago
nick black 1c0a623b8b
document new function ncplane_abs_yx() #1286 4 years ago
nick black 68b340e3c8
ncdirect: prep readline for use #1120 4 years ago
nick black 15386d57ce
nontrivial stacking unit test #1068 4 years ago
nick black 7e05d0438a
notcurses_init.3: fix up some syntax 4 years ago
nick black 54b44513c4
Wide EGC tweaks
Don't bias the nccell width by 1, or 0-length EGCs become
255 columns. We weren't actually using the width to drive
much anything until now, so this wasn't a problem, but it
is exposed as an error once we got rid of CELL_WIDE_ASIAN
and start looping through the actual egc column width.
Closes #1278, closes #1277
4 years ago
nick black 6d6416064e
ncdirect: set up fatal signal handlers #1271 4 years ago
nick black 998cf02f34
add NCDIRECT_NO_QUIT_SIGHANDLERS #1271 4 years ago
nick black 555a3262b1
add channel_palindex and friends 4 years ago
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.
4 years ago
nick black e522429dfb
direct: reorder declarations to please freebsd 4 years ago
nick black 7e20a25482
ncdirect_*_palindex -> ncdirect_set_*_palindex #1261 4 years ago