Jump to content
We've recently updated our Privacy Statement, available here ×

Global styling preference doesn't work?


artyom

Recommended Posts

Hello There 

I am using jasper reports library 6.17.0 to make nice dfp files wich is lovely)

After lates update I have faced with rectangle border issue - the border became visible (the border was here always but was invisible because overlaping).

<detail> <band height="20" splitType="Prevent">  <rectangle>   <reportElement style="alternateRow" stretchType="RelativeToBandHeight" x="0" y="0" width="539" height="20"/>  </rectangle>  <textField isBlankWhenNull="true" pattern="d MMM yyyy">...........  </textField>................. </band></detail>

screen_shot_2021-07-01_at_8_42.50_pm.png.3e036c0ad916fb1ed35e1ed54c691b54.png

pens still overlaped partyally but visible. Note that my 'alternateRow' styling is not a reason, it do not draw any pens, just overlap the rectabgle's  ones. 

I really want to make it invisible. I can do it easely for certain report like:

<rectangle> <reportElement style="alternateRow" stretchType="RelativeToBandHeight" x="0" y="0" width="539" height="20"/> <graphicElement >  <pen lineWidth="0.0"/> </graphicElement></rectangle>

but  I need to do it globally since I have a lot of smulat templates. As I understood the :

net.sf.jasperreports.style.pen.lineWidth=0.0

property is exactly what i need  (docs: http://jasperreports.sourceforge.net/config.reference.html#net.sf.jasperreports.style.pen.lineWidth) but  can not set it globally.

I have tried to put it into jasperreports.properties file - no luck (note that other jasper props from thatfile applies correctly)

I have tried to set it programmatically in java code like:

var exporter = new JRPdfExporter();exporter.setExporterInput(SimpleExporterInput.getInstance(printJobs));exporter.setExporterOutput(new SimpleOutputStreamExporterOutput(exportOutput));SimplePdfExporterConfiguration conf = new SimplePdfExporterConfiguration();conf.setCompressed(true);exporter.setConfiguration(conf);exporter.getExporterContext().setValue(net.sf.jasperreports.engine.style.PropertyStyleProvider.STYLE_PROPERTY_PEN_LINE_WIDTH, "0.0");exporter.getExporterContext().getJasperReportsContext().setProperty(net.sf.jasperreports.engine.style.PropertyStyleProvider.STYLE_PROPERTY_PEN_LINE_WIDTH, "0.0" );[/code]

No affect!

Eventyally I have put it into JRXML file directly:

<property name="net.sf.jasperreports.style.pen.lineWidth" value="0.0"/>Doesn't help.Dear support, could you please let me know what I am doing wrong?Thanks[/code]

 

 

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Popular Days

Posted Images

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...