QuickLook: Handle thumbnail generation

Read at most 1 KiB or 50 lines of a file and render the attributed string in a bitmap context.

The theme is set to Mac Classic to ensure a white background for best look when the previews are used as icons in Finder.

The user’s default fixed width font in size 4 is used. With this font size only around 7 lines are shown, so we need to make it smaller, but we probably want to scale down the result to allow fractional line heights.

A lot of code is copy/pasted from the QuickLook preview generator.
QuickLook: Check for cancellation

Add a bit of redundant code but it's useless to continue doing stuff if the request is cancelled by the user anyway.
QuickLook: Abort preview when type can't be determined
Set required version of ninja to 1.5
Detect abnormal exit when loading plug-ins

Currently we ask user about skipping it, but it might make sense to also add an uninstall option.
Avoid using Application Support for temporary file

Since the user’s library folder might be on a network we should probably avoid writing to it unless strictly necessary.
When clearing marked range, ensure pending range is also cleared

This fixes an issue with complex input managers.

Using Chinese pinyin input and entering ‘ci’ followed by ‘1’ to insert first glyph would insert the glyph (‘刺’) and then set the pending marked range (0-2), which would have caret end up in the middle of a multi-byte sequence.
Remove rmate from .gitmodules

We removed the actual sub-tree from the repository back in 2d4d4729d26ddef40db4bf09ed811a22e1875787.
Make ⌘F default to 'Selection' for multi-line selection

Previously using ⌘F with a multiline selection would automatically set the “in”
pop-up to “Document”. This is no longer the case, but can be brought back by
running: `defaults write alwaysFindInDocument -bool YES`
Use AXValue of OakChooser's cells for accessibility announcements

Previously we used [NSCell stringValue], which is not suited for cells with
custom implementation for AXValue accessibility attribute.
Improve accessibility for OakBundleItemCell

More specifically item's displayed keyboard shortcut or tab trigger is now
announced by VoiceOver.

Implementation of accessibilityAttributeValue:forParameter: returns nil for
some attributes. This is a hack to avoid doing tedious adjustments of certain
parameterized attributes (like AXStringForRange, AXAttributedStringForRange,
AXBoundsForRange, AXRTFForRange) for string AXValue that is extended (appended)
by extra information at its end in accessibilityAttributeValue:. To get an idea
how tedious this is (even though our case is a bit simpler by not *prepending*
anything before the AXValue, and not being an editable field), look at
OakLinkedSearchFieldCell. This looses the ability for the user to interact with
the text, but considering how seldom this will be used (if at all), for now
this seems acceptable.

This is needed because VoiceOver asks for the *StringForRange attributes and if
implemented, will never query AXValue (which is where our custom behavior is).

In the future when tables will be migrated from cell-based to view-based ones,
the tab trigger or shortcut could be a separate NSView, which would probably
allow for much more elegant solution to this problem.
Implement basic accessibility for OakKeyEquivalentView

I experimented a lot with different combination of attributes, this one works
reasonably well compared to the others (even though it is less feature
complete). I may revisit experimenting with it at some later point.
Remove unused code

This should have been removed in 36cfb177a5dcb5c0aef25ee0cfe8a052ba9c7486.
Don’t read bundle sources or signing keys from disk

This was to allow third party indexes but we newer got anywhere with that, so it’s just unnecessary code complexity and the potential for problems if the files on disk are wrong.
Add file type extension to document backups
Only report privileged helper tool outdated when a new one exists

This is so that we can use the privileged helper tool from tests, assuming it has already been installed.
Do not destroy shared authorization rights

Each time we used an authorization right in the privileged helper tool, TextMate would lose the right since the helper tool destroyed it after use.
Improve lifetime of the authorization wrapper used by mate

While the memory was released during exit, we didn’t free the authorization right, which is shared between multiple processes, unsure if that would actually leak any resources.
Make the Find and HTML window switch back to a Space TM is actually in
Make CoreText manage the tabs

Rather than putting tabs in their own node, leave them in the text nodes and allow core text to handle the size. This fixes the issue with using tabs in right-to-left text.