title: Get content from open window in Linux
body: <p>I want to collect data and parse it eventually from an open window in linux.</p>
  
  <p>An example- Suppose a terminal window is open. I need to retrieve all the data that appears on that window. After retrieval, I would parse it to get specific commands entered.</p>
  
  <p>So is it possible to do that? If so, how? I would prefer to use python to code this entire thing.</p>
  
  <p>I am making a guess that first I would have to get some sort of ID for the open window and then use some kind of library to get the content from the window whose ID I have got. </p>
  
  <p>Please help. I am quite a newbie.</p>