Commit Graph

595 Commits

Author SHA1 Message Date
nick black
71dbfd74f7 ncmenu: step around alignment NULL #332 2020-02-09 06:30:17 -05:00
nick black
3bbb752554 ncmenu: unrolled body needs be transparent #329 2020-02-09 06:30:17 -05:00
nick black
5b20651836 demo: add menu, but disable for now 2020-02-07 09:19:08 -05:00
nick black
3cdac5ce28 high-contrast text, simple linear average model #181 2020-02-07 09:19:08 -05:00
nick black
1ed6000193 ncstats: add plane count, fix fbbytes accounting 2020-02-07 09:19:08 -05:00
nick black
dfe4a99446
ncplane_putegc_yx: set sbytes on error path 2020-02-07 01:05:08 -05:00
nick black
85e377e652
Accept US-ASCII/C encoding, with warning. 2020-02-06 22:05:48 -05:00
nick black
62488eaf10
blit->ncblit #324 2020-02-05 20:40:36 -05:00
nick black
74775b97ec
enmetric->ncmetric #324 2020-02-05 20:18:11 -05:00
nick black
89f516dcaa
tablet->nctablet, add ncreel to python #324 2020-02-05 20:04:56 -05:00
nick black
c519c95fff
panelreel -> ncreel #324 2020-02-05 17:29:42 -05:00
nick black
01bc543399
tag demos requiring ffmpeg 2020-02-05 10:41:13 -05:00
nick black
0bff959eed
demo: don't allow HUD to drive rendering 2020-02-05 07:50:55 -05:00
nick black
14f03f781a
add some missing locking #290 2020-02-05 06:02:14 -05:00
nick black
09ff64e19f
ncdirect_style_*() #321 2020-02-05 02:52:45 -05:00
nick black
bb7b92ea4a
ncdirect_styles_*() declarations #321 2020-02-05 02:27:41 -05:00
nick black
ab3a91c5d0
python for ncdirect 2020-02-04 04:16:16 -05:00
nick black
8ac16b734f
keep ncmenu on top #179 2020-02-04 02:20:02 -05:00
nick black
2a9f3c5ab3
ncmenu_selected(), update docs #179 2020-02-04 01:05:51 -05:00
nick black
4d613217b3
ncmenu: only allow one at a time 2020-02-04 00:17:51 -05:00
nick black
10a269c963
ncmenu: reject double menu 2020-02-04 00:08:03 -05:00
nick black
039a390877
ncmenu: print item shortcut aligned right #179 2020-02-03 23:55:19 -05:00
nick black
79a92fcfb1
ncmenu: highlight shortcut keys for menu items 2020-02-03 22:14:29 -05:00
nick black
3821b66bc7
menu: highlight (bold+uline) section shortcuts 2020-02-03 21:32:04 -05:00
nick black
5cd4fc9a1f
menu: reject empty sections #179 2020-02-03 13:08:45 -05:00
nick black
0977fa0d56
menu: don't alight cursor on separators 2020-02-03 12:33:06 -05:00
nick black
ee6eb1a37b
ncmenu: support iteration within a section 2020-02-03 01:07:58 -05:00
nick black
fa88f9b525
ncmenu: nextsection/prevsection 2020-02-02 19:02:52 -05:00
nick black
88a0ffff07 ncmenu: fill in sections #179 2020-02-02 12:57:32 -05:00
nick black
c3ad38adb9 ncmenu: size body width based on items #179 2020-02-02 12:57:32 -05:00
nick black
4586dd7e19 ncmenu: properly place unrolled menu #179 2020-02-02 12:57:32 -05:00
nick black
ce965fcbcd ncmenu: add unroll and rollup #179 2020-02-02 12:57:32 -05:00
nick black
2118c5d81a menu: draw background only onto header row #179 2020-02-02 12:57:32 -05:00
nick black
db53b36d94 ncmenu: calculate height based off sections #179 2020-02-02 12:57:32 -05:00
nick black
7708ec5c96
notcurses_stop_minimal() for use from signal handler #313 2020-02-02 06:26:24 -05:00
nick black
31a07dab33
menu: extend across width of screen #179 2020-02-02 06:02:57 -05:00
nick black
015ce4764e ncmenu: set up the section headers #179 2020-02-02 05:13:40 -05:00
nick black
fdc541c6e5 copy over menu elements #179 2020-02-02 05:13:40 -05:00
nick black
54c57b3487 s/CELL_STYLE/NCSTYLE/ throughout 2020-02-02 05:13:40 -05:00
nick black
8984422f1e basics of menu #179 2020-02-02 05:13:40 -05:00
nick black
6e642f1749 more menu work #179 2020-02-02 05:13:40 -05:00
nick black
321ea908f1
Fix up BGR/RGB reversal in blitter #311 2020-02-02 02:22:38 -05:00
nick black
25ce448889
rgba_blit()/bgrx_blit() #311 2020-02-02 02:20:01 -05:00
nick black
f3af2b8760
Convert mbtowc to mbrtowc everywhere #308 2020-02-01 17:21:13 -05:00
nick black
44f80694a3
selector: bind with ┴ where appropriate #309 2020-02-01 14:24:56 -05:00
nick black
4716b5f495
selector: bind riser to body #309 2020-02-01 14:01:20 -05:00
nick black
39f99dfa4a
Selector: final styling touches #302 2020-02-01 02:25:00 -05:00
nick black
c1664170fd
selector: bgchannels only inside the body #302 2020-01-31 21:25:21 -05:00
nick black
eab1ce0262
selector: align secondary/footer #302 2020-01-31 20:38:58 -05:00
nick black
45235fc076
Selector: add arrows if there are more options #302 2020-01-31 19:58:55 -05:00
nick black
fad612bd2f
Use column width in selector calculations #302 2020-01-31 19:51:14 -05:00
nick black
43ce3e5ccb
selector: don't FPE on empty itemlist #302 2020-01-31 02:49:34 -05:00
nick black
05a83e54c7
Selector: inverse rather than reverse video #302 2020-01-31 00:55:25 -05:00
nick black
fe51f93a4c
selector: destroy ncplane on exit 2020-01-31 00:28:34 -05:00
nick black
77432ee1c5
set ~ICRNL with termios.c_iflag #303 2020-01-31 00:26:52 -05:00
nick black
99b79cbf4f
ncselector_create: fix base_egc fuckup #302 2020-01-31 00:02:00 -05:00
nick black
6a4cfcde95
selector: always rotate options #302 2020-01-30 23:05:30 -05:00
nick black
d30df23f43
selector: support non-zero default idx #302 2020-01-30 22:42:25 -05:00
nick black
a57f0f234c
selector styling 2020-01-30 22:16:03 -05:00
nick black
e4dcccc409
selector: implement scrolling 2020-01-30 19:54:20 -05:00
nick black
3991b3e53a
selector: implement maxdisplay. unit tests! 2020-01-30 19:37:21 -05:00
nick black
ac2b951fa9
ncselector_selected(), unit tests 2020-01-30 16:40:02 -05:00
Nick Black
da0283ac25
Selector widget #166, subtitles #95 (#301)
Get rid of annoying empty line in notcurses-view (and ncvisuals at offsets in general)
Implement most of the Selector widget. Need to add styling and scrolling still. #166
Reenable ubuntu focal build
Subtitles! We decode them, and display them in notcurses-view. If ncvisual_simple_streamer() is provided an extra ncplane, it will use it to display subtitles. #95
We now build Python by default, as things are working much better.
ncplane_set_base() now takes channel, attrword, and EGC, so you can usually avoid having to set up and release a cell. ncplane_set_base_cell() takes over duty from ncplane_set_base() for ease of conversion.
notcurses-demo and notcurses-view now both accept a 0 for delay multiplier, meaning 'go as fast as you possibly can'. Very small multipliers (e.g. 0.00001) no longer cause floating point exceptions.
fading routines no longer cause floating point exceptions on very small timescales.
2020-01-30 08:55:01 -05:00
nick black
345ed60abd
Improve smcup handling
If we're going to issue smcup to switch to the alternate screen,
flush immediately after doing so. Otherwise, subsequent output
prior to the first render can be swept away. See growlight issue
75: https://github.com/dankamongmen/growlight/issues/75. In the
demo, we now get this output either (a) at the beginning (if smcup
is inhibited) or (b) at the end (default). Only perform our pause
on startup in case (a).
2020-01-29 00:25:18 -05:00
nick black
c04a68896c
README: add FAQ entry about c++ scopes 2020-01-25 11:06:08 -05:00
nick black
2cad2bbfd5 direct mode: properly initialize termcaps #77 2020-01-25 07:17:45 -05:00
nick black
81b58234ee
direct mode: reset terminal, check vals #77 2020-01-25 01:37:51 -05:00
nick black
1fd0563093
Direct mode with its own type #77
Introduce the new type 'ncdirect', a stripped-down 'notcurses'
suitable for inline modification of regular output. Used the new
type because otherwise there were going to be if(directmode) checks
everywhere. Direct mode encompasses only colorizing and styling.
Add new man page notcurses_directmode(3). Add new section to README.
Add new PoC using direct mode RGB. Update demo table summary to use
direct mode.
2020-01-25 01:13:04 -05:00
nick black
3d4e157af6 direct-mode coloring #77 2020-01-24 04:06:41 -05:00
nick black
d8849bb4b1 uniblocks: add a few missing blocks 2020-01-24 04:06:41 -05:00
nick black
2ea10d4b28 Remove clear_screen_start option
As it turns out, we can't portably load the initial terminal contents
(there are some hacks of various EXTREME nature, but none of them are
worth it for the rather limited benefit). The O(1)-time damage
inference requires knowledge of what was previously present to
inibit unnecessary draws. We would then need some special cell value
indicating "not yet written to" to distinguish a purposeful null
cell from an initial cell. Again, we could do this, but for what value?

Finally, the idea of clearing new area on SIGWINCH was always flawed,
as we can't do that from a signal handler.

With the advent of direct mode #77, the reason for this largely goes
away in any case.
2020-01-24 04:06:41 -05:00
nick black
55699c6a3c
render summary: autoscale all times 2020-01-22 08:28:56 -05:00
nick black
22f71c9a80
implement quantize_rgb8() for linux console #288 #4 2020-01-21 00:43:36 -05:00
nick black
48025cd794
report Alt in ncinput #228 2020-01-20 00:10:18 -05:00
nick black
be3a53f3cf
input: function key defs through kf59 2020-01-20 00:00:09 -05:00
nick black
1aa462385e
detect ctrl+letter, prep ncinput appropriately #228 2020-01-19 23:45:55 -05:00
nick black
4ece4a9075
demo: skip demos which we don't have support for 2020-01-19 06:09:59 -05:00
nick black
ec5e857a6c
palette256: fix up unit tests 2020-01-19 04:04:13 -05:00
Nick Black
3d612aebcb
ruins color cycling demo #253 (#287)
* palette_set: update pal256 damage map #230
* drone: use newest builders
* palette: send oc on exit for color reset #285
* palette_new: copy existing palette in #230
* Python: use checkRGB everywhere
* more palette unit testing
* add ncplane_set_*_palindex()
* render fg palindex #230
* palette index color is out of 1000
* jungle demo works #253
2020-01-18 20:42:29 -05:00
nick black
03e3c5406d
interrogate_term: check CCC if initc is defined 2020-01-18 16:06:24 -05:00
nick black
f450c1261a
libav: don't molest user pointer 2020-01-17 12:19:32 -05:00
nick black
3e9347a339
palette color: unit test for alpha clear 2020-01-17 11:49:21 -05:00
nick black
f5e151e9a0
render+raster palette-index support #230 2020-01-17 11:34:25 -05:00
nick black
b02acd8631
Curry a void* to fader callbacks #284 2020-01-17 09:30:53 -05:00
nick black
5d69545f22 rgb_greyscale: linear approximation to gamma decomp 2020-01-17 08:35:28 -05:00
nick black
1b01494c79 implement ncplane_greyscale() #280 2020-01-17 08:35:28 -05:00
nick black
3e6a862603 libav: require alpha 192 to be visible 2020-01-17 08:35:28 -05:00
nick black
4c7093901b banner: print term shortname/dims 2020-01-17 08:35:28 -05:00
nick black
2783a1b503 ncplane_move bugfix when already in desired config 2020-01-17 08:35:28 -05:00
nick black
08f6fa0e79 implement ncplane_dup() 2020-01-17 08:35:28 -05:00
nick black
38b2b3d075 render: fix bad reference in final pass 2020-01-17 08:35:28 -05:00
nick black
209d4f41f4 palette: add necessary predicates #230 2020-01-17 08:35:28 -05:00
nick black
0e70304596 palette indexing: set up attributes #230 2020-01-17 08:35:28 -05:00
nick black
20f4b3493c send palette updates (initc) #230 2020-01-17 08:35:28 -05:00
nick black
dfcdd10cb5 more palette support/testing #230 2020-01-17 08:35:28 -05:00
nick black
684bcdcc8c introduce palette256 #230 2020-01-17 08:35:28 -05:00
nick black
98446b4810 render: fix setting of channel on wide 2020-01-17 08:35:28 -05:00
nick black
fc1341ea5a
painter: skip unnecessary work 2020-01-15 04:58:00 -05:00
nick black
aba9a4f967 Eliminate fprintf() for ~20% FPS boost #277
Profiling with `perf` revealed the fprintf() inside term_esc_rgb()
to dominate our performance. Replace it with a u8->str lookup table
and a hand-assembled string fed into a single fputs(). On a 80x70
xfce4-terminal geometry, this wins 20%+ FPS on the demo, w00t!

Huzzah for profiling!
2020-01-15 04:50:54 -05:00
nick black
b8f25ff89b Map 8-bit ffmpeg α to 2-bit notcurses α #276 2020-01-15 04:50:54 -05:00
nick black
f857edd09d libav: render spaces when possible 2020-01-15 04:50:54 -05:00
nick black
17df279b66 libnotcurses-sys rust lowlevel bindings 2020-01-15 04:50:54 -05:00
nick black
3011a59cbd don't call ncplane_dim_yx() in notcurses_render_internal 2020-01-15 04:50:54 -05:00
nick black
385d37ac8c painter: drop loop at end, nice FPS gain 2020-01-15 04:50:54 -05:00
nick black
5f58ef3a4d
implement ncvisual timescaling #275 2020-01-14 15:56:45 -05:00
nick black
dd7f8eff4b
ncvisual_stream: add timescale param 2020-01-14 15:50:17 -05:00
Nick Black
7ec022d067
Painter's algorithm #255 (#274)
* notcursesI.avi 30 -> 60fps
* painter's algorithm works #255
2020-01-14 03:51:11 -05:00
nick black
7c687faea0
pulsing text + unit test + docs #163 2020-01-14 01:09:37 -05:00
nick black
13c2dc9841
fade: propagate fader return value 2020-01-14 01:09:31 -05:00
nick black
56a54b5441
break apart render/rasterize #155 2020-01-12 23:01:03 -05:00
nick black
49d684c772
render: always restore char when recovering 2020-01-12 08:33:56 -05:00
nick black
3faffaa847 channels_blend() : don't blend in wide status #260 2020-01-12 07:46:38 -05:00
nick black
8b4de3f482 add internal cell_debug() 2020-01-12 07:46:38 -05:00
nick black
0f60af347d add clipped set functions 2020-01-12 07:46:38 -05:00
nick black
f36431bc19 render: inherit wide mask on assignment #260 2020-01-12 07:46:38 -05:00
nick black
3ee48a8233 vfprintf: need a va_copy() 2020-01-12 05:04:34 -05:00
nick black
dc2f788d28 summary: match rounding #268 2020-01-12 00:09:37 -05:00
nick black
7895d06273 cursor_move(-1,-1) while invalid is invalid #270 2020-01-12 00:09:37 -05:00
nick black
00e6ecac7d fade: avoid divide by zero on empty plane #269 2020-01-12 00:09:37 -05:00
nick black
abc17d37aa ncplane_vprintf_prep: reprint after realloc #260 2020-01-12 00:09:37 -05:00
nick black
ebbac42bf6
whoomp, there it is: fix all libav timing issues #159 2020-01-09 05:17:09 -05:00
nick black
306045116f API: always call complex from static simple 2020-01-07 16:15:27 -05:00
nick black
acef43c759
avcodec_parameters_to_context() #215 2020-01-07 09:30:50 -05:00
nick black
309211e308
enmetric() for small values #256 2020-01-07 00:24:20 -05:00
nick black
14d7bed6db
notcurses-input: fix banner display #263 2020-01-06 23:32:06 -05:00
nick black
b37ea582a3
enmetric()ize total time output in demo summary 2020-01-06 15:58:16 -05:00
nick black
c00fc3c3f7
mask out SIGWINCH in demo #262 2020-01-06 00:00:49 -05:00
nick black
7e59cf1053
don't print Term line with suppress_banner 2020-01-05 05:13:05 -05:00
nick black
3d02318e29
panelreel-demo: hook up pipe 2020-01-05 04:38:32 -05:00
nick black
07c175b320
refrain from using undefined terminfo capabilities #252 2020-01-05 00:17:59 -05:00
nick black
9c8ce83f95
chunli/view: trans out 2020-01-04 07:49:10 -05:00
Nick Black
f5c6297902
Chun Li demo (#251)
* chun li demo
* ncvisual_decode: allow multiple renders of the same frame
* add -H to notcurses-demo man page
* update section 1 man page versions
2020-01-04 07:21:54 -05:00
nick black
5dd90f3735 add ncplane_dim_[yx] quick accessors 2020-01-04 04:34:29 -05:00
Nick Black
f6975d11d5
Docs/API sweep for 1.0.0 #244 #249 (#250)
* sync up some docs #244
* sync README and man page
* notcurses_output() man page work
* pull attr/channels from output functions #244
* witherworm: clean up explicit moves #244
* still more man page work
* notcurses_lines, last of the man pages i think
* panelreel man page #244
* debian: ruby-ronn->pandoc
* debian: full multiarch compliance
* debian: symbols file
* pandoc: fix syntax for lexgrog
* fm6.mkv: strip audio
* pandoc: fix up apropos man syntax #249
* ncurses_lines man page
2020-01-04 02:37:55 -05:00
nick black
0de1856e38 accept a loglevel for libav 2020-01-03 05:51:27 -05:00
nick black
44da49d351
ncvisual: free up the oframe #241 2020-01-01 07:25:39 -05:00
nick black
e05ec51629
ncvisual: fix the major memory leak in streaming #241 2020-01-01 07:18:25 -05:00
nick black
bc1f9bfb43
ncvisual: free up image alloc #241 2020-01-01 07:07:45 -05:00
Nick Black
2fbc94e41c
Higher planes obliterate bisected wide glyphs #158 (#243)
* higher planes stomp wide glyphs
* broken unit test
* develop out widestomp PoC
* fix notcurses_at_yx()
* fix up dig_visible_cell() return value
* refuse wide glyph on last column #242
* set adjacent cell wide when rendering #158
* xray: eliminate weird color flicker
* witherworm: don't eat wide glyphs
* unit test for boxed glyph
* uniblock: no need to emit so many U+200Es
* witherworm: remove wide glyph hack
2020-01-01 06:41:19 -05:00
nick black
48177b8474
implement notcurses_at_yx() 2019-12-31 21:30:20 -05:00
nick black
35aa7f6e85
move cell_egc_copy() to internal.h 2019-12-31 21:29:57 -05:00
nick black
bdcea181a2
don't sleep without defined interval #224 2019-12-30 07:55:50 -05:00
nick black
e03653b964
fix libav when DISABLE_FFMPEG is used 2019-12-30 07:04:07 -05:00
nick black
99541cc036
pull out terminfo's cub1 2019-12-30 07:03:46 -05:00
nick black
2ea4f77875
introduce ncplane_aligned() #237 2019-12-30 02:28:40 -05:00
nick black
8926fc5879
cursor: always get cnorm/civis defs #240 2019-12-30 01:50:43 -05:00
nick black
bcd12279c0 ncvisual: handle plane resize #169 2019-12-30 01:10:10 -05:00
nick black
ed980f1059 pull _get from all accessors 2019-12-30 01:10:10 -05:00
nick black
014afa348b rename ncplane default -> base #236 2019-12-30 01:10:10 -05:00
nick black
d5748c634d ncvisual: keep duration sum for better sync #113 2019-12-29 23:28:14 -05:00
nick black
707862507d use video pts when available #113 2019-12-29 23:28:14 -05:00
nick black
c21a04137c curry a void* through ncvisual_stream #113 2019-12-29 23:28:14 -05:00
nick black
db8b99d594
notcurses_render: simplify using new alpha rules 2019-12-29 19:37:24 -05:00
nick black
924d80f0d5
don't blend default colors #235 2019-12-29 17:49:38 -05:00
nick black
46b1b8e622
notcurses_stats man page #213 2019-12-29 03:24:32 -05:00
nick black
21c3861804
s/bannner/banner/g, heh 2019-12-28 18:37:44 -05:00
nick black
e9890eefc0 general foreground elision #131 2019-12-27 20:27:12 -05:00
nick black
5b322add56 glyph-based background spec elision #131
When we emit a glyph that has no background pixels (i.e.
the U+2588 FULL BLOCK glyph), there's no need to emit a
background color change.

Eagle demo currently has hand-coded elision. Results from
80x70 runs using the `-c` parameter:

No optimization: 12.63MiB
Hand-optimized: 12.48MiB
New scheme, no hand-coded optimization: 12.45MiB

w00t!
2019-12-27 20:27:12 -05:00
Nick Black
ce2a390b52
Out with googletest, in with doctest #202 (#231)
* introduce doctest over googletest #202
* call dtester in in targets
* doctest conversion #202
* channel.cpp -> doctest #202
* egcpool tests -> doctest #202
* input tests to doctester
* zaxis -> doctest
* drone: always define LANG
* libav to doctest #202
* panelreel tests to doctest #202
* spec that a C++17 compiler is now required for doctest #202
* enmetric tests -> doctest #202
* fade tests -> doctest #202
* notcurses test case -> doctest #202
* last conversion to doctest #202
* finish move to doctest #202
* drone: set up make test
2019-12-27 17:20:20 -05:00
nick black
d4caefc55d
fade: throw a 10ms cap in, improves visual and lessens load 2019-12-27 10:41:49 -05:00
nick black
148114c6ca
rewrite term_esc_rgb for ~8% more FPS 2019-12-27 09:55:06 -05:00
nick black
132793211c
capabilities testing for fade/ffmpeg 2019-12-27 05:13:29 -05:00
nick black
bf49db1ae4
FreeBSD: guard all uses of _unlocked #196 2019-12-27 03:46:39 -05:00
nick black
09aa606281 FreeBSD: no CLOCK_MONOTONIC_RAW #196 2019-12-27 02:48:13 -05:00
nick black
caf7e41737 need struct AVFrame for sans-libav build 2019-12-27 02:48:13 -05:00
nick black
430a321557 don't import av headers in non-ffmpeg build 2019-12-27 02:48:13 -05:00
nick black
bd034c983a input: handle modifiers+mouse (alt, shift, ctrl) #226 2019-12-27 02:48:13 -05:00
nick black
fb0e03fe89 UMOK: fadecb for faders #162 2019-12-27 02:48:13 -05:00
nick black
91a00b3400 ULTRAMEGAOK: feed the HUD #162 2019-12-27 02:48:13 -05:00
nick black
13b376f94f
panelreels: fix logic error at bottom #222 2019-12-25 11:45:42 -05:00
nick black
7906989582
kill obsolete FIXME 2019-12-25 10:45:22 -05:00
nick black
770cdf4773
panelreel: plug up hole at the bottom #220 2019-12-25 10:22:07 -05:00
Nick Black
4571b57ece
Rust/FreeBSD (#221)
* rust bindings
* update release documentation with Rust info
* panelreel tester: accept command-line options#180
* input: char32_t not wchar_t in output
* freebsd compilation issues #196
2019-12-25 10:11:24 -05:00
Nick Black
63ada9289c
Implement CELL_ALPHA_BLEND, improve transparency semantics #191 (#219)
* channels_blend() introduced
* implement CELL_ALPHA_BLEND #191
* maxcolor demo: slidingpanel
* much improved transparency semantics #191
* maxcolor: show all transparencies #191
2019-12-25 06:36:35 -05:00
nick black
4b6063e1ce sliders: fix timing 2019-12-25 02:24:10 -05:00
nick black
cb2bf16a73 support building sans ffmpeg #153 2019-12-25 02:24:10 -05:00
nick black
8d26803ed8
fix linear interpolation on large geometries #216 2019-12-25 00:12:21 -05:00
nick black
4b953e33f2
render: carry state across renders #203 2019-12-24 05:34:39 -05:00
nick black
ca5e14cdad
xraydemo: isolate avi/text 2019-12-24 01:17:49 -05:00
nick black
efcfa372ae
ULTRAMEGAOK: toplevel event handler #207
enable mouse events in the demo. spawn a thread from main() which
brokers all input events. it will consume mouse events, and
publish keyboard events to a queue. rewrite all demo notcurses_getc()
calls to demo_getc() equivalents.
2019-12-24 00:10:20 -05:00
nick black
452e1d302e
output API enhancements #210 #209
Allow -1 in move specification to remain where we are on that
axis (#210), necessary for context-sensitive aligned output.
Add _aligned forms to printf and vprintf. Invert various output
functions so that simpler form is static inline wrapper around
more complicated form, rather than complicated form being a
static inline composition, facilitating atomic move+output. All
output forms now have a simple form (no alignment, placement at
cursor), an _aligned() form, and a _yx() form.
2019-12-23 23:12:29 -05:00
nick black
f742676aee Mouse support using button event tracking #165
Request and parse up mouse messages. We handle up to 11 mouse
buttons, 3 modifiers (currently thrown away), motion while
holding down a button, and loss/gain of focus. I've added twelve
new NCKEYs: one for each button, and one for release. In addition,
I've introduced the 'ncinput' struct, which encodes the nckey plus
extra data. The only extra data thus far is coordinates for mouse
events. It is not necessary to provide a ncinput to all input
functions; NULL can be provided if the caller doesn't care about
details. All demos are updated. notcurses-input has been updated
to decode full information of returned ncinputs.

The primary resource for this work was Dickey at al's "XTerm Control
Sequences", https://invisible-island.net/xterm/ctlseqs/ctlseqs.html.
2019-12-23 19:08:12 -05:00
nick black
aceda89261 input: add NCKEY_MOUSEEVENT, match against CSI prefix #165 2019-12-23 19:08:12 -05:00
nick black
b4b4b3684a yaml 2019-12-23 19:08:12 -05:00
nick black
1555edfa6c
notcurses: disable mouse events on startup/shutdown 2019-12-23 03:38:38 -05:00
nick black
78633de427
mouse: use SGR extended coordinates 2019-12-23 03:36:29 -05:00
nick black
ab47ab8976
notcurses_mouse_on()/_off() #165 2019-12-23 02:47:34 -05:00
nick black
046d0314b9
add links to useful man pages 2019-12-22 22:45:20 -05:00
nick black
2a256192ad
input: allow duplications of escapes #199 2019-12-22 15:57:41 -05:00
Nick Black
9b81de3789
O(1) passive damage detection #189 (#197)
* notcurses: set up lastframe #189
* render: o(1) take no prisoners damage detection #189
2019-12-22 08:08:53 -05:00
nick black
8b1b2ebdf0
term_esc_rgb: add note about ITU T.416 syntax 2019-12-22 02:02:12 -05:00
nick black
c3fa7ea664
bleachworm replaces widechomper #177 2019-12-22 00:27:43 -05:00
nick black
a710222df1
enmetric(): support localized decimal separator #192 2019-12-21 20:44:34 -05:00
Nick Black
3ad2124246
Partial visual renders #170 (#193)
* ncvisual_render() accept four bounding dims #175
* ncvisual_render(): partial renders #175
2019-12-21 16:02:27 -05:00
nick black
7f01dfc241
planereel-tester: delete support 2019-12-20 22:23:33 -05:00
Nick Black
0e0925a84e
Planereel exploration app, panelreel logic fixes (#188)
* planereels tester #180
* suppress_banner in all tests
* tabletcb: start passing back tablet
* properly initialize fbbytes stat
* panelreel: logic fixes #178
* install all testing data
2019-12-20 20:38:13 -05:00
nick black
b0b1679de6
ncvisual_render(): use true transparency #186 2019-12-20 12:54:29 -05:00
nick black
1ebe02cf93
libav: disable stderr logging #174 2019-12-20 12:06:11 -05:00
nick black
3f326ee0a8 fix up ncplane_set_{bf}g 2019-12-20 09:42:41 -05:00
nick black
4950a5ac1a
print enmetricized byte totals 2019-12-20 03:42:00 -05:00