Confessions of an unjustified sinner: Using justification in OOo Writer

When typewriters ruled the desktop, all paragraphs had a ragged right justification, with each line starting at the same position on the left, but with a variable right margin. Full justification -- lines whose left and right sides all ended in the same positions -- were the mark of professional typography, and beyond the means of the average user.

Little wonder, then, that when word processors brought full justification to everyone in the 1980s, that users went wild for it. The fondness for justification has never died since, even though many programs do it poorly, leaving irregular spaces between words and letters that make the document look less professional, rather than more. Writer is better at justification than most word processors and desktop publishing programs, but you need to be prepared to work at it. Before you set your paragraphs to full justification, you need to consider whether it's an appropriate choice for your layout. Then you need to set it up correctly, and be willing to tweak the results if you want results that are as professional as possible.

Planning justification

Unless you have changed the template in Writer, the default style is ragged left justification. Before you change it, you can predict how hard justification will be to implement by examining the line length of the paragraphs where you plan to use it. The basic rule is, the shorter the line length, the harder you have to work for justification to look decent. That means that a fifteen centimeter line that extends across most of the page is a good candidate for justification, while a two inch line in a three column spread may not be.

The easiest way to tell if a paragraph can be easily justified is to look at the number of lines that end in a hyphen when set to ragged left. The more hyphenated lines, the harder you will have to work.

Of course, if a paragraph is a poor candidate, you can always adjust your layout, assuming that you are in the early stages of the design process. You can try changing the font size. Since each font has its own metrics, you can also change the font.

A more elaborate solution may be to change the hyphenation for the paragraph on the Text Flow tab for the paragraph style or the individual paragraph. Select the box for automatic hyphenation, then adjust the default number of characters at the start and end of the line, and evaluate the results.

Alternatively, you can evaluate the extent of the problem by setting the limit on the number of hyphenated lines in a row from 0 -- meaning that no limit exists -- to 1. The more irregular lines you see, the harder you'll have to work with justification.

Setting up justification

Since you are likely to want to make adjustments, always use paragraph styles when using full justification. Most likely, the style you will be working with will be Text Body and any styles derived from it -- headings are usually short enough that you don't need to both with justification for them.

The basic settings are on the Alignment tab. Besides selecting the radio button for Justified, be sure that the Last line setting is Left. This option sets the last line of a justified paragraph to a left alignment, which eliminates the impossible situation of trying to justify a line of text that is simply too short for the alignment, and will have ugly gaps in it. You should almost never have problems with the Last line setting, but, if you do, you can always adjust it manually.

Do not select the Expand single word option, since it will only increase the problem you are trying to avoid. In fact, the existence of this option is a mystery, since no one with any sense of aesthetics would ever want it.

In addition, make sure that hyphenation is set to automatic on the Text Flow tab. When this option is activated, Writer will attempt to hyphenate on-the-fly. You may also want to adjust the other hyphenation choices to see if you can improve the look of the justification.

If you have a problem with justification, it should be obvious as soon as you apply it. You will have what typographers sometimes call rivers of white space -- irregular gaps between words and letters running down the length of the paragraph. Look at the paragraph from a meter or so away, and it will look cluttered as your eye roams over it.

To get best results, print out a sample and evaluate it rather the screen display. For most people, critical and aesthetic judgements are easier on paper -- and, anyway, that is presumably how people will see it, or you wouldn't be taking the time to do full justification properly.

The second pass

When hyphenation is set to automatic, Writer does its best to set up lines on the fly. However, the usual process of editing -- deleting words and lines, and going back and editing what you have already written -- means that the automatic arrangement of lines may be suboptimal, regardless of what your alignment may be.

For this reason, you can almost always improve the look of any document when it is finished by selecting Tools -> Language ->Hyphenation. This selection will allow you to revisit hyphenation a second time. Prompted by every place where an additional hyphen can be put, you have a choice of accepting or rejecting the suggestion, or adjusting the exact location where a word at the end of a line is hyphenated. This control will both improve the look of justification and ensure that hyphenation falls at the end of a syllable as it should (Writer's hyphenation tool is reasonably reliable, but it does make some mistakes).

Should you be unable to run Hyphenation, the reason is that the hyphenation dictionary for the language you are using is not set up or installed. Check Tools -> Options -> Languages -> Writing Aids to see. If the dictionary is not installed, you can either change the language used by the paragraph style on the Fonts tab, or else use File -> Wizards -> Install new dictionaries to install the missing dictionaries.

At this point, justification should be much improved. However, you may still see areas where you can improve the layout. To do so, select some characters and spaces that you want to improve manually, then select Format -> Character -> Position. Choose whether to expand or condense the selected text, and the amount by which you want to adjust it. This amount will be measured in points, the traditional measurement for fonts in typography, which is equal to about 1/72nd of an inch. Writer can work in units as small as one-tenth of a point, and probably, you will want to make adjustments of only a few tenths at the very most -- a point is a lot when you are considering letter spacing. Repeat this process as needed, and, when you are done, the justification in your document will be as well-done as it possibly can be in Writer.

Is justification worth the effort?

Using justification effectively takes time, patience, and more than a little trial and error. For many documents, you may not think it worth the time. Instead, you might omit the final step of tweaking individual characters. If you do, you will still end up with full justification that looks more professional than what you can get in many word processors and layout programs.

The alternative is to content yourself with a ragged right look, perhaps improved by running Hyphenation at the same time as the spell-check. Many designers, perhaps in reaction to the easy availability of full justification in the computer age, actually prefer ragged right, arguing that it is more pleasing to the eye. And there is no doubt that it requires less work to look acceptable, which, I confess, is why it is my own preference.

Still, if you're going to use justification, take some time to do it right. Otherwise, your work will make you look as though you are stuck in an 1980s mindset, and are too bedazzled by the feature to learn how to use it well.

Bruce Byfield is a computer journalist who writes regularly for the Datamation,, and Linux Journal web sites.


Bruce Byfield (nanday)


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

LaTeX is very complex

Regenbogen's picture

I think LaTeX is great, but for the common user not practicable. Very hard to use, and not what I would call userfriendly...


Kraig's picture

As soon as you start to produce documents which have multiple chapters, or documents which are of any decent size, keeping all the source text in one file becomes unmanageable in LaTeX.

Best regards, Kraig
free downloadable fonts

LaTeX is very complex

lucas's picture

I can agree with your opinion :

"I think LaTeX is great, but for the common user not practicable. Very hard to use, and not what I would call userfriendly..."

It is real true... I'm going to blog about on my own blog Blog

correction and addition

John Moore's picture

Helpful article. The more accurate term for the default paragraph alignment in Writer is "left aligned" or "ragged right," not "ragged left alignment." Most word processing should be left aligned for maximum reading ease. Save justified alignment for publication work (some newsletters, magazines, and books), whose formatting and layout should be done with a desktop publishing application like Scribus.

latex is hard to use

mystery's picture

LaTeX even don't have graphic interface.

minor typo in the text

Anonymous's picture

I think this is a typo:

headings are usually short enough that you don't need to both with justification for them

I think that the word in that sentence should be bother, not both.

Use LaTeX and all your

Anonymous's picture

Use LaTeX and all your problems are gone

Oh, good -- the inevitable

Bruce Byfield's picture

Oh, good -- the inevitable "use LaTeX" comment, without which no article on is complete.

Now that it's here, I can relax. :-)

Bruce Byfield (nanday)

Bruce Byfield (nanday)

How about user-friendliness?

Anonymous's picture

How about user-friendliness?

User-friendliness ? Use LyX

Anonymous's picture

User-friendliness ???

Try 'lyx'

Well, lyx is not LaTeX. Can

Anonymous's picture

Well, LyX is not LaTeX. Can either of these solve the problem of hyphenation, ie. no manual tweaking necessary?

Well, LyX is LaTeX

Florian Hackenberger's picture

Well LyX in fact is LaTeX according to [1]:
"LyX uses LaTeX as it's backend typesetting mechanism"
This includes hyphenation. LaTeX solves all your hyphenation needs mostly without any intervention at all. If it needs guidance it tells you with messages like "underfull hbox" or "overfull hbox". These messages mean that LaTeX was not able to properly fill a line. You can now add hyphenation dashes to relevant words in order to solve the problem.



What I meant was LyX is a

Anonymous's picture

What I meant was LyX is a front end to LaTeX and therefore very different from a usability point of view. LaTeX is not user-friendly. LyX may or may not be what you like - I personally find OOo friendlier. But anyway, you still have to fiddle with hyphens and the real point is, whatever editor/word processor you use it surely cannot solve "all your problems". Word processing is unfortunately full of exceptions, including both content (special hyphenation, words in other languages etc.) and formatting.

Geek Guide
The DevOps Toolbox

Tools and Technologies for Scale and Reliability
by Linux Journal Editor Bill Childers

Get your free copy today

Sponsored by IBM

Upcoming Webinar
8 Signs You're Beyond Cron

Scheduling Crontabs With an Enterprise Scheduler
11am CDT, April 29th
Moderated by Linux Journal Contributor Mike Diehl

Sign up now

Sponsored by Skybot