Kieran France Kieran France is a programmer for IDRSolutions in charge of there internal test suite. In his spare time he enjoys tinkering with gadgets and code.

New SVG View Mode Options

1 min read

Recently we have been enhancing the SVG output allowing you to have the SVG pages displayed in different ways. These options can be activated by either setting org.jpedal.pdf2html.viewMode as a system property with one of the following options or using this value as a key in a map, with one of the following as the value, to be passed into the extractor.

Single File Split Spread Mode

Activated with the value “singlefile_splitspread” without quotes. This mode works in a similar way to single file mode with the exception that the pages are split across two columns. The first page appears in the right column, all pages after this will be organised with the even pages on left and odd pages on right.

View of single file split spread mode

Single File Horizontal Mode

Activated with the value “singlefile_horizontal” without quotes. This mode works just like single file mode but the pages are position in a horizontal row rather than a vertical column.

View of single file horizontal mode

Single File Mode

Activated with the value “singlefile” without quotes. The single file mode extracts all pages into a single file arranged in a single vertical column. Each page is extracted as a single image, then added to a single SVG image to wrap them all together.

View of single file mode

Multi File Mode

Activated with the value “multifile” without quotes. This mode is used when no mode has been specified. Multi-file mode extracts each page as a single SVG file. By default each files will have a navigation bar below the image which can be used to navigate to other pages. This option is on by default.

View of multi-file output

Multi File Split Spread Mode

Activated with the values “multifile_splitspread” without quotes. This mode extracts pages so that they are divided into multiple files. The first page is extracted into its own file, appearing a page widths to the right. All other files will contain 2 pages (the first page on the left the next on the right) unless there are an even number of pages, then the final page has 1 page positions to the right. The pages are positioned so that when using the navigation bar (if option is activated) the layout will resemble that of an open book.

View of multi-file split spread mode

This post is part of our “SVG Article Index” in these articles, we aim to help you build knowledge and understand SVG.

Kieran France Kieran France is a programmer for IDRSolutions in charge of there internal test suite. In his spare time he enjoys tinkering with gadgets and code.

Enabling SVG Gzip Compression on Apache and NGINX

Gzip compression is a widely supported method of reducing the size of the content sent from a web server in order to improve the...
Leon Atherton
47 sec read

Leave a Reply

Your email address will not be published. Required fields are marked *

IDRsolutions Ltd 2019. All rights reserved.