Added extra buffer to store last command, made up arrow switch input buffers, implemented preview link control

# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
#
# On branch master
# Your branch is ahead of 'local/master' by 1 commit.
#   (use "git push" to publish your local commits)
#
# Changes to be committed:
#	modified:   TODO
#	modified:   config.h
#	new file:   lwl
#	modified:   lwl.1
#	modified:   main.c
#	modified:   state.c
#	modified:   state.h
#	new file:   test/16
#	modified:   test/8
#
