think logo

Site Info

Categories

Archives

Meta

Geo

Museum

Recent Posts

Recent Comments

 

February 2012
S M T W T F S
« May    
 1234
567891011
12131415161718
19202122232425
26272829  

Spotlight for coders

March 1, 2011

Apologies to everyone who already knew this…

I just discovered something very cool. As an only occasional coder (Python, mostly, when I get the chance to write code), I don’t have a very good grasp of where all the header files for Mac OS X frameworks live.

Let’s say that you want to know where CGEventSourceSecondsSinceLastEventType is defined. Just hunt for it in Spotlight and it will turn up all the places it shows up in header files.

E.g.

/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs /iPhoneSimulator3.2.sdk/System/Library/Frameworks/ApplicationServices.framework /Versions/A/Frameworks/CoreGraphics.framework/Versions/A/Headers

Or

/Developer/SDKs/MacOSX10.6.sdk/System/Library/Frameworks /IOKit.framework/Versions/A/Headers/hidsystem

Clicking on the Spotlight results opens the file in Xcode.

Who knew?

1 Comment

  1. Allan says:

    Haha, I just realized that I’ve written a ton of code lately, but it’s all WordPress PHP code to build themes. For some reason that doesn’t feel like coding, I guess.

    March 3rd, 2011 at 9:08 pm

Sorry, the comment form is closed at this time.