I have found that monospace support in the current 2.1.9x fontconfig is disabled with a note stating that it doesn''t work so it was disabled. As far as I was able to tell it always seemed to work correctly for me. Now however kde can no longer see fixed width fonts from fontconfig. What fonts were having the problem which caused you to disable the support? Thanks, Chris Cheney Debian KDE Maintainer
Around 20 o''clock on Mar 28, Chris Cheney wrote:> Thanks Keith! I''ll try this out and then let Colin (Debian Fontconfig > Maintainer) know that the bug I reported to him is fixed in cvs. 8)Yeah, make sure it works first :-) -keith
Thanks Keith! I''ll try this out and then let Colin (Debian Fontconfig Maintainer) know that the bug I reported to him is fixed in cvs. 8) Chris
Around 8 o''clock on Mar 28, Keith Packard wrote:> One easy possibility is to compute the spacing attribute directly from the > font; scan all of the glyphs and mark fonts as monospaced when they are in > fact monospaced. I think that would be easy enough to try, and may fix > this particular problem well enough.I''ve gone ahead and done this; it seems to work quite well. It''s essentially free as the library had to scan every glyph in the font to detect glyphs which were encoded but had no outlines (many TTF files "remove" some glyphs by leaving the encoding entries but stripping out the glyphs). -keith
Around 9 o''clock on Mar 29, Owen Taylor wrote:> Not sure if you are doing it or not, but CJK dual-width fonts need > to be treated as monospace, just not metric forced to the maximum > width. (If you want to metric force based on wcwidth() data, that > would be OK, though a little tricky, but I''m not sure there is a > point.)I''m not doing that right now because Xft uses the ''spacing'' value to force expansion to maxwidth. I think we need to figure out both the right solution and a plan for migrating to that from where we are right now. We need several things: 1) Identify monospace fonts 2) Identify dual-spaced fonts 3) Force fonts to be monospaced 4) Force fonts to be dual-spaced It seems clear the mechanism in 3) and 4) should be separate from 1) and 2), while right now they are tied together -- 1) and 3) both use ''spacing''. I suggest we add a new value that identifies mono/dual/other spacing in fonts; that will (at least) give us the ability to find fonts without affecting their layout. -keith
Around 1 o''clock on Mar 28, Chris Cheney wrote:> What fonts were having the problem which caused you to disable the support?The problems worked in both directions -- there were many fonts which are useful in terminal emulators (like some versions of andale mono) which weren''t marked as monospaced, making those not visible in KDE, and (worse, it turns out), there were many Japanese fonts which were marked as monospaced but which were not. This latter issue caused significant problems as Xft forced any font with the monospace attribute to be spaced according to the maximum width of all glyphs in the font. One easy possibility is to compute the spacing attribute directly from the font; scan all of the glyphs and mark fonts as monospaced when they are in fact monospaced. I think that would be easy enough to try, and may fix this particular problem well enough. -keith
On Fri, 2003-03-28 at 11:24, Keith Packard wrote:> Around 1 o''clock on Mar 28, Chris Cheney wrote: > > > What fonts were having the problem which caused you to disable the support? > > The problems worked in both directions -- there were many fonts which are > useful in terminal emulators (like some versions of andale mono) which > weren''t marked as monospaced, making those not visible in KDE, and (worse, > it turns out), there were many Japanese fonts which were marked as > monospaced but which were not. This latter issue caused significant > problems as Xft forced any font with the monospace attribute to be spaced > according to the maximum width of all glyphs in the font. > > One easy possibility is to compute the spacing attribute directly from the > font; scan all of the glyphs and mark fonts as monospaced when they are in > fact monospaced. I think that would be easy enough to try, and may fix > this particular problem well enough. >Not sure if you are doing it or not, but CJK dual-width fonts need to be treated as monospace, just not metric forced to the maximum width. (If you want to metric force based on wcwidth() data, that would be OK, though a little tricky, but I''m not sure there is a point.) The reason for this is that these fonts are used in the contexts where monospace fonts are used - terminals and text editors. Most terminal emulators and software that formats text for fixed width display properly understand double-char-cell characters these days. Regards, Owen