If you’ve written any code, you probably agree that programming involves reading documentation, lots of it. In many cases, the time spent reading documentation and other code exceeds the actual time writing code. And since that documentation is more often than not accessed on the Web, a significant portion of time is wasted finding the information you’re looking for and waiting for it to load. These small delays can be frustrating, especially with slower connections, and can quickly add up to minutes, or hours, of lost productivity. Besides, a constant Internet connection, which is not always available, is required to access that information,
Fortunately, you can use Zeal, an offline documentation browser, to store programming language and software documentation on your computer and access it quickly and effectively. Zeal uses document sets (docsets) provided by Dash. They include documentation for many programming and scripting languages and libraries, as well as various software such as Docker, Nginx, WordPress and ElasticSearch, to name a few.
Here’s how to install, use and customize Zeal on Linux.
Also read: View Your Code Like a Pro with Code Compare
Installing Zeal
Zeal is available in the software repositories of many Linux distributions, so you should install it using your native package manager if possible.
On Ubuntu, Linux Mint, and Debian:
sudo apt install zeal
On Arch Linux:
sudo pacman -S zeal
On Gentoo:
sudo emerge app-doc/zeal
On Fedora:
sudo dnf install zeal
Using Zeal
You can launch Zeal from your application menu/launcher or from a command-line terminal by typing zeal
.
Zeal does not include any documentation by default. To view the available docsets, go to “Tools -> Docsets” and open the “Available” tab.
Select the docsets you want to store and click on “Download.” Once fetched, document sets are displayed in the upper-left pane in a navigable hierarchical structure. When applicable, the lower-left pane displays shortcuts to the elements of the current document page.
You can search all docsets by entering a query or a specific docset with the syntax docset:query
. For instance, to search for Python’s re.match
function, you would enter python:re.match
.
Note: with the compound search syntax (that is docset:query
), the docset
part is case sensitive, and the query
part is case insensitive.
Customizing Zeal
Fonts
You can configure Zeal’s appearance to your liking with fonts and font sizes.
To do so, go to “Edit -> Preferences -> Content” and then select a default font family and specific fonts for each font family.
Dark Mode
Zeal also provides a dark mode (in “Edit -> Preferences -> Content”), though it is only applied to document contents and not to the surrounding graphical interface as you can see in the following screenshot.
User-Defined CSS
If you are going to be using Zeal on a regular basis, then it’s worth devoting some time to tweak it to your own taste. You can use a custom stylesheet for greater and finer control over the appearance of documents.
Create a new CSS file using your text editor:
vim ~/.local/share/Zeal/custom.css
Enter the desired CSS rule sets, for example:
code { border-style: dashed; border-width: 1px; color: red; }
Go to the “Edit -> Preferences -> Content -> Custom CSS” file to select the newly created CSS file. After saving your settings, the changes will be visible immediately. The following screenshot shows Zeal after applying the above CSS.
Conclusion
Zeal is a great tool for programmers and system administrators who tend to access documentation frequently. Since it stores documents locally, it can save you time and allow you to better focus on the work at hand. Additionally, unlike Web documents, it supports user-defined stylesheets for fine control over document appearance.
Karl Wakim is a technical author and Linux systems administrator.
Subscribe to our newsletter!
Our latest tutorials delivered straight to your inbox
Sign up for all newsletters.
By signing up, you agree to our Privacy Policy and European users agree to the data transfer policy. We will not share your data and you can unsubscribe at any time. Subscribe