I'm interested in writing an OS X service and figured python would be the easiest way. Is it possible to write a script to get the active PDF in the foreground window of any app, and then open that file (or a copy) in a different app?
What function calls would I need to get this done? Would it be easier to do this with AppleScript?
Edit: Apparently, the application I want to send the PDF to (Papers 2) isn't AppleScriptable. Python it is, I guess.