Zathura (document viewer)

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search
Zathura
Screenshot of zathura viewing a PDF file in Arch Linux.
Screenshot of zathura viewing a PDF file in Arch Linux.
Original author(s)Moritz Lipp, Sebastian Ramacher
Developer(s)pwmt[1]
Initial releaseSeptember 18, 2009 (2009-09-18)
Stable release
0.4.3 / December 22, 2018[2]
Repository Edit this at Wikidata
Written inC
Operating systemUnix-like
TypeDocument viewer
Licensezlib License[3]
Websitepwmt.org/projects/zathura/

Zathura is a free, plugin-based document viewer. Plugins are available for PDF (via poppler or MuPDF), PostScript, DjVu, and EPUB. It was written to be lightweight and controlled with vi-like keybindings. Zathura's customizability makes it well-liked by many Linux users.[4]

Zathura has a mature, well-established codebase and a large development team.[5] It has official packages available in Arch Linux,[6] Debian,[7] Fedora,[8] Gentoo,[9] OpenBSD,[10] OpenSUSE,[11] Source Mage GNU/Linux,[12] Ubuntu,[13] and an unofficial macOS package provided by MacPorts.[14]

Zathura was named after the 2005 film Zathura: A Space Adventure.[15]

History[edit]

Development on Zathura began on 12 August 2009.[16] On 18 September 2009, version 0.0.1 was announced to the Arch Linux community.[17]

Zathura has been an official Arch Linux package since April 2010.[18] Same year, by the end of July it was imported into Source Mage test grimoire.[19] It has been an official Debian package since at least 2011, as part of Debian Squeeze.[20]

Features[edit]

Zathura automatically reloads documents. When working in compiled documents such as those written in LaTeX, Zathura will refresh the output whenever compilation takes place. Zathura has the option of enabling inverse search (using "synctex").[21][22]

Zathura can adjust the document to best-fit or to fit width, and it can rotate pages. It can view pages side-by-side and has a fullscreen mode. Pages can also be recolored to have a black background and white foreground.

Zathura can search for text and copy text to the primary X selection. It supports bookmarks and can open encrypted files.

The behavior and appearance of Zathura can be customized using a configuration file. Zathura has the ability to execute external shell commands. It can be opened in tabs using tabbed.[23]

Forward/Inverse Search with Kile[edit]

Modifying the python codes in https://texwiki.texjp.org/[24], with the file name 'zathuraforward.py',

#!/usr/bin/env python
# -*- coding: utf-8 -*-

import sys
import re
import subprocess

if __name__ == '__main__':
    m = re.match(r'file:(\S*)#src:(\S*) (\S*)', sys.argv[1])
    if m:
        pdf = m.group(1)
        line = m.group(2)
        tex = m.group(3)
	args = line + ':0:' + tex
    subprocess.call(['zathura', '--synctex-forward', args, pdf])

followed by

$ chmod +x zathuraforward.py
$ sudo cp zathuraforward.py /usr/local/bin

Zathura is ready for the forward search. In Kile → Setting → Configure Kile → Build → Forward pdf, set the viewer command to be zathuraforward.py with the option '%target', which will pass the line number, tex file name, and pdf file name to Zathura through the python script. To get inverse search done, add following two lines to ~/.config/zathura/zathurarc

set synctex true
set synctex-editor-command "kile --line %{line} %{input}"

See also[edit]

References[edit]

  1. ^ "Programs With Movie Titles".
  2. ^ "Tags - pwmt / zathura". Retrieved 19 October 2018.
  3. ^ "LICENSE · master · pwmt / zathura". Retrieved 2017-06-24.
  4. ^ "MakeTechEasier list of alternative PDF viewers". Retrieved 24 April 2015.
  5. ^ "OpenHUB analysis of Zathura PDF Viewer". Retrieved 24 April 2015.
  6. ^ "Arch Linux zathura package".
  7. ^ "Debian zathura package".
  8. ^ "Fedora zathura package".
  9. ^ "Gentoo zathura package".
  10. ^ "OpenBSD zathura package".
  11. ^ "OpenSUSE zathura package".
  12. ^ "Source Mage zathura package".
  13. ^ "Ubuntu zathura package".
  14. ^ "MacPorts zathura package".
  15. ^ "pwmt". GitLab.
  16. ^ "Zathura initial commit".
  17. ^ "zathura - a document viewer".
  18. ^ "Arch Linux package history for Zathura".
  19. ^ "zathura package in Source Mage".
  20. ^ "Debian Squeeze package for Zathura".
  21. ^ "LaTeX forward/inverse searches with Zathura".
  22. ^ "Vim+Zathura+Synctex".
  23. ^ "Vim, Latex and Markdown preview scripts".
  24. ^ "Kile - TeX Wiki". texwiki.texjp.org.

External links[edit]