Move FS utility funcs from OFB to a separate file
Add "Reveal Current Document" command

This reveals the current document in the file browser, by expanding directories to reach it, rather than changing the root directory of the browser.
Ensure DisplayName doesn’t return nil

Although I don’t know when it would return nil, issue #649 indicates that it sometimes does. We now fallback on the full URL in this case (and returning ‘«nil»’ if the url itself is nil). This should give a hint about what file system entries would fail to return a display name.
Make OakSavePanel API block-based
Remove unused method
Make DocumentOpenHelper API block-based
Remove unused method
Remove duplicate of public symbol
Add missing const qualifier
Clicking a ‘find all’ result would be handled twice

Normally this wouldn’t be noticed, as the second action would do the same as the first (go to the result in the associated project window), but when there was no project window a new window opens (to show the result), and that would be done twice.

This fixes issue #281.

There is still an issue with successive selections for the “no project window” situation, as each time, a new window is opened, rather than reuse the first one that opened.
Watch if we leak ProjectLayoutView objects
Use factory method for DocumentController objects

We regularly iterate through all open windows and test if these are document controller windows. It will be easier to let the document controller class (or application delegate) manage a list of open document windows, as we anyway need some sort of owner with ARC (currently the instances own themselves and give up ownership in windowWillClose: which cause them to be released).
Use to_s instead of UTF8String

This has the advantage of not causing a crash if the string object is nil.
Public API to make HTML output windows reusable
Make HTML output window a panel

This allows the main (document) window to handle menu keys (which are not handled by the HTML output window controller).
Let buffer_t[size()] return empty string

Previously this was undefined, yet some code could trigger it. E.g. asking for the OS dictionary pop-up with an empty document.

I wasn’t sure if this should actually be allowed but decided that since operator[] returns strings, the “end of buffer” code point is easily defined as an empty string makes the code using this API simpler.
Only grab ‘untitled’ token for user-created documents

We may use OakDocumentView in a context where we don’t immediately assign it a document, or we wish to “overwrite” its default document with an untitled document that we create.

If the document view holds its own untitled document then the global counter includes that and the one we create is one higher than expected.
Custom named documents don’t occupy an untitled counter

Previously if the custom name was set before the display name was requested, it would not allocate an untitled counter, but if set later, it would (effectively) not release the counter already allocated.
Add ‘uuid’ to txmt URL scheme

This can be used to link to the “current document” even if that document has no path. Previously this was done by leaving out the ‘url’ parameter, which made it target the frontmost document — using ‘uuid’ is a more robust way to achieve the same.

A command can read the TM_DOCUMENT_UUID environment variable for the current document’s identifier.
Let window title include project folder name

This is only if the project directory is actually set at the time the default properties are expanded, so presently this has no effect (but will when TextMate sets a default value for the projectDirectory variable).