Skip to content

Implement a mechanism to display log messages in a separate window in the GUI

Ammar Nejati requested to merge loggerWindow into develop

Messages for the GUI user can be displayed in a separate window (LogWindow) via View->Open log window menu item. The messages have the same levels as defined in the Logger module and are displayed with different colours according to their level. The displayd messages can be saved as plain text to a file. The log window can also be cleared.

nsx::nsxmsg is a helper method which can be used to send such messages to the GUI and all other receivers (currently, only GUI); for instance,

nsx::nsxmsg(nsx::Level::Info, "This is an info message.");

As the infra-structure, a Messenger class is implemented to allow a simple message-passing mechanism to send messages to the registered receivers (eg., GUI modules), without a strong coupling of the core to the receivers (esp. the GUI). The messages are immutable structures of type LogMessage.

Resolves #161 (closed)

Edited by Ammar Nejati

Merge request reports