[#4782] - Copy Text Measurer From JasperServer to JasperReports

Category:
Feature request
Priority:
Normal
Status:
Acknowledged
Project: Severity:
Minor
Resolution:
Open
Component: Reproducibility:
N/A
Assigned to:

On JasperServer there is a "net.sf.jasperreports.text.measurer.factory" called "com.jaspersoft.jasperserver.api.engine.jasperreports.util.SingleLineTextMeasurerFactory" available as an option.

This does not exist under JasperReports. Please add it there.

rw-network's picture
1121
Joined: Mar 1 2007 - 3:44am
Last seen: 6 years 8 months ago

2 Comments:

#1

Does the below change make resolving this issue unneeded? Or was that change the resolution to this issue?

JasperReports 4.5.0 Change Log
===================================
- optimized text measurement for short and simple texts, to speed up report filling process;

#2

The optimization implemented in JasperReports 4.5.0 differs from the SingleLineTextMeasurerFactory present in JasperServer. The goals are similar, but the implementation and some details differ.

The optimization applies to single-style texts that fit on a single line (and that don't have tabs). Such texts are measured using a faster method than the original one, and the measurement result should be identical to the one produced by the old code. In other words, the change should be transparent to any code other than the measuring code. The optimization is part of the default text measurer and is applied by default.

SingleLineTextMeasurerFactory stores and reuses measurement results based on style attributes, and completely skips measurements in some cases. The drawback is that the measurer does not guarantee exact measurements.

The 4.5.0 optimization is just the first step, we'll continue to look for ways of speeding up JR.

Regards,
Lucian

Feedback
randomness