Peter, >From what I remember (and the last time I touched this code was in 2002), It could handle mixed font styles. Now that I'm re-reading the javadoc, I'm not at all sure about what attributes can be set. I had initially provided regular font attributes when constructing the AttributedString. In my case, I never got to using mixed font styles in one string, though I was planning ahead so I'd be able to do that easily later. Maybe someone from the 2D team can chime in here about the types of attributes that can be set on the AttributedString. It seems to me that it would be imporant that the attributes are actually used by the code using the iterator. (like the LBM). David Thus Spoke Peter B. West: =========================================================================== 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".On Thu, 2006-06-15 at 11:38 -0400, David Kavanagh wrote:Peter, I've used AttributedString to represent a sequence of text with various attributes at different segments. Then, you can use the LineBreakMeasurer(and passing the AttributedCharacterIterator, and FontRenderContext). I found that the LBM didn't work well for blank lines (and paragraph breaks), so I ended up handling those cases specially. Once I had the lines broken up, I could iterate through and render them, creating a glyph vector for each as I go.DavidDavid, To be a bit more specific regarding your solution, how did it work with font changes (e.g. bold) within words? I don't yet know how the multiple GlyphVectors will behave in such circumstances. Peter |
- [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors David Kavanagh
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors Phil Race
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors David Kavanagh
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors Chris Nokleberg
- Re: [JAVA2D] Using GlyphVectors douglas felt
- Re: [JAVA2D] Using GlyphVectors Doug Felt @ Sun
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors douglas felt
- Re: [JAVA2D] Using GlyphVectors Chris Nokleberg
- Re: [JAVA2D] Using GlyphVectors Peter B. West
- Re: [JAVA2D] Using GlyphVectors Doug Felt @ Sun