On 5 Mar 2002, Jean-Marc Lasgouttes wrote:

> >>>>> "Allan" == Allan Rae <[EMAIL PROTECTED]> writes:
[...]
> Allan> FWIW, wouldn't it make sense for FontLoader to use a pattern
> Allan> that includes the screen DPI setting?
>
> I do not like this one, especially if DPI is not 75 or 100.
>
> Allan> Or at least FontInfo::query() when searching for a suitable
> Allan> scalable font?
>
> What do you mean?

Well, I was thinking about the possibility of selecting scalable fonts
based on the DPI setting.  In particular for cases where DPI is not 75
or 100 we are almost guaranteed to only get scalable fonts listed.  So
if someone sets their roman font to say, "-monotype-times new roman"
and we do a XListFonts() call with the Preferences->Screen Fonts->DPI
setting we will get an "exact" match.  For cases where no scalable
font exists we get no matches (provided DPI != 75 or 100) and know we
can only use bitmapped fonts.

What this would effectively do is make it so any given FontInfo would
attempt to use a scalable font at the DPI specified.  If no scalable
font matches we call XListFonts() again with a * for the DPI settings
and attempt to match fonts again (probably only bitmapped fonts
available in this case).

So we'd end up prefering scalable over bitmapped fonts for DPI
settings other than 75 or 100.

> Allan> Or we should at least be trying to match a font that is as
> Allan> close as possible to the screen dpi setting within
> Allan> FontInfo::getFontName() for non-scaled fonts.
>
> Yes, although we may decide that we are not interested by dpi setting,
> but only pixel-height value. This allows to mix different dpi settings
> and have acceptable results.

Hmmm... Okay, I think that will work.  But let's call that stage 3.
Stage 2 would be giving preference to the closer DPI
bitmapped/scalable font (ie. 75 or 100).

Stage 4 if it ever occurs would take on something bigger like the
description above.

Stage 1 is finishing the "identify scalable bitmapped fonts" patch.
That is the only one I'm interested in seeing get into 1.2.0 since it
finishes partially completed work.  It's also likely that is the only
thing I'd have time for (apart from a couple of small bugs that still
have my name on in bugzilla).

Allan. (ARRae)  I have a new thesis supervisor.  One with a big whip!

Reply via email to