How to install Krop(PDF Crop Tool) on Debian 9.0

To install Krop(PDF Crop Tool) on Debian 9.0

Krop is a free, simple and lightweight graphical PDF crop tool. You can split pages in a PDF file into sub-pages using Krop, doing this may help you crop the pages of a PDF file to fit the limited screen size of devices such as eReaders. One of the interesting features of Krop is that it has the option of automatic selection via Trim Margins button. Also, while cropping you can apply it on all pages, even/odd page, or a individual page. Page exception is also supported. It is so simple to install Krop and this article covers the method to install Krop on Debian 9.0

Installing Krop

If you want to download the installation package for Krop, make sure you get it from its official website. For that, you can use the wget command along with the download link for Krop which you should copy from its site.

root@debian:~# wget http://arminstraub.com/downloads/krop/krop_0.4.11-1_all.deb
--2017-07-25 06:46:56--  http://arminstraub.com/downloads/krop/krop_0.4.11-1_all.deb
Resolving arminstraub.com (arminstraub.com)... 107.191.102.54
Connecting to arminstraub.com (arminstraub.com)|107.191.102.54|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 18058 (18K) [application/octet-stream]
Saving to: ‘ krop_0.4.11-1_all.deb’ 

krop_0.4.11-1_all.deb    100%[===============================> ]  17.63K  --.-KB/s    in 0s      

2017-07-25 06:46:57 (35.3 MB/s) - ‘ krop_0.4.11-1_all.deb’  saved [18058/18058]

Once you have downloaded the file, make sure you install all the necessary dependency packages for the Krop application.

root@debian:~# apt-get install python-poppler-qt4 python-pypdf2
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libjavascriptcoregtk-3.0-0 libwebkitgtk-3.0-0
Use ' apt autoremove'  to remove them.
The following additional packages will be installed:
  libmariadbclient18 libpoppler-qt4-4 libqt4-dbus libqt4-declarative libqt4-designer
  libqt4-help libqt4-network libqt4-script libqt4-scripttools libqt4-sql libqt4-sql-mysql
  libqt4-svg libqt4-test libqt4-xml libqt4-xmlpatterns libqtassistantclient4 libqtcore4
  libqtdbus4 libqtgui4 mysql-common python-qt4 python-sip qdbus qt-at-spi qtchooser
  qtcore4-l10n
.
.
Setting up python-poppler-qt4 (0.24.0-1+b3) ...
Processing triggers for libc-bin (2.24-11+deb9u1) ...

You can now install Krop in an easy manner as follows.

root@debian:~# dpkg -i krop_0.4.11-1_all.deb 
Selecting previously unselected package krop.
(Reading database ... 126363 files and directories currently installed.)
Preparing to unpack krop_0.4.11-1_all.deb ...
Unpacking krop (0.4.11-1) ...
Setting up krop (0.4.11-1) ...
Processing triggers for gnome-menus (3.13.3-9) ...
Processing triggers for desktop-file-utils (0.23-1) ...
Processing triggers for mime-support (3.60) ...

Krop has been installed, Go to your Activities search field and type the name of the application, so that you can launch it. When you do that, the application appears on your screen like the following image.

With this, the installation of Krop on Debian 9.0 gets completed.

Tag : debian
FAQ
Q
Can you give me A few tricks in Krop?
A
If you press Trim Margins on a page without selections, then krop will automatically create a region for the full page with the margins trimmed.

If you are cropping a PDF file with many pages, then you may have some exceptional pages which need to be cropped in a different way then the other pages. In that case, the option Exceptions under Selections apply to will be useful to you.

You can use krop --go on the command line (without the GUI) to automatically

extract certain pages,

rotate pages, or

trim empty margins (the margins are determined from the --initial page).

For instance:



$ krop --go --rotate 90 --autotrim -o ~/output.pdf input.pdf



To get around the error "cannot connect to X server", you can prefix this command with xvfb-run (in the package xvfb on Debian and Ubuntu).

Run krop with --help to get a list of all possible arguments (for instance, --initial page 5 starts krop with the fifth page open).

To add the dimensions of your own eReader to the 'Fit screen of device' choices, you can edit the configuration file. The location of this file may differ from system to system, but a good place to start looking is ~/.config/arminstraub.com/krop.conf. Don't forget to adjust the counter size= after adding your entries in the device type section.

If you run into the error "multiple definitions in a dictionary" while cropping a file, then this is because pyPdf is too strict. You can either upgrade to PyPDF2 or proceed as indicated in this bug report.
Q
I want to install krop on ubuntu?
A
just follow this link, https://www.linuxhelp.com/how-to-install-krop-on-ubuntu-17-04/
Q
is there any alternative of krop?
A
Alternatives are below, PDF Shuffler Briss PDFCrop
Q
What does if krop is fails to do?
A
via YaST->Software->Software Management and search for wireshark or via the cli; # zypper in wireshark.As a result, krop is not suited for the following: censor a PDF document decrease th
Q
How to install krop on deian package?
A
run as command below, # dpkg -r krop_0.4.11-1_all.deb