Add row joining.

When a menu entry is currently selected, pressing 'J' will cause the top
record to merge with the bottom record, similar to the join behaviour of
Vi. Joining a row will not activate it, allowing multiple joins to be
made in one trip to the dialog. Finally, the usage counter is inherited
from the left-most entry, as opposed to merging the counters. This was
done to prevent entries from remaining around for too long.

This commit also fundamentally changes the way the way the clipboard,
history, and GUI handle and store data. In particular, there is a
heavier emphasis on shared and reused references.
Allow editing to be on a per-entry basis.

Previously, entry editing could only be performed on the head element.
This change allows any selected element to be edited by pressing "e"
(just edit) or "E" (promote to current).
Always load clipboard value at startup.
Made Entry IDs portable.