Made window positioning relative rather than X/Y absolute position.
Add argument parsing capabilities and help usage. Updated examples to show how to pass arguments from command line to internall call to main_loop function.
Add quiet and verbose mode. Error messages are captured and displayed under the layout.
Window title will be split over multiple lines if window is too narrow. It can also be cropped using option -c.
To keep a clean screen compared to absolute coordinate mode, terminal size change is captured.
The input/sleep callback must be named update (regression warning)
Fixes regarding text position in window (may change rendering)
Added a sanity check that the file was not run as a script.
Wrong coordination of move_up and col_right will not screw display.
Add 2 level option parsing to choice.sh example: 1st level for choice, 2nd level for simple_curses.sh main function
Fixes:
Many functions were >> BSC_BUFFER in sub-main functions.This is redundant with main >> BSC_BUFFER. They have been removed, which result in cleaner code.
Many cursor position changes were exposed to a movement of 1 if the argment was 0. This could lead to last char beeing overwritten by right border
First character on the left is displayed against the border (tput cuf 0 shifts one cell)
Fix tedious/bug-prone reading of multibyte keys (arrows) in choice.sh
Maintenance:
Simplify append_function to avoid writing a file.
Simplify append_command function, now uses bsc__append.
Simplify append_file, now uses "append_command cat $1"
Inlined small functions called only one time
append_command and append_function do not rely any more on a temporary file
New:
Fixes:
Maintenance: