…he copyright has been transferred to Erlang Solutions Ltd. The Makefile now use rebar exclusively.
'undefined' instead of  so that it is clear that the argument that is sent isn't a argument list (like the ones used in apply/3 e.g.). The argument is sent as-is to the driver and this should clarify a bit.
created every time a new character is retrieved.
Updated rebar.config accordingly
…efile. The *.so file would be put in the "wrong" place but the same convention as rebar is used and the *.so file is put in priv/
…with the behaviour gen_server. Also cleaned up some unnecessary code lines and made things more readable.
…lity. Added a new example.
…the keys easier
The input is now done by ncurses itself. The driver starts a thread that will do getch() continuously and send a message back to Erlang when it has a character. meanwhile if a process asks for a char (cecho:getch()) it will block by first sending a message to the cecho_srv process and "register" itself as waiting and then as soon as a key input is read from the driver it will be sent to it. If a message is received from the port and no process is waiting for the character then the message will be discarded. If a process tries to do cecho:getch() at the same time as another one is already blocking the process that called cecho:getch() last will be killed. If special characters need to be captured then cecho:keypad/2 must be used to enable keypad mode. NOTE: erl must be started with +A <N> where N is a number (probably above 40, try e.g. 50 or above) AND the flag -noinput must be given to stop the erlang shell from reading input (and thus competing) with cecho. To test the new feature run cecho_example:input() as follows: $> pwd /home/mazen/dev/repos/cecho $> erl -pa ../cecho/ebin/ -noinput -eval 'cecho_example:input(),halt().' +A 50 $> Use 'q' to quit.
…e taken a window argument before but was not since I hadn't implemented windows yet. Leaving the old functions which don't take a window for easier access to stdscr.