4teamwork/ftw.book — pull request #53 by jone (2014-03-10 13:34:07+00:00)
Title: Improve book internal links

:construction:
Includes / bases on #52

- **TinyMCE:** Configures TinyMCE properly, so that blocks and chapters used within a book are referenceable and chapters may be opened in the TinyMCE reference browser.

- **Reader:** Improve the reader view to detect book internal links and scroll to the link target within the reader view. The jumping behaves like the links in the left-hand navigation: when the target is already loaded it scrolls to the content, otherwise the reader is reloaded on the target. This is necessary because we don't always know how much content is between the already loaded an the link target and we try to load as few as possible but as much as necessary.

- **PDF:** The PDF / LaTeX part is extended so that book-internal links are rendered as anchors within the PDF. The anchor has a footnote with the target page number, so that it is usable on printed versions too. Internal links are only created when the target is expected to be included in the PDF. If a chapter is exported which has content to another chapter (which is not exported), the links are represented as normal links, linking to the content on the website.

--

**PDF:**
![bildschirmfoto 2014-03-10 um 14 33 04](https://f.cloud.github.com/assets/7469/2373934/97026778-a858-11e3-9e19-ddcda314cdae.png)

--

/ @maethu