Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Searching the Mac OSX system dictionaries?

I'd like to search for words in the OS X system dictionary (or dictionaries) using a simple glob or regex rather than a known text. (Currently I'm using /usr/share/dict/words instead, but the OSX dict would be a lot nicer.)

The Dictionary Services interface is quite limited and doesn't allow this, but it seems like DSGetTermRangeInString might be doing something similar under the hood. Does anyone know of a way to access such functionality?

Alternatively, is there a way to extract a word list from the dictionary? I could then grep that. Some dictionaries seem to include the source XML in the bundle, which should be easy enough to parse, but (not surprisingly, I guess) the big language dictionaries only have the data in some binary format. Any clues as to what that might be?

like image 618
walkytalky Avatar asked Nov 08 '09 13:11

walkytalky


People also ask

Where are dictionaries stored Mac?

~/Library/Group Containers/UBF8T346G9.Office As noted above a Custom Dictionary file can be stored in a different location if you wish. If you do so you'll need to go to Word> Preferences> Spelling & Grammar - Dictionaries - Add to point to the file you want it to use.

Why does Dictionary keep popping up on my Mac?

System Preferences > Trackpad > Point & Click > Uncheck "Look Up" > Voila.

How do you clear the Dictionary on a Mac?

To remove words in your macOS dictionary, follow these steps: Open another TextEdit document (see instructions above). Type the word you wish to remove from the dictionary (again, don't press the spacebar). Press and hold the Control key on your keyboard, click the word and select the option 'Unlearn Spelling'.


1 Answers

The dictionary Apple provides in OS X is licensed from one of the major publishers. Legally, they can't let you dump the whole word list.

like image 108
NSResponder Avatar answered Oct 03 '22 07:10

NSResponder