Skip to content

Instantly share code, notes, and snippets.

@bdotdub
Created January 7, 2011 05:49
Show Gist options
  • Save bdotdub/769161 to your computer and use it in GitHub Desktop.
Save bdotdub/769161 to your computer and use it in GitHub Desktop.
#import <Foundation/Foundation.h>
#import <CoreServices/CoreServices.h>
// adjective
// 1 imaginative or fanciful; remote from reality
// 2 extraordinarily good or attractive
// DERIVATIVES
// fantastical adjective (in sense 1) .
// fantasticality noun (in sense 1) .
// fantastically adverb
@interface DictionaryEntry : NSObject {
}
@end
@implementation DictionaryEntry
@end
int main() {
NSString *word = @"fantastic";
CFRange range = DCSGetTermRangeInString(NULL, (CFStringRef)word, 0);
NSString *definition = (NSString*)DCSCopyTextDefinition(NULL, (CFStringRef)word, range);
NSLog(@"Testing : %@", definition);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment