15 August 2010

Apple's Dictionary/Wikipedia Bug!

Update: Apple fixes Dictionary in 10.6.5, released today(10 Nov. 2010)!
Here is the File they changed:
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/DictionaryServices.framework/Versions/A/Resources/Wikipedia.wikipediadictionary/Contents/Info.plist

And What they changed in the Info.plist file:
<key>WikipediaDataURL</key>
<string>http://%@.wikipedia.org/w/index.php?title=%@&amp;useskin=monobook</string>
<key>WikipediaDataVariantURL</key>
<string>http://%@.wikipedia.org/w/index.php?title=%@&amp;variant=%@&amp;useskin=monobook</string>

I guess they liked my fix so much they decided to use it! And why couldn't they update this earlier?
====== End Update ======

Okay, I was about to post something completely different, but as I went to look up some information in Wikipedia (via Apple's Dictionary app) I ran into a snag. I could no longer scroll beyond the bottom of the window. (Ok you Mac users give it a try.)  I use Spotlight (command-space) then type in a word like "tree," select Definition and it brings up the Dictionary app. Now click on Wikipedia and you have some good info on trees except like I said you can't scroll any further down.

So, Why did this happen? Well, it's rather simple Wikipedia wanted to enhance/update their user interface. You can read about the changes here. No fault there, they have every right to innovate and improve. So now it's up to Apple to fix. "Well, what are they waiting for," you ask? That's a good question considering Wikipedia has been testing these changes since November 2009 and I'm sure Apple has known about it.

Alas, I guess it's up to the hackers and tech geeks to fix until the big companies decide it's important enough for them to do.

Here's the info and education on the fix:

Wikipedia default skin(look) was Monobook, their new one is Vector. If we modify the Dictionary's Wikipedia search string we can force it to use the old skin by adding useskin=monobook. (You can read more fun stuff to do with the search string @ MediaWiki.)

The file to change is deep in the system frameworks so be careful not to edit anything else or it could break something.

Warning: Edit the file at your own risk, I am not responsible if you break something!

The file: (starting from the root directory)
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/DictionaryServices.framework/Versions/A/Resources/Wikipedia.wikipediadictionary/Contents/Info.plist

What to change:
<key>WikipediaDataURL</key>
<string>http://%@.wikipedia.org/wiki/%@</string>

To:
<key>WikipediaDataURL</key>
<string>http://%@.wikipedia.org/w/index.php?title=%@&amp;useskin=monobook</string>

The file (Info.plist) and the folder it's in (Contents) have read only privilege's, so if you really want to make the change and you don't know how you will have to look up file/folder permissions and how to change them on a mac. Good Luck!

Note (16 Oct. 2010):  I mentioned this in a comment below. If you decided to test out the URL in your browser you will get an error when using &amp; However Dictionary.app WILL crash if you only use &!