USING PYTHON, FIND ACTIVE WINDOW NAME IN MAC OS X

Felix Pickles

Total Post:24

Points:168
Posted by  Felix Pickles
 857  View(s)
Ratings:
Rate this:

How can I find the name of the application that window I currently using with the time (MAC OS X using Python)?

  1. Tarun Kumar

    Post:214

    Points:1642
    Re: Using Python, find active window name in Mac OS X

    From AppKit import NSWorkspace

    active_app_name = NSWorkspace.sharedWorkspace().frontmostApplication().localizedName()

    print active_app_name

      Modified On Sep-30-2015 11:06:49 PM

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!