In a fully updated 3.1 image, I ´try to install a Truetype font via ...
"TTFontReader installTTF: 'c:\winnt\fonts\arial.ttf' asTextStyle: #Arial sizes: #(24 60)"
So far, so good. However, as soon as I try to actually put the font to use (by clicking to the "System Fonts" menu entry), I get a "Bad BitBlt arg (Fraction?)" error as soon as the font selection menu is about to be displayed. If I proceed, nothing happens.
Can anyone explain why this happens and what can be done about it?
BTW, is there any other way to get Truetype fonts into Squeak? All the methods I've tried (as described on this ML and the Swiki) either give errors or a obsolete. Andreas Raabs TTF-to-file-in converter produces Smalltalk code for old Squeaks (utilizes methods which don't exist in current images), Ned Konz' fix posted to the ML doesn't help either (guess it has found its way into the update stream a long time ago anyway) ...
Best regards, -- Chris
On Friday 28 September 2001 06:42 pm, Christian Langreiter wrote:
In a fully updated 3.1 image, I ´try to install a Truetype font via ...
"TTFontReader installTTF: 'c:\winnt\fonts\arial.ttf' asTextStyle: #Arial sizes: #(24 60)"
So far, so good. However, as soon as I try to actually put the font to use (by clicking to the "System Fonts" menu entry), I get a "Bad BitBlt arg (Fraction?)" error as soon as the font selection menu is about to be displayed. If I proceed, nothing happens.
Can anyone explain why this happens and what can be done about it?
I dunno. Works for me, but doesn't look too nice (though I'm not necessarily using the Windows Arial.ttf) At least it doesn't blow up.
BTW, is there any other way to get Truetype fonts into Squeak? All the methods I've tried (as described on this ML and the Swiki) either give errors or a obsolete. Andreas Raabs TTF-to-file-in converter produces Smalltalk code for old Squeaks (utilizes methods which don't exist in current images), Ned Konz' fix posted to the ML doesn't help either (guess it has found its way into the update stream a long time ago anyway) ...
Well, what do you want to do? Because of the lack of hinting, you don't want to use TTF fonts in small sizes. In bigger sizes, there is the TTSampleStringMorph:
font _ (TTFontReader parseFileNamed: '/usr/share/fonts/truetype/arial.ttf'). sm _ TTSampleStringMorph new font: font; string: 'This is a test string'. sm openInWorld
If you're just looking for replacements for the system fonts, use bitmap fonts, not scalable fonts.
If you're just looking for replacements for the system fonts, use bitmap fonts, not scalable fonts.
AFAIK all the MS default-supplied TTFs include manually tuned bitmap fonts to be used at low resolutions. I guess there isn't a way to directly retrieve those from Squeak ...I'll try my luck with one of those TTF2BDF tools (if there are any functioning left ;-).
BTW, I've updated the VM to the latest one in the testPilot dircetory, and now the BitBlt error is gone (the fonts, however, look, uhm, funky - too funky to be of any use, actually).
Thank you very much, anyway!
-- Chris
squeak-dev@lists.squeakfoundation.org