Jump to content

Re:i18n problem--Pleazzzzzzzz help


mana_singh01

Recommended Posts

Hi Teodord,

 

Thanks a lot for your reply.

May be you haven't seen my reply yet. So, m posting it as a new post.

I will explain my requirement a bit more.

I know I can set the pdffontname etc for a text field. In my application there are two locales. one is english & the other is japaneese. So, when the locale is english the reports come up fine with verdana as font.(I have downloaded verdana.ttf as my pdffont.) However, this font does not show japaneese characters when the locale is japan & report reads the japaneese property file. For that if I make my pdf font as MSMincho or MsGothic...the report displays in both english & japaneese(as per the locale). However, my client does not want the font to be MSMincho for english reports. He wants the font to be vardana if the locale is english & MSMnicho when the locale is Japan. Would u suggest me a way to solve this problem?

Please help Teodor.

 

Thanks & Regards,

MS.

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Hi,

 

There is no need to post the same message again and again.

 

Rest assured that we see all the messages coming in.

Is just that we do not have answers for all of them and sometimes we do not have enough time to answer everybody.

But by posting the same message multiple times, you will not get better results anyway.

 

Thank you,

Teodor

Link to comment
Share on other sites

Hi Teodor,

 

I apologise for causing any inconvenience, if any. However, I didn't intend that. I just thought may be you will see the new post for sure as I was desparately looking for a solution & I still am.

Talking about the fontmap thing that u suggested. I can for sure create a fontmap & put it as an exporter parameter. However, my problem of conditionally specifying a font in the jrxml remains as is.

 

I don't see any such thing in the fonts or any other samples provided in JR.

You have always helped Teodor & I hope the same this time also.

Thanks & Regards,

MS.

Link to comment
Share on other sites

Hi,

 

If it is not about only about changing font mappings when exporting to PDF and you also need to change fonts at report fill time (fontName attribute in JRXML), then you could make all your text fields use a report style and change the fontName of this report style at runtime, using the setFontName() method.

Take a look at our /demo/samples/alterdesign sample where we dynamically change the color of some elements on a compiled report template (JasperReport object).

What you need to do looks close to this.

 

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