Jump to content

blaguman

Members
  • Posts

    47
  • Joined

  • Last visited

 Content Type 

Forum

Downloads

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Events

Profiles

Everything posted by blaguman

  1. Hello everybody ! I know this problem is frequent, but I have a question concerning what says Teodor about fonts : In case of a font not available on every system, he says to "make sure you rely on some TTF files that you ship with your application and install them on-the-fly using the Font.createFont() method" I indeed have ttf files, and my reports print correctly the text in these fonts, but do the measure with a default font, with different metrics, 'cause the system does not know the font. How can I create a font on-the-fly ? I created the font with the createFont method, and I have a Font object, but what do I have to do with it ? I tried to build a <FontKey, Font> map, and pass it to the exporter through the JRExporterParameter.FONT_MAP element, but the types do not match (a PdfFont is required, not a Font). So what's the difference between JRExporterParameter.FONT_MAP and JRPdfExporterParameter.FONT_MAP, by the way ? I'd really like my application to work soon, so your my last chance... :) If someone could give me a way to deal with that, it would be very welcome ! Regards, Morgan
  2. Hello !Yes, this is frequent, and I've already been confronted to that issue.For your question, yes, I think these two fonts are equals, and have the same metrics...But one question, by the way, if someone's reading that : how do you get asian fonts to match (fontName & pdfFontName) ?!Does the STSong-Light, for instance, have a metrics-like font in java awt ?! Regards, Morgan
  3. Hello Lucian !ÔH YEAH it works !I thought about that yesterday and I just tried it.In fact, it's just I didn't understand the pdfFontName should represent an existing font on the JVM.I thought the key I gave to my FontMap was just an alias I could use from wherever I wanted. But when I tried to give the FontMap some keys whose name existed on the JVM, it started to work...Thank you, see you soon ! :) Regards, Morgan
  4. Hi... I attach the jrxml file, just in case.. Regards, Morgan
  5. Hi everybody, hmm, I was wrong, the problem is not solved in every case. I still have some of my fields which leave a blank line under them, as they would need more place to print themselves. I join a screenshot so I'm sure you'll understand... In the example, the red frames show where a unnecessary blank space is placed. For instance, if I try to add some characters at the end of the first line, they're still printed on the same line, so there's enough space left, but this line shows anyway... Any clue...? Thank you very much Regards, Morgan Post Edited by blaguman at 06/05/2009 07:32
  6. Hi ! you should try passing your Collection to your main report instead of the JRMapCollectionDataSource. Pass your masterList (etc...) object and then, in the subreport expression, give the subreport something like that : new JRMapCollectionDataSource((Collection)$P{manifestDS}) Tell me if it solves the problem :) Regards, Morgan Post Edited by blaguman at 05/28/2009 14:19
  7. Hi Telos, I think you can make your subreport to return a value. Maybe you could try that way ?
  8. Hi Andrew, Could you be more specific about the way you want your data to be printed ? Do you have to print one account number, and then the associated transaction, then the others, etc... ? Could you attach the jrxml files ? Regards, Morgan
  9. Teodord... THANK YOU ! It works ! I really don't understand how it could be this unpredictable (most of the time, the cursor spotted the first record), but it's now OK ! Thank you again, and see you soon ! Morgan
  10. I was limited on file attachments, here are the last jrxml files...
  11. Hi Theodor, and thank you very much for your response ! First of all, I never pass the REPORT_DATA_SOURCE element as the subreport's DataSource expression, 'cause I've of course understood that the first record might be consumed (which is perfectly logic, BTW, well done !). But the cursor of the DataSource may indeed not be pointing to the first record... I've seen a JRBeanCollectionDataSource element dispose of a function called moveFirst(), which would be interesting to try. But can I make a call to this function in the JRXML file (from iReport) ? I've build a small "architecture" of my subreports, which I join to the jrxmls, so you can better understand how my subreports work... Thank you VERY MUCH again, you're really nice having answered !
  12. If you want some extra information, after several tests, I've seen that in every case, my DataSource is not null (I write something like ((JRBeanCollectionDataSource)($P{REPORT_DATA_SOURCE})).getData().toArray()[0], and I have the values contained in my datasource. It's just the field mapping that doesn't work, and I really don't understand why... Could it be linked to the location of the frame (the "header" of the second page) ? Thank you...
  13. Hello ! Nobody tried to answer this post ? :( Does someone already have faced this problem ? Thank you... Morgan
  14. Hello ! I have a big problem for around a week, and I really don't understand how to solve this ! I have a subreport in my main report, and in this subreport, there is several levels of subreports. I have indeed several frames one below the others (there's a loop on the datasource). In the example I'm working on, I have 3 frames. In the main report, the band containing the subreport element is set to "splitAllowed", 'cause I'd like my frames to be printed on several pages. In my example, all my frames and their content (including the fields from the datasources) displays very well. BUT, if I add some text in the above bands, everything starts to be confusing. My third frame goes to the next page, as wanted (that is correct), but the data it should be containing doesn't appear anymore... If I add some text above, the second frame goes to the next page with the third, and both are displayed very well.. I really do not understand where it comes from, and what I should do... I join three screenshots, so you can understand a little better. The result is really unpredictable... Please, help meeee :'( :P Thank you very much for your help ! Best regards, Morgan Post Edited by blaguman at 05/19/2009 08:32
  15. OK, I found the solution ! I just had to put the same font in fontName and pdfFontName. Thank you anyway
  16. Hello ! I'm facing a strange problem for several days... I have some text fields with the flag "stretch with overflow", and this feature works very good, my fields expand when the text has to be printed on more than one line. However, the problem is that I sometime have a blank line under some of these text fields. In fact, I have kind of a list of text fields ones under each others, and with a single lineSpacing between them. But for some fields in which the text is large, it seems that Jasper "reserve" a new line to write into, but when it's not necessary. So i'm wondering if it's because I use a styled texte, and so the original size of the string is larger than the actual one, ('cause of the <style ...="".....> tags etc..), what could disturb Jasper. Does someone have any idea of what I could do to prevent this line to be jumped for nothing ? Thank you very much :)
  17. Thank you for your answer. I think I'll be constrained to write a utility method... :) Post Edited by Morgan Belkadi at 04/07/09 08:51
  18. Hi ! No, I just want my european characters (like 'a', 'b', 'c' or 'd') to be printed in "Arial" instead of the font included in the chinese font... Thank you for your answer :)
  19. Hello, my question is simple. I have some text fields printed in a pdf in an asian language (Traditionnal Chinese for example), and I would like the Latin characters to be printed in "Arial" for instance. Is it possible to make a mix between two fonts and let Jasper know when to print which one ? Is my question clear ? I'm french so my english may not be perfect... :) Thank you very much for your response.
  20. Thank you very much, I'm going to test that now ! :) Post Edited by Morgan Belkadi at 03/24/09 08:48
  21. Hello everyone ! First, I'm sorry for my english, and I'd like you to pardon me if it's not always clear.. :) So, I'm working with Jasper Reports and I'm stucked with problem I can't solve... (I have to say that I'm a newbie on the Jasper solutions) Here's my problem : - I currently have a frame in which are included some different-sized text fields. Some parts of these fields are filled with parameters I'm passing through the filling step, and the frame extends its height according to the elements it contains. But when the height remaining on the bottom of the page isn't sufficient to contain my frame, it splits and is drawn in two parts. Is it possible to tell the frame to be printed only when there is enough space (or insert a page break), so it's always drawn in one part ? Or is it possible to know the future height the frame is going to have ? That doesn't sound realistic, given that the size is certainly known after the filling part... Otherwise, I noticed the presence of the TextMeasurer class. Would it be useful for what I'm trying to do ? Would it help me know the size some text is going to have ? Thank you very much for your response, I'm starting to need it.. :) Bye bye EDIT : Oups, sorry, that appeared twice :O Post Edited by Morgan Belkadi at 03/23/09 14:26 Post Edited by Morgan Belkadi at 03/23/09 14:27
  22. Hello everyone ! First, I'm sorry for my english, and I'd like you to pardon me if it's not always clear.. :) So, I'm working with Jasper Reports and I'm stucked with problem I can't solve... (I have to say that I'm a newbie on the Jasper solutions) Here's my problem : - I currently have a frame in which are included some different-sized text fields. Some parts of these fields are filled with parameters I'm passing through the filling step, and the frame extends its height according to the elements it contains. But when the height remaining on the bottom of the page isn't sufficient to contain my frame, it splits and is drawn in two parts. Is it possible to tell the frame to be printed only when there is enough space (or insert a page break), so it's always drawn in one part ? Or is it possible to know the future height the frame is going to have ? That doesn't sound realistic, given that the size is certainly known after the filling part... Otherwise, I noticed the presence of the TextMeasurer class. Would it be useful for what I'm trying to do ? Would it help me know the size some text is going to have ? Thank you very much for your response, I'm starting to need it.. :) Bye bye EDIT : Oups, sorry, that appeared twice :O Post Edited by Morgan Belkadi at 03/23/09 14:26 Post Edited by Morgan Belkadi at 03/23/09 14:27
×
×
  • Create New...