Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
Page Numbers Representation in daisy
In Daisy page numbers are marked with the <pagenum> tag. The <pagenum> tag must be placed at the top of a page, regardless of where the page number is located on the print page, so that the end user will be positioned at the beginning of the page when he or she navigates to it. To ensure accurate navigation, the markup at the beginning of a major structure (part, chapter, section, etc.) must follow a precise order. The order should always be: level1-6 tag, pagenum, and heading. This will ensure that if end users navigate to the beginning of the major structure (as marked by the level1-6 tag) and begin playback, they will hear both the page number and the heading of the major structure.
There are three types of page which are distinguished in the markup through the use of "page" attribute.
It is used to mark the page numbers used in the front matter of most books (most often roman numerals but sometimes Arabic). Regardless of the type of page numbering used in the book, pages located in the front matter, preceding the body, is marked up as
It is used to indicate variant pagination schemes used in some books, for example hyphenated numbers often used in appendices (A-1, A-2, etc.). It is also used to mark up pages without page numbers, for example, pages with photos which occur between sequentially numbered pages.
It is used to indicate that the content of the number is the standard Arabic numeral used in the body and rear matter of most books.
Page Number Representation in WordML
1. Create a header or footer that contains only the page number in Office 2007
On the Insert tab, in the Header & Footer group, click Page Number.
Xml code representation:
<w:fldSimple w:instr="PAGE \* MERGEFORMAT">
2.Insert a manual page break
Xml code representation:
<w:p w:rsidR="00897FD0" w:rsidRDefault="00897FD0">
<w:br w:type="page" />
This will not display the page number. This will only give breaks the page and inserts a new blank page.
3. Last Rendered page break
This element specifies the position of the end of a page when this document was last paginated while saving the document.
Example: Consider a run which consists of the text, “This is the end of the page”, and was the last word on a page. If the application saving this file had paginated this content, that information may be saved with the file as follows:
<w:p w:rsidR="005752AD" w:rsidRDefault="005752AD" w:rsidP="005752AD">
<w:t> This is the end </w:t>
<w:t xml:space=”preserve”> of the page </w:t>
The lastRenderedPageBreak element indicates that there was a page break resulting from pagination of this content, which occurred between the word end and the word of.
This element can be used by applications to specify the locations of page breaks within a document
when it is saved as WordprocessingML, in order to allow other applications (e.g. assistive software) to utilize this information when reading the document.
However, there are certain rare scenarios where we will not be able to get “Last Rendered Page Break” value and page number information will not be converted accurately. (According to specification when the document author is breaking a run then <lastRenderedPagebreak> will occur, otherwise it will not occur.)
All the identified scenarios will be explicitly mentioned in the Authoring guidelines.
• Option 1 cannot be used in the Daisy Translator because if page numbers in a word documents are inserted in this way then Daisy Translator will not be able to get current page number information.
In the code snippet for option 1 <w:t>1</w:t> will remain as 1 even if the current page is 5.
• Instead we can use information by combining option 2 and 3 to generate page number information.
That is we will be considering <w:lastRenderedPageBreak /> and <w:br w:type="page" />.
• Word2007 does not support DTBook concept of “special” and “front” page number types, so we are only converting page numbers that are of type “normal”.
Note: Even if page numbers are inserted using option 1 in a word document we will still have Last rendered page break information which can be used.
Response from Joel Håkansson :
Regarding page numbers:
Combining option 2 and 3 seems to be the right approach.
As I understand the current design, the plan is to number pages based on their position within in the document. The upside of that approach is that page numbers are unique at all times; the downside is that the author may refer to a page that cannot be found in the Daisy book.
In my opinion, it is the page numbers that the author would refer to that are of interest here. I.e., if a document contains numbering such as A, B, C, D etc, then the output should have the same numbering scheme (this would also imply that page="special" should be used for such numbering schemes). I still think that option 2 and 3 is the right approach for page number placement, but how to get the value of the page number is another question.
Response from George Kerscher :
Joel, thanks for your thoughts.
The whole page number is difficult and we appreciate the thought you are giving to this.
I have a question regarding the use case where an organization is using Word to create content that is in an existing printed book. For example, a 500 page book on history. The organization scans the book and breaks it into a front matter file, ten chapters, and a rear matter file. for a total of 12 files. They have a person clean up OCR recognition errors. They then need to insert page numbers where they occur in the printed book.
Might it be possible for the translator to be set to ignore the automatic pagination and rely only inserted text of a specific style? Could three styles be created, one for front, one for normal, and one for special? Then the editor could say insert:
VI with a style front
23 with style normal
A-2 with style of special.
The conversion then takes this content with the specific style and turns it into:
Of course you could not mix and match the page numbering export routine; it would either be the automated process you suggest or the manual identification by style.
I was just reading the DAISY forms on the save as DAISY plug and saw that pages will be added to the next release of the plug in. http://forums.daisy.org/viewtopic.php?f=5&t=12
I wanted to know what convention is going to be used for the page numbers?
I agree with the convention that George Kerscher outlined would be great using styles.
Some of the befits could be:
Allowing the authors to put in pages numbers where they want them.
Authors could leave page numbers out of a document if it is not relevant.
Custom page numbers could be created like roman numerals, A-1, etc.
Front and back matter pages could be marked up.
Thank you for all the great work,
In this release (march 20th) We are supporting the usual Page number insertion method in the word.
In Word application, Page numbers are populated in the header or footer part of the document.
To insert a Page number in a document, navigate to insert tab, this tab has “Header & Footer “group of buttons. In this group ‘Page Number’ button is present.
On click of the Page Number button, user will be provided an option to insert a page number either in the Top of Page or Bottom of Page.
On click of the “Top of Page” or “Bottom of Page”, user will be shown a gallery of page number designs. Clicking on the page number design will insert a page number in the document.
If the user inserts the Page number in the Top of Page, it will be inserted in the header and if the user inserts the page number in the Bottom of page, it will be inserted in the Footer part of the document.
Any word document is having one default section and the header and footer are belongs to that section.
User could break the document into multiple sections. Page numbers could be inserted to each section of the document with different page number formatting.
User could format the page numbers by clicking on the “Format Page numbers …” option of Page Number button in the “Header & Footer” group of buttons.
User can format a page number with one of the number format mentioned below in the Page Number Format dialog box
The translator will identify the page number format applied and will populae appropriate type like normal or special.
In the next release (Milestone 4), we will support styles as George mentioned for Page numbers. user could chosse either Automatic or manual page numbers.