Fixed some visual issues with the chunk highlighter and diff margins.

Upon loading the diff viewer, the chunk highlighter would appear as a
little square in the bottom-left of the page, taking up space. This was
caused by an initial highlight call on the diff_index, which it wasn't
really able to highlight, so it fell back to being in a default
position. We no longer try to highlight nothing.

When it was highlighting, it wouldn't track the element it was supposed
to highlight if elements above it changed size. This was particularly
noticeable with image diffs. The highlighter would stay in its prior
position.

This was due to the highlighter living in the #diffs element, but now it
lives in the .diff-container. To make this work, I had to separate out
the rules and responsibilities of diff-container into diff-container and
diff-box elements.

While here, I fixed the margins between diffs so they're consistent
throughout the page.
Change the min-height on labels to be 16px (from 15px).

Our edit icon is now 16px tall, not 15. Trivial change.
Move i18n building into a script to fix deployment issues.

For some reason, doing a 'fab deploy' results in the django import in
Build18N to fail. The code doesn't seem to be running with the
PYTHONPATH we'd expect.

This change moves the i18n building logic out into a script, just like
media building. The script is then able to run in the context of the
virtualenv, and not in whatever screwed up environment the class is
otherwise running in.
Add support for image diffs.

This greatly enhances the ImageReviewUI to support showing diffs between
images. When generating a binary diff between images, the Review UI will
provide several modes for viewing how the images changed.

The first mode is the Two-Up mode, which just shows the two images
side-by-side.

The second is the Difference mode, which shows a color-based difference
between the images. It's useful for spotting what pixels actually
changed between images, and what remained the same.

The third is the Split mode, which layers the two images and provides a
slider for showing how much of the modified image is visible, vs. the
original. The user can slide back-and-forth to see what changed between
the images.

The fourth is the Onion Skin mode, which layers the two images and
provides a transparency slider. This slider will alter the transparency
of the modified image. This makes it easy to see what pixels may have
moved, or other subtle changes to the image.

All modes allow commenting, and all comments are displayed on all modes.
The comment thumbnail for image diffs will show the commented regions of
the original and modified images side-by-side (similar to the Two-Up
mode).
Fix js-tests.

Ripping out the startsOpen behavior invalidated some of the tests. I've removed
the special case tests and added a call to the generic editCountTests() method.
Trivial change.
Call success and update draft field when setting the close description.

The changeDescription field works kind of strangely when a review request is
closed. Rather than setting a field in a draft and asking it to save, it calls
close() with the new text. Unfortunately, the changeDescription field in
reviewRequest.draft was getting out of sync (since it wasn't updated), and the
success callback was never triggered. This fixes both those issues.

Testing done: Used in conjunction with my markdown change.
Reviewed at https://reviews.reviewboard.org/r/4504/
Fix ReviewBoxListView iteration over changedescs.

Our markup for change description boxes is a little weird, where we end up with
multiple nested elements with the 'changedesc' class. ReviewBoxListView was
iterating over everything with that class to set up the collapsable boxes,
which worked okay, but as soon as I tried to add something else to it, things
got weird.

This changes ReviewBoxListView.el to point to #content, and then iterates only
over the children.

Testing done: Used in conjunction with the markdown change.
Reviewed at https://reviews.reviewboard.org/r/4505/
Pull in 3rd-party libraries for markdown support.

This adds the latest versions of Google Code Prettify (a javascript syntax
highlighter) and marked.js (a markdown parser/renderer). These are not yet used
for anything, or even included in the pipeline definitions in settings.py.
Make long-form text entries use markdown formatting.

There are several places in Review Board where users can enter long-form text:
the review request description and testing done fields, comments, review body
top and bottom, and change descriptions. Until now, all of these have just been
preformatted text. This change integrates client-side markdown rendering for
these fields.

Because old text wasn't written with any feedback for what it would look like
as markdown, this functionality is gated for only new entries in the database.
A new boolean field called "rich_text" has been added to everything that could
potentially be rendered. The evolutions ensure that all the old models have
this set to false, and new ones will have it set to true.

The way this works on the client side is that fields in the HTML are annotated
with a data-rich-text attribute, which will be either true or false based on
the rich_text field in the model. The various views which use these have been
changed to call RB.formatText(), which will handle the hard work of formatting
the text using marked.js if appropriate, as well as handle the special stuff we
need to have it work with the inline editor.

The style throughout is done to keep things visually pretty close to plain
text, but with the nice benefits of emphasis, code samples, tables, lists, etc.
One extreme example of this is that the font size is consistent throughout,
even including headings.

One thing which is left to do for this is to render the markdown text for use
in HTML emails. I'm going to do that as a separate change because it's likely
to be pretty big itself, and I'll need to do some research on rendering
github-flavored markdown in python.

This change is based loosely on Greg Wang's change from
https://reviews.reviewboard.org/r/3892/

Testing done:
- Checked that old review requests/comments were not rendered with markdown.
- Tested using markdown syntax in each of the different rich text boxes.
- Tested that rendering occured for each box after page load, and that things
  re-rendered after the values were changed.
- Verified that bugs and review requests were properly linkified.
- Tried inserting HTML (especially <script> tags) and saw that it was escaped
  properly.

Fixes bugs 2093, 2098
Don't allow exceptions to bubble up when failing to fetch commits/branches.

It looks like sometimes the github API will return "not found". I'm not sure if
this is due to API outages or ownership issues (I haven't done too much
digging), but we should catch this case and log, rather than just letting the
failure bubble up to email Christian.

Trivial change.

Testing done: Ran unit tests.
LDAP: Use fully qualified DN for authentication

Use the fully qualified DN with LDAP bind for user authentication. Currently a
DN built with the base DN and uid is used. This did not work on our company
LDAP server.

Testing done: Code running successful with our company LDAP server.

Fixes bugs 2836, 3069
Reviewed at https://reviews.reviewboard.org/r/4488/
Merge branch 'release-1.7.x'