Bug 153316 - [Improve Page Break Management] Support for Page Sequences as described in Page Setup Spec
Summary: [Improve Page Break Management] Support for Page Sequences as described in Pa...
Status: NEW
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: BIRT (show other bugs)
Version: unspecified   Edit
Hardware: All Windows XP
: P3 enhancement with 6 votes (vote)
Target Milestone: Future   Edit
Assignee: Vincent Petry CLA
QA Contact: Xiaodan Wang CLA
URL:
Whiteboard:
Keywords: plan
: 266290 292387 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-08-09 12:11 EDT by Stefan Gross CLA
Modified: 2010-05-18 06:35 EDT (History)
10 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Gross CLA 2006-08-09 12:11:40 EDT
As of BIRT 2.1 page sequences as described in the Page Setup Specification document are still not supported.

There seems to be no way to use a different master page for the title page, when
the Report body is just a simple list of records. In this case the multiple master page support is not applicable, because there is no element which can switch to another master page on from the second page of the report.

Please add support for page sequences to support the simple case of using one Master Page for the Title and some othe Master Page for following pages.
Comment 1 Wenfeng Li CLA 2006-08-09 19:02:11 EDT
On the title page, do you want to show the report title only, or you want to show the title AND some rows in the simple list of records?

Do you have grouping on row no so that in HTML the simple listing will have page breaks?
Comment 2 Stefan Gross CLA 2006-08-10 01:43:01 EDT
(In reply to comment #1)
> On the title page, do you want to show the report title only, or you want to
> show the title AND some rows in the simple list of records?
> 

The title page shall contain rows of the simple list of records AND the some fields which shall be displayed below this records (in the footer section).


> Do you have grouping on row no so that in HTML the simple listing will have
> page breaks?
> 

No, I have no grouping enabled at the moment.
Comment 3 Stefan Gross CLA 2006-08-10 15:02:08 EDT
I found a workaround for my problem by using a global variable
and changing the value in the onPageBreak Event of the record list table.

Report has two master pages "Title" and "Body", default for record list is
"Title"

ReportDesign initialize
=======================
reportContext.setGlobalVariable("TitlePage","true");

Table onPageBreak
=================
reportContext.setGlobalVariable("TitlePage","false");

Table->Detail->Row onCreate
=========================
if (reportContext.getGlobalVariable("TitlePage").equals("false")) {
	this.getStyle().masterPage = "Body";
}


But this will introduce some overhead, since the check has to be done for
every row in the onCreate event.

As long as there is no page sequence implemented (adjusting the Page Setup
Spec would be fine), maybe this can be documented for the Title Page use case?

Cheers
 Stefan
Comment 4 Wenfeng Li CLA 2006-08-10 17:17:53 EDT
I am thinking a solution that

1) create a group on the row_no with N # of rows
2) set page break on this group as always except first group.
3) in the onpageBreak() script for this group
this.getStyle().masterPage = "Body";
Comment 5 Stefan Gross CLA 2006-08-11 10:20:02 EDT
(In reply to comment #4)
> I am thinking a solution that

> 3) in the onpageBreak() script for this group
> this.getStyle().masterPage = "Body";

Setting the masterPage property during onpageBreak() has no effect, at least for the PDF Emitter in Build N20060808.

My findings are, that it works in onCreate() only.
Comment 6 Wenfeng Li CLA 2006-08-14 14:51:27 EDT
+1 to support two usages in onPageBreak() scripting:

(1) switch to a different pre-defined master page
(2) change the contect/properties of a pre-defined master page.
Comment 7 Wenfeng Li CLA 2007-05-21 01:19:35 EDT
add plan key word.
Comment 8 Stefan Gross CLA 2008-02-10 06:46:33 EST
Since there was no activity quite a long time and originally the target once was 2.1 - any news regarding this request?

Cheers
 Stefan
Comment 9 Wenfeng Li CLA 2008-06-09 20:32:02 EDT
wei, please consider this usage when you work on the page model enhancement project.
Comment 10 Wei Yan CLA 2009-03-02 02:15:22 EST
*** Bug 266290 has been marked as a duplicate of this bug. ***
Comment 11 Wei Yan CLA 2009-05-18 02:02:37 EDT
defer to 2.5.2 for resource issue.
Comment 12 Jan Linders CLA 2009-08-21 10:28:25 EDT
No sure what is done on this request, however I'm also interested in a solution to have a different Masterpage on odd and even pages.

For example,   Invoice document (duplex)

I would like to have on the first page the Header, details and footer. On the second page a complete text page of Terms & Conditions.
This will be the back page of a duplex page.

So Invoice data on the front and T&C's on the back.

If the Invoice has more lines than will fit on the first page, a third page
with remaining details and footer should be printed, followed by a fourth page with the T&C's again.

Not sure if this can be done in a different way then specifying a different 
masterpage per page.

Looking forward to a possible solution.

Regards,,,,
Comment 13 Wenfeng Li CLA 2009-09-16 19:55:38 EDT
schedule to 2.6 to allow more time to work on this enhancement.
Comment 15 Zhiqiang Qian CLA 2010-05-18 06:35:46 EDT
*** Bug 292387 has been marked as a duplicate of this bug. ***