Commit Graph

4100 Commits (e20fb4ac8fb1f397761331c15cee1cd29239d1e5)
 

Author SHA1 Message Date
joseLuís 6049e07d27 rust: continue refactoring the error system.
- made const NotcursesOptions constructors.
- refactor Notcurses constructors to return NcResult.
- pass NotcursesOptions by value, since it's Copy.
- update tests.
- add helper modules for Notcurses & NcPlane.
  - new initialization functions to be used in tests.
- BONUS:
  - refactor NcDirect
  - update examples.
4 years ago
nick black b8c33a6caf
ncplane_highgradient: use direct blitting #1249 4 years ago
joseLuís b12abeddc9 rust: finish NcDirect error system refactor
- change Option return type for NcResult when appropriate.
- make NcDirect constructors return NcResult.
- rename NcError::new() to with_msg() and simplify new().
- refactor examples:
  - rename direct-image.rs to direct-image-c.rs
  - recreate using rust methods, as direct-image-rust.rs
  - differentiate more throughly between both styles.
  - remove the sys namespace on both examples.
4 years ago
nick black 4e5dbfd2b9
render: use hpa in place of cuf #1245 4 years ago
nick black 1002347c9e
HACKING: document right-to-left shittery 4 years ago
joseLuís 1687af89e0 rust: refactor error system.
We need to use Result<> to manage error flow,
at least on the methods API. This way it will
finally feel idiomatic Rust and more concise.
Also, we can't return a non Result from main.

- rename NcResult to NcIntResult.
- new NcError & NcResult types.
- new error![] macro to reduce boilerplate.
- change return type of NcDirect methods to NcResult.
  - refactor several examples to return NcResult:
    direct-cursor, poc-direct & poc-kittyzapper.
- BONUS: fix test not stopping notcurses context.
- update lib doc-comment.
- fix typo in readme.
4 years ago
joseLuís 5d1dfe1d02 rust fix poc-direct; update readme deps badge 4 years ago
joseLuís ab2675b358 rust: add poc-direct example
- fix NcDirect dim_[y|x] methods.
- add NcDirect.dim_yx() method.
4 years ago
joseLuís a9413eafb2 rust: add poc-kittyzapper example
- fix ncdirect_[b|f]g_rgb8 functions.
- fix NcDirect.bg_rgb8 method.
- new printf![] macro.
4 years ago
joseLuís 3c8328c9cc rust: add all NcDirect methods.
- add missing ncdirect_* static inline functions.
- update Notcurses.getc().
- add NcTime constructor.
- add NcSigSet type + constructor.
- minor fixes.
4 years ago
joseLuís 7d53abc1b1 rust: finish Notcurses methods & fix tests 4 years ago
joseLuís b62c1ec74b rust: refactor NcCell constructors 4 years ago
joseLuís 815507293d rust: fix tests 4 years ago
joseLuís c07b68f783 rust: add example poc-cjkscroll 4 years ago
joseLuís bf7f5de745 rust: fix putchar related methods.
- refactor NcCell constructors.
- add Notcurses.term_dim_yx method.
- reduce name imports.
- fix comments.
4 years ago
joseLuís e174ad44e2 update rust version in readme 4 years ago
joseLuís ca38d9109e rust: add NcCell Methods.
- improve some apis.
- made some functions const.
- add comments and intra-doc links.
- fix comments.
4 years ago
joseLuís bda47b7403 rust: add methods for NcResizeCb & NcPalette.
- fix intra-doc links.
- refactor palette module.
4 years ago
joseLuís 1afa9cc1db rust: add more methods.
- add NcChannel & NcChannelPair methods.
- add more NcPlane methods.
- add comments and intra-links.
- refactor intra-links style in all modules.
4 years ago
nick black f1cd068da3
add atma.png for keller 4 years ago
nick black e6a45d5422
wcwidth: print running measure 4 years ago
joseLuís 3be38890c9 rust: refactor input module.
- unify NcInput & NcKey in the same module.
- fix lifetimes issue.
4 years ago
joseLuís 298f250ee8 rust: refactor unsafe functions.
- remove unneeded unsafe.
- simplify lifetimes.
- fix ncplane_gradient_sized.
- fix NcChannelPair
- fix comments.
- rustfmt.
4 years ago
joseLuís af11b123fa rust: add NcProgBar widget 4 years ago
joseLuís 4c048ef625 rust: finish adding Notcurses methods. 4 years ago
joseLuís fa693a89c1 rust: add most Notcurses methods.
- fix some comments.
4 years ago
nick black 878842942d
TERMS.md: document block-drawing 4 years ago
nick black 6ca8949845 add kittyzapper PoC #1117 4 years ago
nick black 0578e86e02 introduce terminal-specific heuristics
Kitty conflates an RGB background specification that aligns
with the default background color with that actual background
color. This can result in translucent background when we're
expecting opaque ones. Detect kitty (strstr check of terminal
name for "kitty"), and if it's active, mark `bg_collides_default`
with the rgb of the default background color. For now, we assume
this to be (0,0,0), but we ought improve it by determining (or
setting, if that's impossible) the precise default bg color.
Closes #1117.
4 years ago
nick black 7df2c7cd04
ncdirect: use sgr0, properly align images 4 years ago
nick black e1b1654d1e
NEWS: mention ncdirect image render split 4 years ago
nick black 0ceb129125
document kitty properties #1117 4 years ago
nick black d3fc0db1ee
Merge branch 'master' of github.com:dankamongmen/notcurses 4 years ago
nick black 53d4dac427
drone: add ubuntu hirsute builder 4 years ago
joseLuís fd1b81c0f8 rust: add NcPixel methods.
- finish updating the functions.
4 years ago
joseLuís 0db4e48a6b rust: endianess updates for NcPixel & NcCell
- Update NcPixel functions, and their descriptions.
- Update NcPixel constructor.
4 years ago
joseLuís 6752741982 rust: add dynamic linesig control
- add new functions notcurses_linesigs_disable & notcurses_linesigs_enable.
- fix comments.
4 years ago
nick black 1fb4a66853
raster: fine-grained emits of op for default #1240 4 years ago
nick black 408004ee66
define fgop/bgop for fine-grained default color #1240 4 years ago
nick black 248dd1fff2
add dynamic linesig control #1228 4 years ago
nick black 99abcb5f07
cbreak_mode: move to input.c 4 years ago
nick black 41c2a75f9b
TERMS.md: some fatty did eat the cake 4 years ago
nick black 0920675db1
there are now three ways to hide a plane, sigh 4 years ago
nick black d1fdaf7614 view: add -t option for timeouts
When the -t switch is provided to notcurses-view, its
floating-point argument is the number of seconds for
which we delay after showing an image. When this is used,
the standard "press any key to continue" prompt is not
displayed, and indeed keybindings are not honored. This
can be used for a slideshow, or just for fullscreen display
involving no user interaction. It does not apply in the
case of -L for looping. Closes #1229.
4 years ago
nick black c0316ee96c view: document and parse -t time argument #1229 4 years ago
joseLuís 240b58d52b rust: update msrv in readme 4 years ago
joseLuís de56912cc4 rust: keep adding NcPlane methods & more
- new type NcResizeCb.
- new functions ncresizecb_safe & ncresizecb_unsafe.
- update NcPlaneOptions constructors.
- Improve & fix comments.
4 years ago
joseLuís 183d6473cd rust: continue adding NcPlane methods.
- add new module fade.
  - new type NcFadeCb.
  - move NcFadeCtx here.
- add TOC for NcPlane methods sections.
- fix & improve comments.
- remove deprecated ncplane functions.
4 years ago
joseLuís 45c01c95af update align doc comments #1234 4 years ago
joseLuís 84987b61a9 rust: refactor ncbox, ncalign; add NcPlane methods.
- wrap NCBOX* constants.
- new NcBoxMask type.
- new NCRESULT_MAX const.
- add NcPlane box & perimeter methods.
- move NcAlign to notcurses mod.
- update notcurses_align & test.
- improve comments.
- rustfmt.
4 years ago