Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 331976 - BIRT putting css classes forcefully on report
Summary: BIRT putting css classes forcefully on report
Status: RESOLVED WORKSFORME
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: BIRT (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 normal (vote)
Target Milestone: 3.7.0   Edit
Assignee: Birt-ReportEngine-inbox@eclipse.org CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-07 00:21 EST by Pulin Pathneja CLA
Modified: 2011-05-26 13:32 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pulin Pathneja CLA 2010-12-07 00:21:41 EST
Build Identifier: 

We have tab structure in web page where the reports are getting rendered. one tab contain single report and another tab club both the reports.

Now the problem is first report(in 1st tab) comes very nicely but in 2nd tab(contains second report+first report) is totally cluttered. Both are using the same style sheet which is being linked (not imported).

some of the elements are taking classes which are not applied to them. 


More Details regarding the bug can be found at 

http://www.birt-exchange.org/org/forum/index.php/topic/20952-birt-putting-css-classes-forcefully-on-report/page__p__70427__fromsearch__1&#entry70427



Reproducible: Always

Steps to Reproduce:
1. Create two reports
2. Apply style sheet to them
3. Include these two reports in one page

The whole reports would be cluttered. When the reports would be seen individually, it would work fine.

The reason for this is while rendering of the report report engine changes the class name of the style to style_1, style_2 etc. from the original names. As these two reports are rendered separately. So these styles contradict with each other.
Comment 1 Wei Yan CLA 2010-12-07 12:28:02 EST
You can use the HTMLRenderOption.setHTMLIDNamespace set the name prefix, so the name won't conflict with each other.
Comment 2 Xiaoying Gu CLA 2011-04-12 04:12:50 EDT
After use options.setHTMLIDNamespace("REPORT_PREFIX");
 before rendering the report, the generated sytle name will be .REPORT_PREFIX_style_0{...}

Set as worksforme.