[阅读: 1854] 2008-04-10 08:05:11
我的代码如下:
98 NSString* sCands = [NSString stringWithString:@"Abcd 123"];
99 //struct __GSFont * font=[NSClassFromString(@"WebFontCache") createFontWithFamily:@"Helvetica" traits:2 size:18.];
100 struct __GSFont * font=GSFontCreateWithName("Helvetica", kGSFontTraitBold,18);
101 [sCands drawInRect:_rectCand withFont:font];
编译时会提示警告信息如下:
Area.m:100: warning: passing argument 1 of 'GSFo
ntCreateWithName' from incompatible pointer type
Area.m:101: warning: 'NSString' may not respond
to '-drawInRect:withFont:'
Area.m:101: warning: (Messages without a matchin
g method signature
Area.m:101: warning: will be assumed to return '
id' and accept
Area.m:101: warning: '...' as arguments.)
运行时,代码跑到这里就会over。我的firmware是1.1.4的。
百思不得其解啊。
顺便说一句:我是做中文手写输入法的,在iPhone上已经能用了。
请版主帮帮忙吧!
我的email:nxy@hanwang.com.cn