PDF Tech

Your Guide to Text Editing with Web-based PDF Viewers

by Conor Smith | May 21, 2020

Being able to edit PDF text online is crucial to a lot of business workflows. This includes adding new text to files that typically don’t have form fields as well as making edits to already existing text. If you’re an insurance company, you need to be able to quickly add a text box with the typewriter tool to include additional policy information. If you work in the legal sector and don’t have access to a filing in its original authoring format, you need to be able to make a text adjustment in the PDF version. There are many different use cases for text editing whatever your industry. Read on as we take a look at text editing with Web-based PDF viewers and what you need to get the most out of it for your company.

If you’re at the research stage of trialing web-based PDF viewers, the first thing you need to ensure is that you can actually edit text. Surprisingly, a lot of vendors in the market don’t offer this functionality which can mean your vision of improved workflows falls by the wayside. You should be able to adjust text and add new text boxes where required. Once you’re good to go with that, let’s move on to what you need control over for a great PDF text editing experience online. The main foundation of good PDF viewing/editing software is its ability to provide users with full control to modify content in any environment or context. Text editing, of course, is at the top of this list.

Text Selection

When it comes to text selection, this can be tricky in a PDF. Because PDFs are often flattened, this means all objects in a file are placed onto a single layer. This is a problem for most Web-based PDF editors as they struggle to differentiate objects by type, coordinates, and other properties. Quality text selection functionality means you should be able to select a full line, provided the formatting of the text in the line is the same. Text selection is also key for doing subsequent operations in a PDF since it locks in the specific information regarding the text provided by the text selection activity.

Font & Text Size

Some PDF editors default to commonly used fonts also known as “master” fonts. The Arial font is an example of this. This means every time you try to add new text in a line, in order to prevent any incorrect display of text if a custom font is being used, there may be glyphs missing from the document font. This may not be an issue if your entire document is written with Arial but can be when you’re using multiple or uncommon fonts. Great JavaScript-based PDF viewers will enable you to edit text that matches the font and text size you are editing as a default. Of course, you should also be able to easily change the font and size as you wish.

Premium web-based PDF viewers provide a wide coverage of fonts, so you don’t need to worry about text rendering issues and font embedding. However, you should also have the flexibility of doing that by yourself. This is particularly important if memory is an issue in your application and you have your own workflow in place for example. In either case, a powerful core engine should be able to handle and successfully display a large number of fonts, as well as standard and custom encoding types.

Simplify your PDF Development Journey

Languages & Character Encodings

Being able to edit the text of different languages and scripts is also critically important for many companies who do business in the global market. If your company is only concerned with the English language, your needs will likely be met by a basic viewer, but if you have people working in different scripts then you will need to be able to add that umlaut and hamza in your work. Again, top quality PDF viewers will allow you to work with many languages to ensure the needs of an internal team are met.

Supporting a wide range of languages and character encodings is no mean feat. Going beyond basic ASCII into Unicode’s extensive character encodings and expanding the range of languages supported requires a mature and specialized rendering engine. It must be capable of supporting many use cases while remaining flexible to customization without damaging the font rendering for other languages.

Color, Bolding, Italics & Underlining

Other important elements you should be able to control include the text styling of color, as well as bolding or italicizing certain text, and underlining. A basic web-based JavaScript PDF viewer will only offer one or a combination of these functions, whereas more advanced viewers will offer all of them.

When all of the above comes together, you should get an online PDF text editing experience that looks something like this:

At Foxit, we’ve been the foremost expert on PDF for developers for over a decade now. Get in touch with us below for more info on editing text online with PDF SDK for Web and see how we can help you.