Applying page styles and page numbers

Discuss the word processor
Post Reply
wenfengru
Posts: 3
Joined: Sun Jun 24, 2018 6:57 am

Applying page styles and page numbers

Post by wenfengru »

I'm sure this is discussed ad infinitum, but I'm really struggling here.

I understand that there's not an easy way to suppress page numbers in the document. However, I have page numbers in my footers and need to remove them on the first three pages of a document.

I understand that I'm supposed to use page styles for this. However, I've now read half a dozen things about how to do this and nothing is working. Perhaps part of the issue is that I already have the pages formatted unusually - they're set for an unusual size. Otherwise I could use the "first page" style, I think.

Basically, I go, I click on page styles, I create a new one... and nothing happens. There are manual page breaks between the first page and the second, but changing the content of the footer still changes it everywhere. There must be a way to do this. However, from the way page styles works, I honestly can't even tell if I've done anything at all. It's clearly meant for advanced use only.

Thanks in advance!
LibreOffice 5.0.4.2 on Windows 10
User avatar
Zizi64
Volunteer
Posts: 11362
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: applying page styles and page numbers

Post by Zizi64 »

Basically, I go, I click on page styles, I create a new one... and nothing happens.
It is not enough to create them, but you must apply the created page style for the document.
Use the menu item: Insert - Manual break - Page break - with a different Page Style... instead of the shortcut key "Ctrl-Enter".


It is very inportant: the page styles will work in the native ODF (.odt) file format only. The binary MS file format (.doc) can not handle the real page styles.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
wenfengru
Posts: 3
Joined: Sun Jun 24, 2018 6:57 am

Re: Applying page styles and page numbers

Post by wenfengru »

So, I have now set up two different styles - one that has page numbers and one that doesn't but otherwise, they're the same.

All my manual page breaks were applied by using control-enter already - I'm not even sure where the page break button is.

If I double click the style, it applies it everywhere. If I hit a new manual break by pressing control-enter and then applying a new style, it applies that style everywhere, regardless of what page the cursor is on. If I try selecting the pages by highlighting the text and hitting the style I want just for them, nothing happens at all.

I'm sure I'm asking the stupidest question ever, but how do I get the style to apply to some pages and not others. How do I control where it goes? None of the tutorials I'm looking at seem to address this. They act like it's going to be obvious, but it's really not, at least not to me.

Thanks!
LibreOffice 5.0.4.2 on Windows 10
wenfengru
Posts: 3
Joined: Sun Jun 24, 2018 6:57 am

Re: Applying page styles and page numbers

Post by wenfengru »

I referred back to the help guide. It says that to apply a new style, you make a manual break and apply the new style. Except it's definitely not working for me. I hit a brand new manual page break then double clicked the style and the style went everywhere throughout the document. Is this perhaps because my document already has multiple manual breaks? I can't really remove them at this point. They're integral to the document.
LibreOffice 5.0.4.2 on Windows 10
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: Applying page styles and page numbers

Post by Bill »

wenfengru wrote:...it's definitely not working for me. I hit a brand new manual page break then double clicked the style and the style went everywhere throughout the document.
Since you inserted the page breaks using CTRL+ENTER, you have simple page breaks that just start a new page with the same page style on both sides of the break. To change the page style of a page with such a page break, right-click the first line on the page and select Paragraph. On the Paragraph dialog, select the Text Flow tab. In the Breaks section, tick "Insert" and "With Page Style". Open the drop down list next to "With Page Style" and select the new page style. You can click the Help button on the dialog for help with the settings.
AOO 4.1.14 on Ubuntu MATE 22.04
User avatar
Zizi64
Volunteer
Posts: 11362
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: Applying page styles and page numbers

Post by Zizi64 »

I referred back to the help guide. It says that to apply a new style, you make a manual break and apply the new style. Except it's definitely not working for me. I hit a brand new manual page break then double clicked the style and the style went everywhere throughout the document. Is this perhaps because my document already has multiple manual breaks? I can't really remove them at this point. They're integral to the document.
Manual Break is not equals as the Page Break: as Bill described above.


There is an another way to apply a new Page style in a document:
It works with pages that you need only one page in a document - like the First Page for the cover sheet, or an another page style for the inner side of the cover sheet (if you want print the document double sided on the paper), or when one page is enough for the "Contents" list, etc...)
You can set the property "Next style" in the settings of an existing page style.
If you choose the name of an another page style at this point, then the another page style will be applied automatically when the text flows onto the next page (or when you apply a Page break by hitting Ctrl-Enter).
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: Applying page styles and page numbers

Post by John_Ha »

You may find this explanation helps your understanding.

You can get full information on Page Styles, Page Breaks and Page Numbering in Chapter 4 - Formatting Pages of the Writer Manual. Also see the Writer Tutorials where you will find [Example] Document structure and numbering and [Tutorial] Page numbering.

Be sure to download the two files in [Example] Document structure and numbering and format the example file - it will help you immeasurably.

It's all about Page Breaks.

It is very useful to make Page Breaks visible by Tools > Options (Preferences on Mac) > OpenOffice > Appearance > scroll to Text document > tick Section boundaries > choose a colour for Page and column breaks. Page Breaks now show on the screen as a thin coloured line and identify all Page Breaks. This is the default setting on later installations where Page Breaks appear as a thin blue line.

Also be sure to Set View > Non printing characters ..., to ON to see the paragraph breaks.

Page numbers

Page Numbers follow on sequentially from the previous page and there is nothing stored in the document to tell you what a given page number is because, apart from where a change is made, each page number is calculated by how far away from "its start" it is.

If you want to change the Page Number you must insert a Page Break and set the new Page Number. Go Insert > Manual Break > Page Break..., and a small pop-up window allows you to change the Page Number for the first (and hence subsequent) page(s) following the Page Break.

The Page Number you set is stored as an attribute of "the first paragraph on the page following the Page Break where the change in number is made". It can be seen, and changed, by placing the cursor in "the first paragraph on the page following the Page Break" and going Format > Paragraph > Text Flow .... The value " 0 " here means "page number follows on from the previous page number". Any value 17, 23 … etc means that this page starts at 17 or 23 etc.

There is an exception. If you define Page Style Fred to have a "Next Style Bill" then when you insert a Page Style Fred, the next page will automatically become Bill. In this case there is no Page Break between Fred and Bill, and Bill's "start" for numbering is Fred. Format > Paragraph in the first paragraph of Bill has no pagination information.

Page Styles – changing headers, footers and/or page formats

The Page Style following a Page Break can be exactly the same Page Style as the page before the Page Break or it can be a different Page Style.

If you want to change a header, change header text, change a footer, change footer text, change the page number, hide page number etc, you must insert a Page Break and you must select a Page Style which makes the change you want.

If you want to change the Page Style you must insert a Page Break and set the new Page Style. Go Insert > Manual Break > Page Break..., and a small pop-up window allows you to choose the Page Style for the first (and hence subsequent) page(s) following the Page Break.

Page Styles (and hence changed headers and footers); Page Breaks and Page Number are an attribute of "the first paragraph on the page following the Page Break where the change in number is made" even if the paragraph is empty or is a Heading (or is a table at the very top). Note that Heading means a Heading 1 or a Heading 2 etc, and not a Page header as in header/footer.

You can also manually insert or delete a Page Break; manually choose the Page Style (and hence change headers and footers); and manually change the Page Number; by placing the cursor in "the first paragraph on a page following a Page Break" and going Format > Paragraph > Text Flow > Breaks ... (or in the table, and going Table > Properties > Text Flow...) where all these options can be changed.

You can also delete a Page Break by Backspace, or by deleting highlighted text which includes the Page Break.

Debugging problems with page numbers or page styles, headers and footers

Debug Page Style changes / changed page numbering / changed header problems by placing the cursor in "the first paragraph on the page following the Page Break where the change in number is made" and going Format > Paragraph > Text Flow > Breaks .... What is the document telling Writer to do following the Page Break? If you see nothing there to cause the change, the document has become corrupted and (much!) more diagnosis is required. Remember if the Page Number here is " 0 " it means “page number follows on from previous page ...”

Be aware that there is no Page Break between different Page Styles if the second Page Style (Bill) is defined as the Next Style in the first Page Style(Fred). See Fred and Bill above.

Two words of caution

1. You can go Format > Page ..., and edit the format of the page in which the cursor is currently located. However, you are actually editing that page's Page Style, so all other pages which use that same Page Style will also have their formats changed.

2. Do not manually change the page number by editing any paragraph, not even the first paragraph on a page. You must only edit "the first paragraph on the page following the Page Break where the change in number is made". If you edit any other paragraph to change page number your document will go horribly wrong.

Showing that a problem has been solved helps others searching so, if your problem is now solved, please view your first post in this thread and click the Edit button (top right in the post) and add [Solved] in front of the subject.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
Post Reply