[futurebasic] Re: [FB] HITheme_Demos

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : March 2010 : Group Archive : Group : All Groups

From: Robert Purves <listrp@...>
Date: Sat, 6 Mar 2010 08:15:41 +1300
Peter wrote:

> I'm trying to run  the demo of HITheme in the example folder of 5.4.4 and I'm running 10.4.11. Do I need 10.5 to run this demo? I'm getting CGFloat as unknown, along with other variables.

CGFloat was not defined until 10.5. You can fix that by putting this at the top of HITheme_demos:

BeginCDeclaration
#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_4
typedef float CGFloat;
#endif
EndC

But it will still fail on 10.4.11 because two functions in the demo use 10.5 CoreText features of HITheme.

...HITheme_demos.c: In function 'drawHIThemeDrawTextBox':
...HITheme_demos.c:26: error: 'HIThemeTextInfo' has no member named 'font'

...HITheme_demos.c: In function 'drawHIThemeGetTextDimensions':
...HITheme_demos.c:26: error: implicit declaration of function 'CTFontCreateWithName'

Robert P.