.travis.yml: Lock astroid to version 1.1.0

astroid is a library used by pylint. Since astroid 1.2.0 was released,
our `make check-pylint` on Travis fails with `StopIteration` and the
below stack trace while checking tests/test_ocr.py. See bug #42 in the
astroid bug tracker[1].

    File "/usr/local/bin/pylint", line 9, in <module>
      load_entry_point('pylint==1.1.0', 'console_scripts', 'pylint')()
    File "/usr/local/lib/python2.7/dist-packages/pylint/__init__.py", line 21, in run_pylint
      Run(sys.argv[1:])
    File "/usr/local/lib/python2.7/dist-packages/pylint/lint.py", line 1040, in __init__
      linter.check(args)
    File "/usr/local/lib/python2.7/dist-packages/pylint/lint.py", line 626, in check
      self.check_astroid_module(astroid, walker, rawcheckers, tokencheckers)
    File "/usr/local/lib/python2.7/dist-packages/pylint/lint.py", line 712, in check_astroid_module
      walker.walk(astroid)
    File "/usr/local/lib/python2.7/dist-packages/pylint/utils.py", line 697, in walk
      self.walk(child)
    File "/usr/local/lib/python2.7/dist-packages/pylint/utils.py", line 694, in walk
      cb(astroid)
    File "/usr/local/lib/python2.7/dist-packages/pylint/checkers/base.py", line 246, in visit_function
      self._check_redefinition(node.is_method() and 'method' or 'function', node)
    File "/usr/local/lib/python2.7/dist-packages/astroid/scoped_nodes.py", line 670, in is_method
      return self.type != 'function' and isinstance(self.parent.frame(), Class)
    File "/usr/local/lib/python2.7/dist-packages/logilab/common/decorators.py", line 155, in __get__
      val = self.wrapped(inst)
    File "/usr/local/lib/python2.7/dist-packages/astroid/scoped_nodes.py", line 536, in _function_type
      _type = _infer_decorator_callchain(node)
    File "/usr/local/lib/python2.7/dist-packages/astroid/scoped_nodes.py", line 501, in _infer_decorator_callchain
      result = current.infer_call_result(current.parent).next()
    StopIteration

[1]: https://bitbucket.org/logilab/astroid/issue/42/pylint-with-astroid-120-fails-with
Refactor: Region: Change internal representation of `Region`

`Region` is now represented internally as (x, y, right, bottom) rather than
(x, y, width, height).  This gives us a way to represent regions which are
infinite, such as the region x < 5, y > 10.  This seems to be a more
natural representation anyway as most of out methods and uses use right and
bottom.

This is not intended as an externally visible change, although some details
may leak through the cracks.  These include:

* The string returned by `__repr__` lists right and bottom rather than
  width and height.  This is necessary as `repr` should be unambiguous.
* If you use subscripting to get at the internal representation of the
  `Region` (e.g. `region[2:]`) this will now return `right` and `bottom`.
API: Region: Add Region.ALL

`Region.ALL` represents the entire 2D frame from -∞ to +∞ in both the x
and y directions.  This is useful to pass to functions that take a
`region=` parameter to say that we want the whole frame considered.  This
is really quite nice as it behaves as you might expect with functions
such as `contains()`, `intersect()` and `extend()` without any special
casing.

In the 0.20 release the only public function which took a `region=`
parameter was `ocr()`.  In this case the parameter defaulted to `None`
meaning the whole frame.  It now defaults to `Region.ALL` with the same
meaning as before.  Passing `region=None` to `ocr()` is deprecated so in
the future we can change its meaning to mean the empty region consistent
with the return value of `Region.intersect()` and the region parameter
of `TextMatchResult` as returned from `match_text()`.
API: Region: Make intersect commutative and associative

`intersect` returns None if the two given regions don't intersect.  By
making `intersect` a `@staticmethod` `None` can be passed as either
argument rather than having to be the second.  This allows constructions
such as:

    Region.intersect(Region.intersect(a, b), c)

or

    reduce(Region.intersect, [a, b, c], Region.ALL)

to behave consistently if any of `a`, `b` or `c` are either `None` or
don't overlap with any of `a`, `b` or `c`.

`Region.intersect` has not yet been in a public release so this is not
considered an API break.
API: Region: Add Region.translate

This is a convenience function implemented to help with the implementation
of passing `region=` to `stbt.match()`
Refactoring: Factor out loading templates

In preparation for adding `stbt.match`.

Internally we now pass around an `_AnnotatedTemplate` object rather than
an `numpy.ndarray` so we can attach the template name and any other
information we wish to. This tidies up an number of bits of code and
should make them more robust to changes in the future.
stbt.py: Refactor drawing MatchResults on frames

We can re-use this when adding the `stbt.match()` API.
Add `stbt.match`
WIP: API: Add region parameter to match

TODO:
* Documentation
* Tests