Secondary page numbering scheme solution outline in sight!!! Need help!!!

  • Thread starter =?iso-8859-1?q?Jean-Fran=E7ois_Michaud?=
  • Start date
?

=?iso-8859-1?q?Jean-Fran=E7ois_Michaud?=

Hello all,

I came up with a potential solution for creating a secondary page
numbering scheme within the same document when transforming to FO!

I need a little bit of help to crystalize it because it is not entirely
trivial. I see the outline of the solution but if anybody has ideas to
facilitate this process, it would be most welcome.

This solution will enable anybody to output a secondary numbering
scheme in their document; this is a serious direct functionality
shortcoming well known under XSLT.

At first I thought I would have to process the document twice with 2
different stylesheets but this doesn't seem to be necessary anymore.

1- Basically, I output the document as I want it under the most generic
page number scheme so that we can get (page) of (total number of pages)
wherever we want it in the page (the footer for example). The totality
of the document is processed; including the sections that need a
secondary page numbering scheme.

The sections that require a secondary page numbering scheme are then
REPROCESSED with a modified initial page and appended at the end of
the document. That way, if the last-page block id is set at the end of
the firstly processed document (before the reprocessed sections are
appended to the new XML tree), the total number of pages comes out
properly on every page of the document except for the funky appended
section(s). This appended tree can NOT be part of an RTF because the
page numbering information contained within it is dynamically generated
at run-time by the FO engine. (If generating PDF for example, the funky
appended reprocessed bits of FO can simply be ignored in the final
output).

2- The second part of the process I'm trying to figure out right now is
how to dynamically reference the proper element at which a given new
page will occur to be able to lay down a unique <fo:block
id="something"> in front of every element that can occur in the section
that will require a secondary page number scheme (to eliminate
ambiguous conditions, templates used to process nodes in those sections
will have to be duplicated so that the current page at which the
element is processed can be known and outputted properly through an
<fo:page-number-citation ref-id="something" line-height="0pt"/>

This is what I have so far. It looks very promising but still needs a
bit of work.

Any help would be greatly appreciated. Not only will you help me, but
countless others in the comunity that need to output similar results.

Regards
Jeff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top