Jump to content

eliminating most of the px image use


raffimd

Recommended Posts

Hi,

I wanted to eliminate the use of px image in the generated HTML file for couple of reasons.

1)Generated HTML file size is larger than

2)Firefox is not picking up the relative path to px due to some environment issue in my project.

 

I quickly figured out that I can set a flag in the parameters map as mentioned below:

Code:

JRHtmlExporter exporter = new JRHtmlExporter();
exporter.setParameter(JRHtmlExporterParameter.IS_USING_IMAGES_TO_ALIGN, Boolean.FALSE);

 

This really avoided the use of px image at all the places except the place holder for the image element which is optional.

This is pretty good.

Is there a way to avoid the use of px file even for the image element place holder?

 

By setting this parameter, will I have any problem in any of the browsers?

Thanks,

Raffi

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Hi,

 

I think you should log this as a feature request as it is not possible to achieve right now (for images having onErrorType="Blank").

 

Px images were used because older browsers did not rendered HTML the same way when precise measuremente were needed. I guess with more recent browsers this is not a problme anymore, and this is why we introduced this option to get rid of the px image.

 

I hope this helps.

Teodor

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...