Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Apr 15, 2011, 10:58 PM   #1
Blakeasd
macrumors 6502a
 
Join Date: Dec 2009
Adding to NSMutable Dictionary

Is it possible to add all of the terms (not the definitions, just the name of the work) from the built-in OS X Dictionary into an NSMutableDictionary?
Blakeasd is online now   0 Reply With Quote
Old Apr 16, 2011, 02:36 AM   #2
gnasher729
macrumors G5
 
gnasher729's Avatar
 
Join Date: Nov 2005
Quote:
Originally Posted by Blakeasd View Post
Is it possible to add all of the terms (not the definitions, just the name of the work) from the built-in OS X Dictionary into an NSMutableDictionary?
I wish you lots of luck doing this, but there seems to be no useful documentation about it at all. If you figure it out, I would be very grateful if you posted here how to do it.
gnasher729 is offline   0 Reply With Quote
Old Apr 16, 2011, 02:46 AM   #3
robbieduncan
Moderator
 
robbieduncan's Avatar
 
Join Date: Jul 2002
Location: London
Dictionaries are in /Library/Dictionaries/

Each Dictionary is a bundle (with a .dictionary extension). Within each dictionary bundle in the resources is a (localised) xml file called <DictionaryName>.xml. You can parse the xml (the format looks quite simple) to get all the keys (and definitions if you want).
robbieduncan is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
Importing NSMutable Array into Map Annotations Futhark iPhone/iPad Programming 39 Apr 25, 2013 02:52 PM
Custom Dictionary in the native OS X Dictionary App gtx383 Mac Programming 1 Apr 10, 2013 04:42 PM
NSMutable Array Help AnonymousInUse iPhone/iPad Programming 12 Oct 11, 2012 03:46 PM
Resolved: Fetch object in NSMutableDictionary inside NSMutable lasash iPhone/iPad Programming 22 Oct 9, 2012 09:10 PM
Adding/Modifying custom words programatically to iOS dictionary from a csv file ashwinr87 iPhone/iPad Programming 1 Sep 27, 2012 11:38 AM

Forum Jump

All times are GMT -5. The time now is 09:44 PM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps