krop Original

Utilities crop ebook pdf

Source (link to git-repo or to original if based on someone elses unmodified work): https://github.com/arminstraub/krop

3
8 .1
Description:

krop is a simple graphical tool to crop the pages of PDF files.

It is written in Python and relies on PyQT, python-poppler-qt5 and PyPDF2 for its functionality. A unique feature of krop is its ability to automatically split pages into subpages to fit the limited screen size of devices such as eReaders. This is particularly useful, if your eReader does not support convenient scrolling.

For more information and how to install krop, see: http://arminstraub.com/software/krop
Last changelog:

krop (0.6.0) 2020-06-09 -- Armin Straub 5 months ago

+ Fixed aspect ratios, like letter size, can be chosen for selections.
+ Selections (or a grid of selections) for the full page can now be created
using the context menu or by pressing Insert (or Shift+Insert). Also
introduced the command line option --grid to create a grid of selections on
the initial page.
+ Auto trimming margins can now inspect all pages.
+ New option for whether to include pages without selections in the output.
+ Added the command line options --optimize (thanks to Ondrej Tichacek for
suggesting this feature) and --exceptions.
+ Implemented several keyboard shortcuts including Shift+Arrow to move
current selection and Delete to remove it.
* Keep track of current selection and highlight it visually.
* Don't fail on PDFs that are encrypted with an empty password.
* Remember window geometry and fit in view setting.

9

roctheme

5 years ago

krop crash, if I try to open krop directly with a file. E.g. via right click menu.

in terminal it works:
krop <filename>

ProblemType: Crash
CurrentDesktop: KDE
Date: Tue Aug 11 08:57:21 2015
ExecutablePath: /usr/share/krop/krop.py
ExecutableTimestamp: 1400944165
InterpreterPath: /usr/bin/python2.7
ProcCmdline: /usr/bin/python /usr/bin/krop /home/user/File.pdf
ProcCwd: /home/user
ProcEnviron:
LANGUAGE=de
PATH=(custom, user)
XDG_RUNTIME_DIR=<set>
LANG=de_DE.UTF-8
SHELL=/bin/bash

...

krop.py crashed with TypeError in main(): decode() argument 1 must be string, not None

Report

C

arminstraub

5 years ago

Thanks for the report!

The following should fix the crash: in krop.py, replace the line
fileName = args.file.decode(sys.stdin.encoding)
with
fileName = args.file.decode(sys.stdin.encoding or sys.getdefaultencoding())
Please let me know if this does not work as intended.

This change will be included in the next update of krop.

Report

9

roctheme

5 years ago

It works!

Thank you!

Great App.

Report

9

epsilom

5 years ago

Thanks for this app this is very useful!, I have one wish: please do that the pointer mouse change when over edge icons/markers of mergin to cut, and make those markers more bigger. This would be easier when I want change the selection margins

Report

C

arminstraub

5 years ago

Thank you for the helpful suggestions! I hope you like the improved visibility of the selections and handles in the new version 0.4.8.

Report

Putin

5 years ago

can you include the mainwindow.ui file to the source code ?

Report

C

arminstraub

5 years ago

Added to the source files in the new version 0.4.7. Have fun!

Report

9

OdinEidolon

6 years ago

krop /mnt/usbpen/images/all_ALL_all_ALL.pdf
Traceback (most recent call last):
File "/usr/bin/krop", line 19, in <module>
krop.krop.main()
File "/usr/lib/python2.7/site-packages/krop/krop.py", line 54, in main
from mainwindow import MainWindow
File "/usr/lib/python2.7/site-packages/krop/mainwindow.py", line 30, in <module>
from vieweritem import ViewerItem
File "/usr/lib/python2.7/site-packages/krop/vieweritem.py", line 20, in <module>
from popplerqt4 import Poppler
RuntimeError: the sip module implements API v11.0 but the popplerqt4 module requires API v10.1

Report

C

arminstraub

6 years ago

The last line of your output suggests that popplerqt4 is not correctly setup on your system. Try typing "from popplerqt4 import Poppler" at a python command line to see if you get an error.

Not sure what may have caused the problem; does the suggestion at https://groups.google.com/forum/#!topic/frescobaldi/ViHxQpW4470 make sense to you?

Report

9

OdinEidolon

6 years ago

Hi, thanks for this little nifty program, works very well.

I also have the bug which prevents Krop to be used via the right-clivk "open with" menu.

Three more suggestions in order of importance:
1) Provide a way to allow to crop many different pdf files with the same cropping geometry/selection. Or at least speed up the process. (eg: option to remember output folder and cropping region for the next file, and button to open the next file in the working folder)

2)Provide a button to automatically select a region without having to do it manually. Okular does have such a button that says "trim margins".

3)Krop seems to forget, if closed and reopened, the last opened files and their folder.

Thank you!

Report

C

arminstraub

6 years ago

Version 0.4.6 now has your item (2) covered, but I have not yet gotten around to items (1) and (3).

Report

C

arminstraub

6 years ago

Thank you for the comments! I like your suggestions and plan to address them in the next version (which will probably be a few weeks down the road of time).

Report

nitsnatsnok

6 years ago

In Kubuntu 12.04, i can't open files using the "Open" button in the GUI - opening the same files using the terminal (krop file.pdf) works great. Here's the error thats shown when I start krop in the terminal and try to open a file:

UnicodeEncodeError: 'ascii' codec can't encode character u'\xe4' in position 26: ordinal not in range(128)

Great program, thanks a lot!!!

Report

C

arminstraub

6 years ago

Could you please try if the updated version (now 0.4.5) fixes your issue?

Report

9

roctheme

7 years ago

Waiting so long for a good pdf cropping tool.

Debian Package work with Kubuntu 13.04 too.

Report

9

roctheme

7 years ago

Note, command line option [file] doesn't work on Kubuntu.

e.g.: krop /home/user/Dokumente/test.pdf

krop: Unexpected argument '/home/user/Dokumente/test.pdf'.
krop: Use --help to get a list of available command line options.

Report

C

arminstraub

7 years ago

Thanks for the kind words!
The bug you mention will be fixed in the next version.
(To fix this silly regression right now you can replace the line 'KCmdLineArgs.init (sys.argv, aboutData)' in krop.py by the line 'KCmdLineArgs.init(aboutData)'.)

Report

9

roctheme

7 years ago

Thanks,

KCmdLineArgs.init(aboutData) fixes the command line problem in Kubuntu.

context menu "open with->krop" now work too in Dolphin.

Note, krop has no icon in Kubuntu. Perhaps you can use this system icon:
Icon=edit-cut

Report

C

arminstraub

7 years ago

Nice suggestion! The edit-cut icon is now used in version 0.4.3.

Report

9

cgonzalez

7 years ago

I have a Nook 1st Generation to and I was looking for an application like this. Thank you!

Report

krop (0.6.0) 2020-06-09 -- Armin Straub 5 months ago

+ Fixed aspect ratios, like letter size, can be chosen for selections.
+ Selections (or a grid of selections) for the full page can now be created
using the context menu or by pressing Insert (or Shift+Insert). Also
introduced the command line option --grid to create a grid of selections on
the initial page.
+ Auto trimming margins can now inspect all pages.
+ New option for whether to include pages without selections in the output.
+ Added the command line options --optimize (thanks to Ondrej Tichacek for
suggesting this feature) and --exceptions.
+ Implemented several keyboard shortcuts including Shift+Arrow to move
current selection and Delete to remove it.
* Keep track of current selection and highlight it visually.
* Don't fail on PDFs that are encrypted with an empty password.
* Remember window geometry and fit in view setting.

krop (0.5.1) 2018-10-27 -- Armin Straub 5 months ago

* Replace and extend the README file with a MarkDown version (thanks to
Eduardo Montenegro for doing this).
+ Add a manpage.
* Fix a Qt5 related bug when selecting filename for saving (thanks to
Lin-Buo-Ren for reporting this).

krop (0.5.0) 2018-02-11 -- Armin Straub 2 years ago

+ Support PyQt5.
+ Use Ghostscript to optionally optimize the final PDF (thanks to Mathias Rav for the idea and code).

krop (0.4.13) 2017-07-22 -- Armin Straub 3 years ago

+ Added the command line option --go, which outputs a PDF using the choices
from --autotrim, --rotate and --whichpages, without opening the krop GUI
(thanks to Mirko Weihrauch for the idea).
+ Padding for auto trimming can be specified as in CSS using one to four
values. This option is now also available on the command line as
--autotrim-padding. (Thanks to Jonah Langlieb for providing sanity checks!)
* Fix incorrect string handling when opening files from the command line
using python3 (thanks to Giuliano Costantini for observing and fixing this).

krop (0.4.12) 2017-01-22 -- Armin Straub 3 years ago

* Use CropBox instead of MediaBox when determining the region to be cropped (thanks to Tim Mueller for observing and fixing this).
* Use a more proper Python package structure (thanks to Xavier Corredor Llano for advice).

krop (0.4.11) 2016-08-29 -- Armin Straub 3 years ago

* Make krop compatible with both python2 and python3.

12345678910
14
product-maker purplehuman Oct 31 2015 9 excellent
product-maker dubious Oct 27 2015 9 excellent
product-maker epsilom Feb 16 2015 9 excellent
product-maker pondogor Feb 16 2015 9 excellent
product-maker narya Oct 27 2014 9 excellent
product-maker anespor May 25 2014 9 excellent
product-maker OdinEidolon Feb 16 2014 9 excellent
product-maker ahlo Sep 19 2013 9 excellent
product-maker dunemafia Aug 29 2013 9 excellent
product-maker janet Aug 11 2013 9 excellent
product-maker roctheme Aug 07 2013 9 excellent
product-maker caig Jul 30 2013 9 excellent
product-maker cgonzalez Jul 29 2013 9 excellent
product-maker fri Jul 29 2013 9 excellent
Be the first to comment
janet
Mar 20 2014
OdinEidolon
Feb 16 2014
roctheme
Aug 19 2013
File (click to download) Version Description PackagetypeArchitectureRelease Channel Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
GPLv3
version
0.6.0
updated Jun 09 2020
added Jul 29 2013
downloads 24h
0
mediaviews 24h 0
pageviews 24h 7