Fix regressions caused by the recent editor changes.

Some of my recent work made assumptions about elements that exist on a
page in ReviewRequestEditorView. While fixing this, I realized there's a
lot of work we're doing on those pages we don't need to do.

This change conditionalizes a lot of the logic to only work with fields
and other review request editable stuff if we're on a page with those
elements. We could get more fine-grained, but this is enough to simplify
review UIs a fair amount and to fix the breakages.

It also fixes loading images in a Markdown field. Since an image could
load after we render (unless it's in cache), it could end up messing
with the sizes. Now we call resizeLayout when any contained image loads.

There's also fixes to make unit tests pass. The structure of the
template better matches the real structure of the review request, at
least close enough for logic to work.
Re-enable an important optimization in the Myers diff algorithm.

There's an optimization we turned off many years ago in MyersDiffer
that results in excessively long diff times for very large files. This
was the source of some huge CPU spikes and memory usage, especially if
users dogpiled on the review request.

We turned this off in the early days of Review Board, and the commit
message was vague about why. It seems that it resulted in a breakage
with some diffs. I have not been able to reproduce this, and this part
of the algorithm matches GNU diff's perfectly. I know we've made other
fixes to the differ since then, so most likely, the breakage was due to
one of those.

To ensure compatibility with older diffs, I've bumped the diff compat
version. If it turns out that this does break things, we can easily
revert it, and test manually with any diffs by setting the stored compat
version in the database per-diffset.

This gets some large, more insane diffs from 1-2 minutes down to around
10 seconds.
Merge branch 'release-1.7.x'
Replace Lucene search for Review Requests with Haystack and Whoosh.

Full-text search with Lucene is a hassle to set up. Haystack and Whoosh are
pure python so it's easy to include them with Review Board and have full-text
search available out of the box. Regular maintenance of the search index is
still required for the search function to return up-to-date results.

These Review Request fields are indexed : id, summary, description, commit_id,
testing done, bugs, author (submitter's full name), submitter (username),
filenames of the files in the diffs (diff content is not indexed).

Testing Done:
* Enabled and disabled search in General Settings and changing index file path
  and results per page, followed by rebuilding the index.
* Search using the following fields:
      id, summary, description, testing done, bugs, author, submitter,
      diff filenames.
* Built and inspected Sphinx docs.
* Built and updated the index through rb-site.
* Unit tests passed.

Reviewed at https://reviews.reviewboard.org/r/4935/

Obsoletes bugs 2021, 2544, 2755, and 3095