Mercurial > dwindows
comparison mac/dw.m @ 1041:6a57bf20d8f9
Return displayName property instead of fontName property in dw_window_get_font()
author | mhessling@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Thu, 26 May 2011 11:46:13 +0000 |
parents | 7ea8a428e0cc |
children | 625fa470dcf0 |
comparison
equal
deleted
inserted
replaced
1040:7ea8a428e0cc | 1041:6a57bf20d8f9 |
---|---|
4284 *bytes = stringLength; | 4284 *bytes = stringLength; |
4285 if(lines) | 4285 if(lines) |
4286 { | 4286 { |
4287 for(index=0, numberOfLines=0; index < stringLength; numberOfLines++) | 4287 for(index=0, numberOfLines=0; index < stringLength; numberOfLines++) |
4288 index = NSMaxRange([ms lineRangeForRange:NSMakeRange(index, 0)]); | 4288 index = NSMaxRange([ms lineRangeForRange:NSMakeRange(index, 0)]); |
4289 | 4289 |
4290 *lines = numberOfLines; | 4290 *lines = numberOfLines; |
4291 } | 4291 } |
4292 } | 4292 } |
4293 | 4293 |
4294 /* | 4294 /* |
7264 { | 7264 { |
7265 font = [object font]; | 7265 font = [object font]; |
7266 } | 7266 } |
7267 if(font) | 7267 if(font) |
7268 { | 7268 { |
7269 NSString *fontname = [font fontName]; | 7269 NSString *fontname = [font displayName]; |
7270 NSString *output = [NSString stringWithFormat:@"%d.%s", (int)[font pointSize], [fontname UTF8String]]; | 7270 NSString *output = [NSString stringWithFormat:@"%d.%s", (int)[font pointSize], [fontname UTF8String]]; |
7271 return strdup([output UTF8String]); | 7271 return strdup([output UTF8String]); |
7272 } | 7272 } |
7273 return NULL; | 7273 return NULL; |
7274 } | 7274 } |
7321 DW_MUTEX_UNLOCK; | 7321 DW_MUTEX_UNLOCK; |
7322 return 0; | 7322 return 0; |
7323 } | 7323 } |
7324 | 7324 |
7325 [object removeFromSuperview]; | 7325 [object removeFromSuperview]; |
7326 | 7326 |
7327 tmpitem = malloc(sizeof(Item)*(thisbox->count-1)); | 7327 tmpitem = malloc(sizeof(Item)*(thisbox->count-1)); |
7328 | 7328 |
7329 /* Copy all but the current entry to the new list */ | 7329 /* Copy all but the current entry to the new list */ |
7330 for(z=0;z<index;z++) | 7330 for(z=0;z<index;z++) |
7331 { | 7331 { |