开发者

Sharing look and feel between many pentaho prpt report

I have a bunch of pentaho reports (prpt) generated by Pentaho Report Designer (PRD) and I would like to change the reporting style (font, logo, colours) on all of them, but I need to be able to change them from time to time and quickly (customer customization)

Question: Is there any way to keep the styles outside开发者_JAVA技巧 prpt and shared between all of them?

It's anoying to change one by one. Im not using BI server, just the report engine.


You can encapsulates your styles into the report environment by

(1) Putting your style information into properties in the "classic-engine.properties" file in the report designer's resources directory (and by creating or copying that file into your application's classpath as well).

(2) Using style-expressions (a formula on the style properties, definable via the green-plus on the element) and attribute expressions to pull in the information from the report environment into the formulas. Formulas can read environment information via the "ENV(..)" formula function.

For reference:

Logos are defined by given the path to the file or a URL in the "value" attribute of a image-element.

Fonts can be set on the font-name style by giving the logical font name, font properties like size and bold/italics goes with the appropriate boolean value. Colours can be given as hex codes in the format "#rrggbb" or for certain colours as literal string (all defined HTML colors are accepted as well as all constants defined in java.awt.Color.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜