I'm using Vala for Webkit (webkit2gtk-4.0) to display HTML content on WebView. Instead of showing the vertical scrollbars, I would like to break up the page into a smalled set of lines i.e. pagination. the attached picture will give an idea of the content i'm displaying.
Is there someway I can identify the number of lines when the content reaches the max page size and break up the content into the next page and so on. Is there a signal I can connect to which will help me do pagination. Here is the link to my code on GitHub: bookworm
The content has its own stylesheets and also images, so I cannot think of characters per line and no of lines per page to do the pagination.
Thanks in advance for any ideas.