Using the `-http-server` argument will now start Browsh in HTTP Server
mode. It will accept request like this:
`curl brow.sh/http://news.ycombinator.com`
This will return a plain text version of the Hacker News front page,
with a width of 100 characters, with each line separated by a line
break.
Unit tests needed tab objects to be created.
Integration tests needed more max time for start up and to make sure
that the final tab doesn't get closed.
Adding, cycling, deleting. The width of the tab handle is currently
fixed to 20. And if there are more tabs than can fit in the tab bar then
the extra ones just dissapear off to the right, but they can still be
cycled to with CTRL-Tab.
The marks the end of feature development in preperation for a version
1 release.
Input boxes are currently only one line and to not properly wrap. So
textareas are also one line. TBC...
Also includes:
* First implementation of the DOM MutationObserver. This needs to have
an eye kept on it in case some websites trigger too mutatation
events. For now it doesn't seem too bad. Although strangely it seems
to stop on Youtube after about 15 seconds.
Text in the real browser only needs to be displayed when parsing with
the Text Builder in order to get the text's colour and z-index. Text
parsing should be done in frequently as it likely doesn't change often.
However graphics building of the current viewport is set to
automatically parse ever 250ms and it doesn't need to know anything
about text. So there's no point defaulting to having text on and hiding
it for every graphics frame.
This tweak has improved the perforance of the graphics parsing for small
frames (the same size as the viewport) from around 100ms to around 4ms!
There are still some curious and inexplicable CPU spikes when
scrolling... TBC
* CLI is now prepared for supporting multiple tabs.
* Refactored global vars into relevant files
* Now using real types in JSON sent to CLI
* Still doesn't fix integration tests
Instead of mirroring the browser's viewport, as if we had a camera over
the browser, the entire DOM is now sent in the frame. This means that
the CLI itself can scroll without having to wait for updates from the
webextension screenshotter.