DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39422>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39422





------- Additional Comments From [EMAIL PROTECTED]  2006-04-27 23:13 -------
Dear Vincent,

some kind of "hasGlyph" function is most certainly necessary. And maybe some 
helper functions to go 
with it, but these can be easlily implementing using the "hasGlyph"

the current font system has a "hasChar" function:
  public boolean hasChar(char c);
 
I've added a tracker item for axsl

http://sourceforge.net/tracker/index.php?func=detail&aid=1478049&group_id=123259&atid=695974

---

I've also found the source of my '#'. It is is 
o.a.f.render.pdf.PDFRenderer#escapeText:

            if (fs.hasChar(orgChar)) {
                ch = fs.mapChar(orgChar);
                int tls = (i < l - 1 ? parentArea.getTextLetterSpaceAdjust() : 
0);
                glyphAdjust -= tls;
            } else {
                if (CharUtilities.isFixedWidthSpace(orgChar)) {
                    //Fixed width space are rendered as spaces so copy/paste 
works in a reader
                    ch = fs.mapChar(CharUtilities.SPACE);
                    glyphAdjust = fs.getCharWidth(ch) - 
fs.getCharWidth(orgChar);
                } else {
                    ch = fs.mapChar(orgChar);
                }
            }

and by default fs.mapChar(orgChar) returns '#' if the char is not in that font. 

----

so my "dirty hack" solution would be:
- if glyph is not in font, go through list of all fonts until you find a font 
that has this glyph, use it 
instead.

a good solution would be:
- get a list of all fonts supporting that glyph. Find the one that is the "best 
match". use it.

Max


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

Reply via email to