How to use gujrati font In jasper Report with Java

0

I have installed shrti.ttl in iReport Tool and export extenstion as Jar of this to use this In java code.

Its properly display content in iReport, but when I exportReportToPdf in java code ...its properly not displaying content

some two three words are displaying not properly

in Java simple code look like 

JRBeanCollectionDataSource ds=new JRBeanCollectionDataSource(beanData);
jasperPrint = JasperFillManager.fillReport(jasperReport, parameters, ds);

JasperExportManager.exportReportToPdf(jasperPrint);

 

and Ireport xml file simple code like

 

<staticText>
                <reportElement x="72" y="530" width="571" height="185" uuid="74ab227f-bb7b-4ca2-9b00-acd0dfd74ad6"/>
                <textElement>
                    <font fontName="Shruti" size="12" isBold="false" pdfEncoding="Identity-H" isPdfEmbedded="true"/>
                </textElement>
                <text><![CDATA[ર્પાછળ વાળી જગ્યામાં

 પ્રધાનમંત્રી   દ્રારા ભરપાઇ કરવામાં આવેલ હોય

 આથી સોપવામાં આવે છે.]]></text>
            </staticText>

 

also ref

lotiyahardik's picture
Joined: Sep 20 2017 - 7:17pm
Last seen: 2 years 1 month ago

1 Answer:

0

iReport has some problem with external fonts. Try using JasperSoft Studio.

hozawa's picture
52292
Joined: Apr 24 2010 - 4:31pm
Last seen: 5 months 4 days ago
Feedback
randomness