diff mupdf-source/docs/tools/mutool-convert.rst @ 2:b50eed0cc0ef upstream

ADD: MuPDF v1.26.7: the MuPDF source as downloaded by a default build of PyMuPDF 1.26.4. The directory name has changed: no version number in the expanded directory now.
author Franz Glasner <fzglas.hg@dom66.de>
date Mon, 15 Sep 2025 11:43:07 +0200
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mupdf-source/docs/tools/mutool-convert.rst	Mon Sep 15 11:43:07 2025 +0200
@@ -0,0 +1,52 @@
+.. _mutool_convert:
+
+mutool convert
+==========================================
+
+The ``convert`` command converts an input file into another format.
+
+.. code-block::
+
+	mutool convert [options] file [pages]
+
+``[options]``
+	Options are as follows:
+
+	``-p`` password
+		Use the specified password if the file is encrypted.
+	``-o`` output
+		The output file name. The output format is inferred from the output filename. Embed ``%d`` in the name to indicate the page number (for example: "page%d.png"). Printf modifiers are supported, for example "%03d". If no output is specified, the output will go to ``stdout``.
+	``-F`` output format (default inferred from output file name)
+		- raster: ``cbz``, ``png``, ``pnm``, ``pgm``, ``ppm``, ``pam``, ``pbm``, ``pkm``.
+		- print-raster: ``pcl``, ``pclm``, ``ps``, ``pwg``.
+		- vector: ``pdf``, ``svg``.
+		- text: ``html``, ``xhtml``, ``text``, ``stext``.
+	``-b`` box
+		Use named page box (``MediaBox``, ``CropBox``, ``BleedBox``, ``TrimBox``, or ``ArtBox``).
+	``-A`` bits
+		Specify how many bits of anti-aliasing to use. The default is ``8``.
+	``-W`` width
+		Page width in points for EPUB layout.
+	``-H`` height
+		Page height in points for EPUB layout.
+	``-S`` size
+		Font size in points for EPUB layout.
+
+	``-U`` filename
+		User CSS stylesheet for EPUB layout.
+
+	``-X``
+		Disable document styles for EPUB layout.
+
+	``-O`` comma separated list of options for output format.
+		See
+		:doc:`/reference/common/pdf-write-options`
+		and
+		:doc:`/reference/common/document-writer-options`.
+
+``file``
+	Input file name. The file can be any of the supported input formats.
+
+``[pages]``
+	Comma separated list of page ranges. The first page is "1", and the
+	last page is "N". The default is "1-N".