comments: notes feature addition

* A note is a comment on a specific location in the record (e.g., Page 2), main
usecase being paper review before submission;
* Notes are extracted from record comments using regular expressions and a
collection of predefined markers;
* Notes are extracted at comment creation time and persisted in the database;
* Notes are displayed similar to comments, but in a different template (same
base template for both); comments and notes are understood as different views of
the same data.
* Notes can be hierarchic: Note on Page 1, Fig. 3;
* Feature can be disabled via CFG_COMMENTS_NOTES_ENABLED;
* Contains various comments UI fixes and static additions.

Signed-off-by: Adrian-Tudor Panescu <adrian.tudor.panescu@cern.ch>
comments: PDF viewer addition

* Adds a simple PDF viewer, available in the comments/notes page;
* PDF viewer is integrated with the commenting feature: comments can be added
on the previewed page, and notes can be viewed per page.
* Requires CFG_PATH_PDFTK and CFG_PATH_IMAGE_MAGICK_CONVERT.
* Refactors comments JavaScript;
* Feature can be disabled via CFG_COMMENTS_PREVIEW_ENABLED.

Signed-off-by: Adrian-Tudor Panescu <adrian.tudor.panescu@cern.ch>
comments: improvements and fixes

* Notes are extracted at DB insertion time, and not in the view anymore; this
allows for programatic comment insertion + note extraction;
* Fixes comments/ notes/ reviews JS: notably, fixes issues with record page tabs
switching; WIP.

Signed-off-by: Adrian-Tudor Panescu <adrian.tudor.panescu@cern.ch>
Merge pull request #2 from adrianp/notes

Notes & PDF feature addition