gles: Switch default framebuffer destinations properly

Make _cairo_gl_context_bind_framebuffer handle different types of GLES
surfaces properly Since, the multisampling setting of a surface never changes
in for GLES, so the first thing we do when setting the destination is to
ignore the requested multisampling setting. This simplifies all
following logic.
directfb: Correctly chain up map-to-image/unmap to the image backend

Fixes the infinite recursion reported by jojo.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
traps: Ensure that we correctly clip when using multiple clip boxes

We need to be more careful when trying to discard a clip to be sure that
it is truly not required. In particular, we need to not throw a way a
clip region when it has more than one box intersecting the mask.

Reported-by: Alexander Larsson
Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=697357
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
xlib: Unlike the visual when destroying it

Otherwise we leave dangling pointers in the visual list, leading to
memory corruption when using low bitdepth servers.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
test: Expand testing of caps for fine strokes
test: Extend testing of joins for fine lines
trace: Improve operand emission

In particular fixing up a couple of corner cases in emitting the right
instructions for scaled-fonts and patterns.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
test: Fix typo in sample_horizontal to use horizontal, not vertical.

Triggers the following warning during build:

sample.c:61:1: warning: ‘horizontal’ defined but not used
 [-Wunused-function]

Signed-off-by: Bryce Harrington <b.harrington@samsung.com>
Merge branch 'master' of git://anongit.freedesktop.org/git/cairo