2006 IR Open Discussion Posted August 18, 2006 Share Posted August 18, 2006 By: Minimini - minimini TTF and isStretchWithOverflow 2003-03-31 23:08 Hello Teodord, I use a chinese ttf font called ming_uni.ttf for dsiplay content in textfield: <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true" evaluationTime="Now" hyperlinkType="None" > <reportElement mode="Transparent" x="116" y="0" width="140" height="14" forecolor="#000000" backcolor="#FFFFFF" positionType="Float" isPrintRepeatedValues="true" isRemoveLineWhenBlank="false" isPrintInFirstWholeBand="false" isPrintWhenDetailOverflows="false"/> <textElement textAlignment="Left" verticalAlignment="Top" lineSpacing="Single"> <font fontName="/usr/local/fonts/ming_uni.ttf" pdfFontName="/usr/local/fonts/ming_uni.ttf" size="12" isBold="false" isItalic="false" isUnderline="false" isPdfEmbedded ="false" pdfEncoding ="Identity-H" isStrikeThrough="false" /> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{vr_skill}]]></textFieldExpression> </textField> The problem is the textfield will not strength when the text is not long enough, but the isStretchWithOverflow attribute is set to true. I have to increase the textfield's width to show the last few characters. It seems that jasperreports doesn't know the real text length. 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