Mercurial > hgrepos > Python2 > PyMuPDF
comparison mupdf-source/docs/guide/what-is-mupdf.md @ 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 |
comparison
equal
deleted
inserted
replaced
| 1:1d09e1dec1d9 | 2:b50eed0cc0ef |
|---|---|
| 1 # What is MuPDF? | |
| 2 | |
| 3 MuPDF is an open source software framework for viewing, converting, and | |
| 4 manipulating PDF, XPS, and E-book documents. There are viewers for various | |
| 5 platforms, several command line tools, and a software library for building | |
| 6 tools and applications. | |
| 7 | |
| 8 ## Formats | |
| 9 | |
| 10 As you can tell by the name, we support reading PDF files. But that's not all! | |
| 11 | |
| 12 - PDF | |
| 13 - XPS and OpenXPS | |
| 14 - EPUB (DRM-free 2.0, limited support for 3.0) | |
| 15 - Mobipocket (MOBI) | |
| 16 - FictionBook 2 (FB2) | |
| 17 - ComicBook (CBZ and CBT) | |
| 18 - Images (TIFF, JPEG, PNG, etc) | |
| 19 - SVG (a limited subset only) | |
| 20 | |
| 21 ## Viewers | |
| 22 | |
| 23 There are many different viewer applications that build on the MuPDF library | |
| 24 for a large variety of platforms. | |
| 25 | |
| 26 ### Linux, Windows, and BSD | |
| 27 | |
| 28 For Linux and Windows there are two viewer applications. | |
| 29 The main viewer (mupdf-gl) has many features such as a table of contents | |
| 30 sidebar, full unicode search, annotation editing, redaction, etc. | |
| 31 On systems where this viewer cannot be built, we still support the older | |
| 32 legacy viewer which does not have as many features. | |
| 33 | |
| 34 <dl> | |
| 35 <dt><a href="../tools/mupdf-gl.html">mupdf-gl</a> | |
| 36 <dd>The main viewer program that sports the most features. | |
| 37 <dt>mupdf-x11 | |
| 38 <dd>The legacy X11 viewer that works everywhere. | |
| 39 <dt>mupdf-win32 | |
| 40 <dd>The legacy win32 viewer for Windows. | |
| 41 </dl> | |
| 42 | |
| 43 ### Android | |
| 44 | |
| 45 Android currently has two different viewers with varying degrees of complexity: | |
| 46 | |
| 47 <dl> | |
| 48 <dt><a href="https://play.google.com/store/apps/details?id=com.artifex.mupdf.viewer.app">MuPDF viewer</a> | |
| 49 <dd>A high performance PDF viewer with a smooth and polished interface. | |
| 50 <dt><a href="https://play.google.com/store/apps/details?id=com.artifex.mupdf.mini.app">MuPDF mini</a> | |
| 51 <dd>An example of how to create a PDF viewer with the least amount of code. | |
| 52 </dl> | |
| 53 | |
| 54 ### Web Browser | |
| 55 | |
| 56 There's a simple | |
| 57 <a href="https://mupdf.com/wasm/demo/?file=/docs/mupdf_explored.pdf">WebAssembly demo</a> | |
| 58 that runs MuPDF in the browser. | |
| 59 | |
| 60 There's also a commercial license only <a href="https://webviewer.mupdf.com/">MuPDF WebViewer</a> product. | |
| 61 | |
| 62 ### Third party viewers | |
| 63 | |
| 64 Here's a non-exhaustive list of other non-affiliated open source projects that use MuPDF: | |
| 65 | |
| 66 - <a href="https://www.sumatrapdfreader.org/download-free-pdf-viewer">SumatraPDF</a> for Windows | |
| 67 - <a href="https://pwmt.org/projects/zathura/">Zathura</a> for Linux | |
| 68 - <a href="https://repo.or.cz/llpp.git">llpp</a> | |
| 69 | |
| 70 ## Command Line | |
| 71 | |
| 72 The command line tools are all gathered into one umbrella command: mutool. | |
| 73 This swiss army knife has a lot of sub-commands for performing different | |
| 74 tasks on PDF documents. | |
| 75 | |
| 76 For rendering and converting documents use these two commands: | |
| 77 | |
| 78 <dl> | |
| 79 <dt><a href="../tools/mutool-draw.html">mutool draw</a> | |
| 80 <dd>This is the more customizable tool, but also has a more difficult set of command line options. | |
| 81 It is primarily used for rendering a document to image files. | |
| 82 <dt><a href="../tools/mutool-convert.html">mutool convert</a> | |
| 83 <dd>This tool is used for converting documents into other formats, and is easier to use. | |
| 84 </dl> | |
| 85 | |
| 86 A highlight of some other tools useful for working with PDF documents: | |
| 87 | |
| 88 <dl> | |
| 89 <dt><a href="../tools/mutool-show.html">mutool show</a> | |
| 90 <dd>A tool for displaying the internal objects in a PDF file. | |
| 91 <dt><a href="../tools/mutool-extract.html">mutool extract</a> | |
| 92 <dd>Extract images and embedded font resources. | |
| 93 <dt><a href="../tools/mutool-clean.html">mutool clean</a> | |
| 94 <dd>Rewrite PDF file. Used to fix broken files, or to make a PDF file human editable. | |
| 95 <dt><a href="../tools/mutool-create.html">mutool create</a> | |
| 96 <dd>Create a new PDF file from a text file with graphics commands. | |
| 97 <dt><a href="../tools/mutool-merge.html">mutool merge</a> | |
| 98 <dd>Merge pages from multiple input files into a new PDF. | |
| 99 <dt><a href="../tools/mutool-poster.html">mutool poster</a> | |
| 100 <dd>Divide pages of a PDF into pieces that can be printed and merged into a large poster. | |
| 101 </dl> | |
| 102 | |
| 103 And finally, there is a tool for doing anything you can imagine: | |
| 104 | |
| 105 <dl> | |
| 106 <dt><a href="../tools/mutool-run.html">mutool run</a> | |
| 107 <dd>A tool for running Javascript programs with access to the MuPDF library functions. | |
| 108 </dl> | |
| 109 | |
| 110 ## Library | |
| 111 | |
| 112 The library is written in portable C. | |
| 113 | |
| 114 To learn more about the C interface, read the <a href="../cookbook/mupdf-explored.html">MuPDF Explored</a> book. | |
| 115 | |
| 116 ### Javascript | |
| 117 | |
| 118 There is a library available to use MuPDF from Javascript and Typescript, | |
| 119 powered by WebAssembly. You can use this library to build applications that run | |
| 120 in a web browser, or that run server side using Node or Bun. | |
| 121 | |
| 122 The Javascript library is available as a module on NPM. | |
| 123 | |
| 124 ### Java | |
| 125 | |
| 126 There is also a Java library, which uses JNI to provide access to the C library. | |
| 127 | |
| 128 The Java classes provide an interface very similar to that available in the | |
| 129 <a href="../tools/mutool-run.html">mutool run</a> command line tool. | |
| 130 This Java library also powers the Android viewers. | |
| 131 | |
| 132 If you want to build an application for Android, you have several options. You | |
| 133 can base it off one of the existing viewers, or build a new app using the Java | |
| 134 library directly. | |
| 135 | |
| 136 ### Python | |
| 137 | |
| 138 The popular [PyMuPDF](https://pypi.org/project/PyMuPDF/) library makes it trivial to use MuPDF from Python! |
