summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXFont.c
diff options
context:
space:
mode:
authorculler <culler>2020-05-16 17:56:24 (GMT)
committerculler <culler>2020-05-16 17:56:24 (GMT)
commit5b8151f29ca6b12d3421c026eae1a994e702f7b5 (patch)
treee838e2463d61a0ae09e2bd13df04b1b54cf575e5 /macosx/tkMacOSXFont.c
parentdc8dcbced6e03edb40b76e2108e6a4ecf6ff37fd (diff)
downloadtk-5b8151f29ca6b12d3421c026eae1a994e702f7b5.zip
tk-5b8151f29ca6b12d3421c026eae1a994e702f7b5.tar.gz
tk-5b8151f29ca6b12d3421c026eae1a994e702f7b5.tar.bz2
Fix compiler errors and warnings on macOS 10.6 (Snow Leopard)
Diffstat (limited to 'macosx/tkMacOSXFont.c')
-rw-r--r--macosx/tkMacOSXFont.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/macosx/tkMacOSXFont.c b/macosx/tkMacOSXFont.c
index 89df102..4b0b7e2 100644
--- a/macosx/tkMacOSXFont.c
+++ b/macosx/tkMacOSXFont.c
@@ -111,7 +111,8 @@ static void DrawCharsInContext(Display *display, Drawable drawable,
- (instancetype)initWithTclUtfBytes:(const void *)bytes
length:(NSUInteger)len
{
- if (self = [self init]) {
+ self = [self init];
+ if (self) {
Tcl_DStringInit(&_ds);
Tcl_UtfToUniCharDString(bytes, len, &_ds);
_string = [[NSString alloc]
@@ -139,7 +140,9 @@ static void DrawCharsInContext(Display *display, Drawable drawable,
{
return [_string characterAtIndex:index];
}
-
+#ifndef __clang__
+@synthesize UTF8String = _UTF8String;
+#endif
@end
/*