Around 16 o'clock on Nov 17, Tomohiro KUBOTA wrote:
> I am planning to use XftTextExtent() to check the width of "W",
> instead of using max_advance_width. Though there may be many
> "singlewidth" glyphs which are wider than "W", I think this is a
> not so bad way to determine the width of singlewidth glyphs. Anyway,
> Using proportional fonts for fixed-width purpose is a makeshift and
> the best way would be preparing fixed-width fonts.
If the "singlewidth" glyphs are actually proportional, then this will not
generate pleasing output -- "W" is usually *much* wider than most
characters. I think it would look better to use a truly monospaced font
for the latin glyphs.
> BTW, I am testing the software using "Kochi Gothic" and "Kochi Mincho"
> Unicode truetype Japanese fonts. I found that XftDrawString*() cannot
> display characters if these fonts are used in XFT_PIXEL_SIZEs of
> 10, 11, 12, 13, 14, 15, 16, 17, 20, and 21. Curiously enough, the
> Kochi fonts include built-in bitmap fonts for these sizes. I imagine
> either of FreeType, Xft, or Kochi fonts is responsible for this
> problem. Since I don't know at all about TrueType font format,
> I cannot check it.
Sorry, it's an easy bug to fix (once I had a font with bitmaps to try it
out). It doesn't make Xft use the embedded bitmaps, but at least it
displays the glyphs now. I've already committed this fix to CVS so it
will be in XFree86 4.2. I'll make the new Xft library use embedded
bitmaps when not rendering with anti-aliasing.
Index: xftglyphs.c
===================================================================
RCS file: /home/x-cvs/xc/lib/Xft/xftglyphs.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- xftglyphs.c 2001/05/16 10:32:54 1.13
+++ xftglyphs.c 2001/11/17 08:22:45 1.14
@@ -124,7 +124,7 @@
}
else
glyphindex = (FT_UInt) charcode;
- error = FT_Load_Glyph (font->face, glyphindex, 0/*|FT_LOAD_NO_HINTING */);
+ error = FT_Load_Glyph (font->face, glyphindex, FT_LOAD_NO_BITMAP);
if (error)
continue;
[EMAIL PROTECTED] XFree86 Core Team SuSE, Inc.
_______________________________________________
I18n mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/i18n