Using TT Fonts?

Nick Brown maillist at bredon-gill.demon.co.uk
Sun Aug 25 18:01:19 UTC 2002


Hi.

The changeset files in fine, and appears to install fonts fine (I
loaded Arial, and it displays fine in the Standard System Fonts menu),
but when I then tried to set Arial as the default text font I got a
DNU... TrueTypeFont does not understand #textStyle

I'm using 3.2g, latest update, with the most recent Win32 VM.

Regards,
Nick Brown


On Sun, 25 Aug 2002 19:02:50 +0200, Hans-Martin Mosner wrote:

>Incidentally, I've been working on exactly that problem and implemented a
>TrueTypeFont subclass of AbstractFont which displays antialiased TrueType
>glyphs more-or-less correctly. Since the character widths are fractional,
>there are certainly cases where old assumptions about integer character
>widths will break existing code (One such case in a central place needd to
>be fixed to use fractional widths at all). But overall, the results look
>quite ok, and editing and formatting is acceptable even on my 233 MHz
>PowerPC, so I believe it can be a viable way of getting higher quality fonts
>into standard Squeak windows.
>Change set is attached. Please report any rough edges or possible
>improvements.
>
>Cheers,
>Hans-Martin

-------------- next part --------------
MessageNotUnderstood: textStyle
25 August 2002 6:45:55 pm

VM: Win32 - Squeak3.2gamma of 12 January 2002 [latest update: #4879]
Image: Squeak3.2 [latest update: #4952]

TrueTypeFont(Object)>>doesNotUnderstand:
	Receiver: a TrueTypeFont
	Arguments and temporary variables: 
		aMessage: 	a Message with selector: #textStyle and arguments: #()
	Receiver's instance variables: 
		fontDescription: 	a TTFontDescription
		name: 	#Arial
		pointSize: 	14
		xTable: 	nil
		characterToGlyphMap: 	nil
		color: 	Color black
		emphasis: 	0

Preferences class>>setSystemFontTo:
	Receiver: Preferences
	Arguments and temporary variables: 
		aFont: 	a TrueTypeFont
		aStyle: 	nil
		newDefaultStyle: 	nil
	Receiver's instance variables: 
		superclass: 	Object
		methodDict: 	a MethodDictionary(#seeClassSide->a CompiledMethod (569) )
		format: 	2
		instanceVariables: 	nil
		organization: 	('look in class' seeClassSide)

		subclasses: 	nil
		name: 	#Preferences
		classPool: 	a Dictionary(#DesktopColor->(Color r: 0.742 g: 1.0 b: 0.839) #Dictio...etc...
		sharedPools: 	nil
		environment: 	a SystemDictionary(lots of globals)
		category: 	nil

[] in MenuItemMorph>>invokeWithEvent:
	Arguments and temporary variables: 
		evt: 	[276 at 440 mouseUp 88116467]
		selArgCount: 	1
		w: 	a PasteUpMorph(2074) [world]

BlockContext>>ensure:
	Receiver: [] in MenuItemMorph>>invokeWithEvent:
	Arguments and temporary variables: 
		aBlock: 	[] in CursorWithMask(Cursor)>>showWhile:
		returnValue: 	nil
	Receiver's instance variables: 
		sender: 	BlockContext>>ensure:
		pc: 	145
		stackp: 	0
		nargs: 	0
		startpc: 	124
		home: 	MenuItemMorph>>invokeWithEvent:

--- The rest of the stack ---
CursorWithMask(Cursor)>>showWhile:
MenuItemMorph>>invokeWithEvent:
MenuItemMorph>>mouseUp:
MenuItemMorph>>handleMouseUp:
MouseButtonEvent>>sentTo:
MenuItemMorph(Morph)>>handleEvent:
MorphicEventDispatcher>>dispatchDefault:with:
MorphicEventDispatcher>>dispatchEvent:with:
MenuItemMorph(Morph)>>processEvent:using:
MorphicEventDispatcher>>dispatchDefault:with:
MorphicEventDispatcher>>dispatchEvent:with:
MenuMorph(Morph)>>processEvent:using:
MenuMorph(Morph)>>processEvent:
MenuMorph>>handleFocusEvent:
[] in HandMorph>>sendFocusEvent:to:clear:
PasteUpMorph>>becomeActiveDuring:
HandMorph>>sendFocusEvent:to:clear:
HandMorph>>sendEvent:focus:clear:
HandMorph>>sendMouseEvent:
HandMorph>>handleEvent:
HandMorph>>processEvents
[] in WorldState>>doOneCycleNowFor:
Array(SequenceableCollection)>>do:
WorldState>>handsDo:
WorldState>>doOneCycleNowFor:
WorldState>>doOneCycleFor:
PasteUpMorph>>doOneCycle
[] in Project class>>spawnNewProcess
[] in BlockContext>>newProcess


More information about the Squeak-dev mailing list