#NEWLINE# def get_active_window_id( self ) : #NEWLINE# #INDENT# out = getoutput ( 'xprop -root _NET_ACTIVE_WINDOW' ) #NEWLINE# try : #NEWLINE# #INDENT# win_id = out . split ( '#' ) [ ( - 1 ) ] . split ( ',' ) [ 0 ] . strip ( ) #NEWLINE# #UNINDENT# except ValueError : #NEWLINE# #INDENT# return None #NEWLINE# #UNINDENT# return win_id