UbuntuUbuntu Based

How To Install Okular on Ubuntu 24.04 LTS

Install Okular on Ubuntu 24.04

In the ever-evolving landscape of Ubuntu, having a reliable and feature-rich document viewer is essential for productivity and seamless workflow. Okular, a versatile document viewer, has gained popularity among Ubuntu users for its robust functionality and user-friendly interface. This comprehensive guide will walk you through the process of installing Okular on Ubuntu 24.04, ensuring you have access to this powerful tool for managing your documents efficiently.

What is Okular?

Okular is an advanced document viewer developed as part of the KDE project. It supports a wide range of file formats, including PDF, EPUB, DjVu, CHM, XPS, and various image formats. Okular stands out from other document viewers due to its extensive feature set, which includes:

  • Annotation tools for highlighting, underlining, and adding notes
  • Form filling capabilities for interactive PDF documents
  • Text extraction and search functionality
  • Presentation mode for slideshows
  • Customizable interface and keyboard shortcuts

These features make Okular an excellent choice for students, professionals, and anyone who frequently works with digital documents. Its integration with the KDE environment ensures a smooth experience for Ubuntu users, while still being accessible and functional on other desktop environments.

System Requirements

Before proceeding with the installation of Okular on Ubuntu 24.04, ensure that your system meets the following requirements:

  • Ubuntu 24.04 LTS (Long Term Support) installed and up to date
  • At least 2GB of RAM (4GB recommended for optimal performance)
  • 1GB of free disk space
  • An active internet connection for downloading packages

While Okular is not particularly resource-intensive, having a system that meets or exceeds these requirements will ensure smooth operation and quick document rendering.

Pre-installation Steps

To prepare your Ubuntu 24.04 system for Okular installation, follow these pre-installation steps:

  1. Update your system packages:
    sudo apt update && sudo apt upgrade -y
  2. Check for any conflicting software:Ensure that you don’t have any other PDF viewers set as default that might conflict with Okular. You can keep multiple document viewers installed, but it’s good to be aware of potential conflicts.
  3. Back up important data:While installing Okular is generally safe, it’s always a good practice to back up important documents before making system changes.

Installation Methods

There are three primary methods to install Okular on Ubuntu 24.04. Choose the one that best suits your comfort level and preferences.

1. Using Ubuntu Software Center

The Ubuntu Software Center provides a user-friendly graphical interface for installing applications. To install Okular using this method:

  1. Open the Ubuntu Software Center from the Applications menu or by searching for “Software” in the Activities overview.
  2. In the search bar, type “Okular” and press Enter.
  3. Look for Okular in the search results and click on it.
  4. Click the “Install” button next to Okular.
  5. Enter your system password when prompted to authorize the installation.
  6. Wait for the installation to complete. You’ll see a progress bar indicating the download and installation status.

Once installed, you can launch Okular from the Applications menu or by searching for it in the Activities overview.

2. Using Terminal (Command Line)

For users who prefer the command line or want more control over the installation process, using the terminal is an efficient method. Follow these steps to install Okular via the terminal:

  1. Open the terminal by pressing Ctrl+Alt+T or searching for “Terminal” in the Activities overview.
  2. Update your package lists:
    sudo apt update
  3. Install Okular using the following command:
    sudo apt install okular -y
  4. Wait for the installation to complete. The terminal will display the progress and any additional packages that need to be installed as dependencies.
  5. Once the installation is finished, you can verify it by checking the version:
    okular --version

This method is particularly useful for system administrators or users who want to automate the installation process through scripts.

3. Installing from Source

Advanced users might prefer to install Okular from source code. This method provides the latest features but requires more technical knowledge. Here’s a general outline of the process:

  1. Install build dependencies:
    sudo apt install git cmake extra-cmake-modules qtbase5-dev libkf5config-dev libkf5coreaddons-dev libkf5windowsystem-dev libkf5kio-dev libkf5parts-dev libphonon4qt5-dev libkf5threadweaver-dev libpoppler-qt5-dev libepub-dev libspectre-dev libqca-qt5-2-dev libzip-dev libkf5kjs-dev libkf5completion-dev libkf5bookmarks-dev libkf5xmlgui-dev khelpcenter-dev libkf5doctools-dev libkf5purpose-dev
  2. Clone the Okular repository:
    git clone https://invent.kde.org/graphics/okular.git
  3. Navigate to the cloned directory:
    cd okular
  4. Create a build directory and navigate to it:
    mkdir build && cd build
  5. Configure the build:
    cmake ..
  6. Compile Okular:
    make
  7. Install Okular:
    sudo make install

While this method gives you the latest version of Okular, it requires more maintenance for updates and can be more complex to manage.

Post-installation Configuration

After successfully installing Okular, you may want to configure it to suit your needs:

  1. Set Okular as the default PDF viewer:
    • Right-click on a PDF file
    • Select “Properties”
    • Go to the “Open With” tab
    • Choose Okular from the list and click “Set as default”
  2. Customize the interface:
    • Open Okular
    • Go to “Settings” > “Configure Okular”
    • Explore options for appearance, performance, and accessibility
  3. Explore advanced features:
    • Experiment with annotation tools
    • Try the presentation mode for slideshows
    • Test form-filling capabilities on interactive PDFs

Install Okular on Ubuntu 24.04 LTS

Troubleshooting Common Issues

While installing Okular on Ubuntu 24.04 is generally straightforward, you might encounter some issues. Here are solutions to common problems:

Installation Failures

If you experience installation failures, try the following:

  • Ensure your system is up to date: sudo apt update && sudo apt upgrade -y
  • Clear the APT cache: sudo apt clean
  • Retry the installation

Dependency Problems

For dependency issues:

  • Run sudo apt install -f to fix broken dependencies
  • If using a PPA, ensure it’s compatible with Ubuntu 24.04

Performance Issues

If Okular is running slowly:

  • Check system resources using top or System Monitor
  • Close unnecessary applications
  • Adjust Okular’s performance settings in the configuration menu

File Compatibility Problems

For issues with specific file formats:

  • Ensure you have the necessary backend libraries installed
  • Update Okular to the latest version
  • Try opening the file with another viewer to check if it’s corrupted

Updating and Maintaining Okular

To keep Okular up to date and running smoothly:

  1. Regularly update your system:
    sudo apt update && sudo apt upgrade -y
  2. Check for Okular updates specifically:
    sudo apt list --upgradable | grep okular
  3. If updates are available, install them:
    sudo apt install okular

For users who installed from source, you’ll need to periodically pull the latest changes from the Git repository and recompile.

Congratulations! You have successfully installed Okular. Thanks for using this tutorial for installing the Okular universal document viewer on the Ubuntu 24.04 LTS system. For additional help or useful information, we recommend you check the official Okular website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is an experienced Linux enthusiast and technical writer with a passion for open-source software. With years of hands-on experience in various Linux distributions, r00t has developed a deep understanding of the Linux ecosystem and its powerful tools. He holds certifications in SCE and has contributed to several open-source projects. r00t is dedicated to sharing her knowledge and expertise through well-researched and informative articles, helping others navigate the world of Linux with confidence.
Back to top button