Isogeometric analysis based on NURBS (Non-Uniform Rational B-Splines) as basis functions preserves the exact geometry but suffers from the drawback of a rectangular grid of control points in the parameter space, which renders a purely local refinement impossible. This paper demonstrates how this difficulty can be overcome by using T-splines instead. T-splines allow the introduction of so-called T-junctions, which are related to hanging nodes in the standard FEM. Obeying a few straightforward rules, rectangular patches in the parameter space of the T-splines can be subdivided and thus a local refinement becomes feasible while still preserving the exact geometry. Furthermore, it is shown how state-of-the-art a posteriori error estimation tech...