Log/Journal user actions/clicks
-
Hi, Does Qt have the infrastructure to log or journal user actions? If so, how do I activate it? Other than users sending me the log/journal file for debugging purposes, can this be used to "replay" in the future and avoid clicking subsequently?
Thanks.
-
You mean something like automation?
There is the
QTest
module (https://doc.qt.io/qt-5/qtest.html) which can be used to "test" different user behavior by simulating e.g. input events, but this is more for real "testing" than using it in a "live" application.AFAIK Qt doesn't log clicks or keyputs somewhere unless you implement it yourself. There are notifications (signals,
QEvents
) when something happens, but there is no log with all actions, that happened between app start and any given time.-
Qt Event System
https://doc.qt.io/qt-5/eventsandfilters.html
You could install an event filter to watch a specific
QObject
or yourQApplication
-
-
Hi
Qt does have such a recording system out of the box, but you can roll your own with
https://doc.qt.io/qt-5/qsignalspy.html -
Hi,
QSignalSpy as well as all stuff from the QtTest module are to be used only in tests. IIRC, there's even a warning in the documentation about that.
As for the original question, you should take a look at KDE's KUserFeedback framework. It might provide what you need.
-
Thanks everyone for your replies.
@Pl45m4 @mrjj
What I have in mind is: any event (mouse, key, actions on widgets) that changes the state of the user's data should be captured. Let me give a trivial example (one or more actions implied in each step):- the user reads x-y data from a file
- the user manipulates/changes and saves the data based on some provided functionality
Out of the box, can Qt capture this sequence of actions? As I say in the OP, the intent is to use this log/journal file to debug instead of asking the user to describe the sequence of actions, and also let the user can replay without having to take the actions again.
Thanks again.