How are sub- and super-scripts handled by TextMeasurer and TextLayout? My requirement is to use Java2D to perform layout, then to render in, for example, PDF.
The first question would be: is sub/super handling performed. Does Java2D rely on the font to handle sub and super? The API docs (1.5) for TextLayout.getAscent() mention "The ascent is the distance from the top (right) of the TextLayout to the baseline. It is always either positive or zero. The ascent is sufficient to accommodate super-scripted text and is the maximum of the sum of the ascent, offset, and baseline of each glyph." Note that ascent includes "offset", which is presumably non-zero for a super-scripted character. However, there seems to be no way to access this information. If I am not to render using Java2, I need to be able to extract such information in order to correctly place a superscript, given the reported ascent of the TextLayout. Any ideas? Peter =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff JAVA2D-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
