Coder Social home page Coder Social logo

djpdf's People

Contributors

comradekingu avatar ovari avatar unrud avatar vistaus avatar weblate avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

djpdf's Issues

Is jPDFTweak useful to you ?

Hi. Please look for this application (Java) if useful to you or not. It's developer stop from it's development. In fact it need some further new features to be a great application with complete PDF editing powers. It is jPDFTweak:

http://jpdftweak.sourceforge.net/
https://sourceforge.net/projects/jpdftweak/

It is a great crime not to have advanced PDF editor on Linux while we have such great backends like: QPDF & OCRmyPDF & such powerful Java GUI program like jPDFTweak ......

Some exceptions. Also `jbig2` vs. `jbig2enc`.

Looks like a nice tool, thanks. I'm running scans2pdf on the output of scantailor-advanced. Some exceptions occurred, so here is the output of running it on the first page. I can provide the image if it would be useful.

Note that ubuntu 22.04 has a snap providing jbig2enc, while you're looking for jbig2.

$ scans2pdf -v Feigon-001-000.crop_2R.tif scans2.pdf
WARNING:Program not found: jbig2
DEBUG:Using selector: EpollSelector
DEBUG:Running command: ['convert', '-colorspace', 'sRGB', '-profile', '/home/user/.local/pipx/venvs/djpdf/lib/python3.10/site-packages/djpdf/argyllcms-srgb.icm', '-background', '#ffffff', '-alpha', 'remove', '-alpha', 'off', '-type', 'TrueColor', '/home/user/Feigon-001-000.crop_2R.tif', '/var/tmp/djpdf-xwxq05cu/image.png']
DEBUG:convert-im6.q16: profile 'icc': 'RGB ': RGB color space not permitted on grayscale PNG `/var/tmp/djpdf-xwxq05cu/image.png' @ warning/png.c/MagickPNGWarningHandler/1668.

DEBUG:Running command: ['convert', '-fill', '#000000', '-opaque', '#000000', '-fill', '#000000', '-opaque', '#000000', '-threshold', '0', '/var/tmp/djpdf-xwxq05cu/image.png', '/var/tmp/djpdf-nma9ouby/image.png']
DEBUG:Running command: ['identify', '-units', 'PixelsPerInch', '-format', '%x %y', '/var/tmp/djpdf-xwxq05cu/image.png']
DEBUG:Running command: ['convert', '-fill', '#ffffff', '-opaque', '#000000', '-resize', '50%', '/var/tmp/djpdf-xwxq05cu/image.png', '/var/tmp/djpdf-_4oeppyf/image.png']
DEBUG:Running command: ['identify', '-format', '%w %h', '/var/tmp/djpdf-xwxq05cu/image.png']
DEBUG:Running command: ['convert', '-format', '%c', '/var/tmp/djpdf-nma9ouby/image.png', 'histogram:info:-']
DEBUG:Running command: ['convert', '-format', '%c', '/var/tmp/djpdf-_4oeppyf/image.png', 'histogram:info:-']
DEBUG:Running command: ['convert', '-fill', '#000000', '-opaque', '#000000', '-fill', '#000000', '-opaque', '#000000', '-threshold', '0', '/var/tmp/djpdf-xwxq05cu/image.png', '/var/tmp/djpdf-0h9szie5/image.png']
DEBUG:Running command: ['tesseract', '-l', 'eng', '--dpi', '600', '/var/tmp/djpdf-0h9szie5/image.png', '/var/tmp/djpdf-hogdbirb/ocr', 'hocr']
DEBUG:Tesseract Open Source OCR Engine v4.1.1 with Leptonica

INFO:Can't extract textangle from ocr_line: bbox 716 941 826 987; baseline 0 0; x_size 61; x_descenders 15.25; x_ascenders 15.25
DEBUG:Exception occurred:
Traceback (most recent call last):
  File "/home/user/.local/pipx/venvs/djpdf/lib/python3.10/site-packages/djpdf/hocr.py", line 46, in extract_text
    textangle = textangle_regex.search(line.attrib["title"]).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

INFO:Can't extract textangle from ocr_line: bbox 643 1005 898 1043; baseline -0.008 -6; x_size 37; x_descenders 7; x_ascenders 8
DEBUG:Exception occurred:
Traceback (most recent call last):
  File "/home/user/.local/pipx/venvs/djpdf/lib/python3.10/site-packages/djpdf/hocr.py", line 46, in extract_text
    textangle = textangle_regex.search(line.attrib["title"]).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

DEBUG:Running command: ['convert', '-alpha', 'remove', '-alpha', 'off', '-colorspace', 'gray', '-threshold', '50%', '-compress', 'fax', '/var/tmp/djpdf-nma9ouby/image.png', '/var/tmp/djpdf-82nt536j/image.pdf']
DEBUG:Running command: ['qpdf', '--stream-data=preserve', '--object-streams=preserve', '--normalize-content=n', '--newline-before-endstream', '--linearize', '/var/tmp/djpdf-1p_vtodx/temp.pdf', '/home/user/scans2.pdf']

cli-only version

Because of limited resources it is not possible for me to install djpdf with the gui-dependencies. As far as I can see, djpdf without gui would be rather small. Would it be possible to make a cli-only version? (I don't know any other cli-tool to generate pdfs from scans with foreground-background-separation. And djvu isn't an option in my workflow.)

Please look to this backend if it is useful to your application or not !

Hi. I detect your application from my monitoring for Flathub on GitHub. Your application still not appearing in Flathub & for that I'm still not installing it & not test it yet.

However, I'm very interested in development of advanced PDF editor for Linux. Specially, I'm interested in PDF tools that able to manipulate & optimized scanned PDF files .....

Your application seem to be at heart of my interest ! For that I like to bring your attention to very strong backend I see it useful for your application. I'm not sure since I'm not programmer but externally it seem very useful to you. Please see it:

https://pypi.org/project/ocrmypdf/
https://github.com/jbarlow83/OCRmyPDF

Look for it's options !

Are you intersted in creation advanced PDF editor ? Then look for QPDF !

Hi. if you are interested in creation an advanced PDF editor for Linux (which currently the only lack of Linux) then please look for this backend:

https://github.com/qpdf/qpdf
http://qpdf.sourceforge.net/
https://sourceforge.net/projects/qpdf/

Look for it's manual:
http://qpdf.sourceforge.net/files/qpdf-manual.html
http://qpdf.sourceforge.net/files/qpdf-manual.pdf

What it will be a GUI for this backend including ALL it's powers & functions ? It will be what Linux currently miss ....

It will be very helpful for peoples if you expand your application from just an OCR & optimizer for scanned PDF to full featured PDF editor.

Translations

How can translations be provided to this project?

Can translations for this project be hosted on Weblate?

Thank you

No default settings

I can't find where to set the default settings in the UI to keep the images are 100%.

I also expected this to be the default.

Progress

Two parts were the is very little feedback from the UI:

  1. After selecting files to add it take a bit of time, but we don't even know if it is working or not until the pages are displayed
  2. After clicking "create", "saving" stay for a long time without progress.

Keyboard shortcuts/accelerators

Please add keyboard shortcuts/accelerators.

For example:
&Remove
&Quality
&Language
Apply to &all
Apply to &following
&Load default settings
&Save default settings
&Cancel
&OK

What do you think?

Thank you

Blank screen on startup after installation

After I installed via snap on ubuntu 18.04 all I have is a blank window see image
Screenshot from 2019-06-02 16-13-18
I ran it with the command line djpdf and got the following

QStandardPaths: XDG_RUNTIME_DIR points to non-existing path '/run/user/1000/snap.djpdf', please create it with 0700 permissions.
QStandardPaths: XDG_RUNTIME_DIR points to non-existing path '/run/user/1000/snap.djpdf', please create it with 0700 permissions.
file:///snap/djpdf/7/lib/python3.6/site-packages/PySide2/Qt/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: Failed to initialize QSettings instance. Status code is: 1
file:///snap/djpdf/7/lib/python3.6/site-packages/PySide2/Qt/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: The following application identifiers have not been set: QVector("organizationName", "organizationDomain")
file:///snap/djpdf/7/lib/python3.6/site-packages/PySide2/Qt/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: Failed to initialize QSettings instance. Status code is: 1
file:///snap/djpdf/7/lib/python3.6/site-packages/PySide2/Qt/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: The following application identifiers have not been set: QVector("organizationName", "organizationDomain")

Can anyone help please?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.