Linux task manager equivalent
I'm developing an application logger software. I should make a log file that contains all the applications opened by user. Under Windows is not matter, I could solve it using the tasklist. Under Linux it's a little bit different, because I can get the whole list of running processes olny using command ps. So I need some command/tool or any way to get the list of applications physically opened by user - e.g. list of opened windows.
ps.: it should be a cross-platform logger application