HOW to edit a PDF using Libre?

can libre office edit a PDF? When I open one it goes to DRAW and makes the text into an image? Any way to make it text?

If the pdf is just an image of a page, such as a jpg then there will be no text. To edit text in images you need to use an OCR (Optical Character Recognition) program to recognise the text in the image and create a replica of the page but with text. How accurately it does this depends on the program and the image. OCR programs range from free to very expensive. There are some online sites that will OCR images for you, probably search on “OCR website” or similar.
PDF pages that include actual text are not word-processing documents, they are just a layout with objects (text boxes and images) that are placed on the page in specific positions. PDFs are opened in Draw because it is a drawing program and as such is designed to handle objects placed on a page in specific positions. Cheers, Al

1 Like

OK, But I was able to convert the PDF to a WORD file with TEXT, so it was not an image

And it opened in DRAW which is your image program but would not edit.

SO, after editing it in WORD I just saved again in PDF.

WHY did I have to buy this Office suite when it is free?

Word contains an OCR engine according to Google, but why would I know that? This site is about LibreOffice not Word.
It seems Windows 10 has OCR built-in too, see Optical Character Recognition (OCR) for Windows 10 - Windows Developer Blog

Buy what Office suite? You can download and install LibreOffice on as many computers as you like for free.

As @EarnestAl already describes, PDFs generated by third-party software are unpredictable. It’s like a grab bag. You can’t see what you can do with it until you open it in Draw.

Here is a description of third-party PDFs and PDFs created in LibreOffice.

I hope this can help.

There is a useful file export in LibreOffice, you can export your document to Hybrid PDF which means it opens as a pdf in a pdf reader but it can also be opened by the originating LO program and edited if if needs to be changed subsequently.
With your document open click File > Export As > Export as PDF…, in the dialogue that opens (PDF Options) in the General tab click Hybrid PDF (embedded ODF), select any other options and OK.

Hi EarnestAl

I have a simple PDF file with only text, no images. When I open it to edit it, DRAW tries to

Add a TEXT BOX that overwrites my PDF file, does not edit the text, and makes a mess.

This PDF file was simply output by WORD using the Print to PDF option,

so is a standard PDF file, not something from another program.

For now, I have to use another program to CONVERT PDF to TEXT, then edit it in WORD,

And then re-export as PDF… Wish I could just edit it in Draw?

As @EarnestAl has already mentioned it, PDF is a page description language and format (loosely based on PostScript). Therefore everything in it is a graphical object. Text is represented in a compact form (with strings) but it remains a graphical object.

Draw displays all graphical objects it finds in a page. Sometimes you don’t see an exact representation of text because the exporter may have omitted implicit data by not embedding fonts (assuming they are universally present on every computer, which is rarely the case). You no longer have a continuous flow of text with formatting directives but a set of disjoint homogeneous strings (same font face, size, weight, slant, …) positioned horizontally and vertically. If the bounding boxes are not displayed you may have the illusion of a continuous text but this is not the case.

Recreating the text document with all its attributes is impossible. You can’t even recreate paragraphs!

So if you need to frequently edit your PDF, your first task is to recreate a text document. The simplest way to do it is to copy text in a PDF viewer and paste it into a new Writer document. Your second task is to merge the single-line pseudo paragraphs into real meaningful paragraphs. The third task is to reformat the text (for this step, I urge you to think about which paragraph, character and page styles are needed; don’t ever start direct formatting, you’ll create new difficulties for later edits).

When done, save as .odt and consider this file as your primary source. Always edit it.

PDF is only a way to transmit the file in an unchangeable format to anybody (eventually not having the fonts you used). Work on your primary source so that you won’t over and over reconvert from PDF.

For now, I have to use another program to CONVERT PDF to TEXT, then edit it in WORD,
And then re-export as PDF… Wish I could just edit it in Draw?

Then if you already edited in Word, why would you convert back from PDF again? Work on your .docx copy.

As a last resort, you could also open the .docx with Writer or have Word export to .odt. However, I don’t recommend this venue because conversion from .docx to .odt gives documents which are a real mess formatting-wise. Styles are completely polluted during the operation.

1 Like

So you have Convert PDF to Text program, excellent. Why don’t you open the output of that in Writer and arrange to your liking. You can save as ODT while you are working on it and as a backup.
When you are happy with it, click File > Export > Export as PDF

and select Hybrid PDF.

You can then open Writer and click File > Open, select the pdf, edit it in Writer and Export As hybrid PDF again without losing anything.
I would upload a sample Hybrid PDF but the site does not accept PDF files and giving it a different extension defeats the purpose.

Yep, did that. Guess I was lazy and wanted a direct PDF editor like Acrobat DC professional.
Either way it is fine. Thanks.