accented font support in Squeak

Andreas Raab Andreas.Raab at gmx.de
Wed Oct 3 23:29:57 UTC 2001


John,

Ah! That's a bug. I've been pulling in the characters based on Squeak (which
is Mac Roman) encoding rather than Windows. If you change
HostFont>>fontName:size:emphasis: to use

	(Character value: i) squeakToIso asInteger

in the primitive calls (#primitiveFont:fullWithOfChar: and
#primitiveFont:glyphOfChar:into:) they come out rather nicely. Thanks for
finding this (and damn my american keyboard - would've found that one the
first time around on a german one ;-)

Cheers,
  - Andreas

> -----Original Message-----
> From: squeak-dev-admin at lists.squeakfoundation.org
> [mailto:squeak-dev-admin at lists.squeakfoundation.org]On Behalf Of John
> Hinsley
> Sent: Wednesday, October 03, 2001 7:00 AM
> To: squeak-dev at lists.squeakfoundation.org
> Subject: Re: accented font support in Squeak
>
>
> Andreas Raab wrote:
> >
> > John,
> >
> > Just as a side note:
> > > The nifty Win32 ttf support requires a Windows api.
> >
> > Only for getting the fonts into Squeak - when they're in,
> they're in and
> > just plain StrikeFonts.
> >
>
> Yes, it's a neat plug in. I've just tried it. But, although the plain
> fonts come out better than with the other true type to system font
> method -- that's to say, smaller sizes are useable, the
> accents are not
> handled correctly: compare (copy and paste this if you don't have
> accents) ÈèÉé¿¡çÇàìòíáùóñõüÜ with a ttf from your plug in and with
>
> font _ (TTFontReader parseFileNamed:
> '/your/fonts/directory/some.ttf').
> sm _ TTSampleStringMorph new font: font; string:
> 'ÈèÉé¿¡çÇàìòíáùóñõüÜ'.
> sm openInWorld
>
> //Ned's snippet, put to my evil purpose!//
>
> Of course, you have to pick a ttf with accents -- most of the standard
> ones included with M$ have them.
>
> The italics don't seem to work properly either, but I've an
> idea of just
> how difficult this is, and it is early days yet. It's already a very
> clever peice of work.
>
> I guess I'm something of a zealot on the system independence stuff:
> everyone I know runs pirated Windows, and I was one of those who
> maintained that capitalism wouldn't be brought to its knees by
> shoplifting in the 60s!
>
> Cheers
>
> John
>
>
> --
> Can't cope anymore? Desperate for help?
> Join the 12 step program for those who yearn to give up Microsoft:
> http://home.earthlink.net/~penguinrox/index.html
>
>





More information about the Squeak-dev mailing list