2005 IR Help Posted August 27, 2006 Share Posted August 27, 2006 By: Phil - timelord2004 Best way to print characters sideways? 2004-10-10 14:41 Hi, I need to print characters sideways. I tested this by creating a vertical column of text, 1 char per line and then specifying that the text is rotated to the left. It works ok, but is there a way to set up a field so that it automatically is only 1 char wide (and then rotated left)? Otherwise I guess I'll have to take the field text, pass it to a java function which inserts a newline after every character and then returns it to the report? (I'm quite new to J.R so I haven't tried this yet and thought I'd ask first :) .) Thanks, Phil By: Teodor Danciu - teodord RE: Best way to print characters sideways? 2004-10-10 23:48 Hi, Have you tried the "rotation" attribute? There is a sample provided. I hope this helps. Teodor By: Phil - timelord2004 RE: Best way to print characters sideways? 2004-10-11 14:34 Like I said in my first post, I rotated the text to the left. What I'm most interested in is whether there's a better way to do this, and if not, find the best way to enforce a 1-char wide column of characters (before rotation). By: rpgmr - rpgmr RE: Best way to print characters sideways? 2004-10-11 23:36 I think there's a way to set the width to 1-char wide - you need to calculate it, thus you need to know the font that you're using. Which means you also need to use the JasperReports API, when using the API the power of Java is at your side :) But be careful, perhaps not all fonts are rectangular bitmap, if you calculate the width before you rotate, the width may not be sufficient or too much. Or you can create another external program to calculate and replace the value in your jrxml file, or the compiled file, not sure cuz I'm not using them. By: Phil - timelord2004 RE: Best way to print characters sideways? 2004-10-12 15:49 If I have to dive into some java code then I'll just simply enforce a 1-char wide column programmatically. Thanks Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now