[Solved] Headers with multiple fields and justifications

Discuss the word processor
Post Reply
Pete Ford
Posts: 41
Joined: Thu Oct 09, 2008 6:52 pm
Location: Colorado, US

[Solved] Headers with multiple fields and justifications

Post by Pete Ford »

I need to be able to set up headers that have two things at the same time:

- the page number, left-justified on left pages, right-justified on right pages
- the chapter title, centered

More than that, in a mirrored layout I'd also like to be able to put the chapter title as above on the right pages, but the document title centered on the left pages. (To get an idea of what I'm trying to do, take a look at a page of a paperback fiction book.)

I've been through the help pages and done some searching in the forum but I can't figure out how to do this - in fact I'm beginning to think Writer can't do it. Does anyone know how to make this work?
Last edited by Pete Ford on Sat Oct 11, 2008 8:16 pm, edited 1 time in total.
OOo 3.0.X on Ms Windows XP
User avatar
RGB
Posts: 1456
Joined: Mon Oct 08, 2007 1:34 am

Re: Headers with multiple fields and justifications

Post by RGB »

First of all, edit your page style and on the Header tab, activate headers and un-check "same content on left and right pages"
Now, you have two options:
1- Insert a three cell table in the header of a right page, select no border for it and set the alignment on each cell as needed. Repeat the same for a left page.
2- Go to tools -> Options -> OpenOffice.org Writer -> Compatibility and check "use tab format of OpenOffice.org 1.1". Now, on a left page header, for example, insert the page number field, press tab, insert the chapter field: if you are using the default header style everything is OK now. With this "compatibility option" you can have different alignments on the same paragraph. If you use a custom header, be sure to set the first tab stop in the middle of the paragraph.
NOTE: don't use the second option if you need to export the document in M$Word format.
There are two types of people: those who believe that there are two types of people and those who do not.

openSUSE Leap with KDE Plasma / LibreOffice
Pete Ford
Posts: 41
Joined: Thu Oct 09, 2008 6:52 pm
Location: Colorado, US

Re: Headers with multiple fields and justifications

Post by Pete Ford »

The table option may do the trick, although it inserts the table above the header line rather than inside - this may be fixable by adjusting the spacing below the header. Also, until I can try it properly I can't be certain it'll propagate across pages correctly - it's Saturday and I won't have time to test things until later or tomorrow.

In the meantime I'll mark this solved; if it turns out otherwise, I'll come back to it. Writer has proved to be very flexible and although I think something like this could be made much easier, I'm fairly sure there will be some way to make it work, maybe with a little messing about.
OOo 3.0.X on Ms Windows XP
Pete Ford
Posts: 41
Joined: Thu Oct 09, 2008 6:52 pm
Location: Colorado, US

Re: [Solved] Headers with multiple fields and justifications

Post by Pete Ford »

This appears to be working ok although I did have to mess around with it a bit to get things just right. In case anyone else needs to create a template that handles this, here are a few pointers. Note that my page style is set to "Mirrored". Start with a blank document using the default template.

1 - Create two new paragraph styles based on "Header" and "Header Left". Set the font/size characteristics here.
2 - As noted in the earlier post, in the page style enable headers and switch off "same both sides". Set the spacing to ZERO.
3 - Select the header on the template page, switch the para style to the one you created (based on "Header") then Insert-Table, 3 columns, one row, no header, no border. This should create a table with the correct font settings, ABOVE the header.
4 - Select left-justify for the left column, centre-justify for the middle column, right-justify for the right column. The first template page should be a right page so click in the centre column and Insert-Field-Title; click in the right column and Insert-Field-PageNumber.
5 - Go back to the main page body and hit return (or type some text, or whatever) enough to roll over to create the next page.
6 - As step 3, but use the para style you created based on "Header Left".
7 - As step 4, but put the page number in the left column instead of the right.
8 - Delete the text you created at step 5 so that you're back to one page.
9 - Save the template (File-Templates-Save).
OOo 3.0.X on Ms Windows XP
sergiozambrano
Posts: 30
Joined: Sat Jun 06, 2009 9:44 am

Chapter field?

Post by sergiozambrano »

Where is the chapter field?
Mac user since MacPlus. Web/Wordpress plugin/custom theme dev/designer.
Former print designer, DTP/pre-press expert 23+ ys exp. digital Illustration, photography and DTP apps Mac/PC.
http://socialblogsitewebdesign.com Official web of Blogsites.
Oo321
Post Reply