Merge branch 'stable-candidate-july-2013' into stable

This is the version of integration with the graph refactor merged.  It
is being merged into stable to make applying bugfixes to both stable and
integration as easy as possible.  It has been tested with the practical
by several people, so has no regressions to the best of our knowledge.
Fix renaming in Controller.insert_graph

We need to extend_fresh the renamings before passing them to
rename_bang_graph, to make certain there are no clashes.

integration has a fix in rename_bang_graph, but this is the safer fix,
more suitable for stable.
Merge branch 'pasting-hotfix' into integration

Technically, this problem is already solved in this branch, but merging
now will reduce conflicts later.