Posts

Showing posts from August, 2018

An overview of how UI logging works in LibreOffice

Logging in LibreOffice is mainly handled by a class called UITestLogger, defined here . The logger class logs the user actions only if the member flag mbValid is set to true. The flag can be turned on by setting the environment variable LO_COLLECT_UIINFO to a file name where the logs should be collected (see the constructor of UITestLogger, defined here ). We maintain a pointer to an instance of UITestLogger class here . To use the logger object, the static function getInstance can be used to get access to the pointer. The function logAction, defined in the same class, is used to log events from the classes which extend the class vcl::Control. The log statements corresponding to a particular class can be found in the function get_action of the UI wrapper classes. Most of the wrapper classes can be found with this OpenGrok search. The log statements get generated when VCL events get broadcasted. A list of the VCL events can be found in the enum class VclEventId here . For

GSoC final report - UI logger

Overview The idea of this GSoC project was to implement a feature which logs the interaction of users with the UI elements in an interpretable Domain Specific Language (DSL), and an interpreter which converts the log into a file into something which will help in replaying the user actions. The project involved working with the UI elements and the UI testing framework of LibreOffice. Achievements The logger - The logging for the following is currently supported - The UI elements of Visual Component Library like Buttons, Checkboxes, Radio-buttons, Listboxes, Comboboxes, Spinbuttons, etc. Keys pressed in different UI elements UNO commands sent with parameters Selection of Objects Opening of Sidebar/Deck Some application-specific events can also be logged - Writer - Goto Page, Set Zoom, Text Selection Calc - Autofilter Launch, Selection of cells/range of cells, Switching of Sheet Math - Selection of elements from the element selector panel Impress - Set Zoom Addition