Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Finish Status Monitor #2

Open
Marcus-P-114514 opened this issue Apr 9, 2023 · 1 comment
Open

Finish Status Monitor #2

Marcus-P-114514 opened this issue Apr 9, 2023 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@Marcus-P-114514
Copy link
Owner

Marcus-P-114514 commented Apr 9, 2023

简介:Status Monitor是一个窗口,用于打印一些我想要的日志信息。
备注:无

Description: Status Monitor is a window (QWidget) that prints some log info.
Addition notes: None

@Marcus-P-114514 Marcus-P-114514 self-assigned this Apr 9, 2023
@Marcus-P-114514 Marcus-P-114514 added this to the Status Monitor milestone Apr 9, 2023
@Marcus-P-114514 Marcus-P-114514 added the enhancement New feature or request label Apr 9, 2023
@Marcus-P-114514
Copy link
Owner Author

Marcus-P-114514 commented Apr 9, 2023

可用的新函数void StatusMonitor::InsertLog(QString LogType, QString LogContent)

函数参数:两个QString,第一个为日志类型(可选INFOWARNERROROK,输入其他会被识别成OTHER),第二个为日志内容。

函数作用:在日志窗口与调试窗口输出日志。

调用方法

在header中调用StatusMonitor:

#include "<Path>/StatusMonitor.h"

.cpp中实例化StatusMonitor并调用函数:

StatusMonitor* status_monitor = new StatusMonitor;
status_monitor->InsertLog("INFO", "函数输出测试");

New Function: void StatusMonitor::InsertLog(QString LogType, QString LogContent).

Parameters: QString LogType (Here are parameters avaliable: INFOWARNERROROK and OTHER), QString LogContent (Contents of the log, in plain text).

What does the function do: The function outputs log in both separate log window and debug window

How to Use

#include "<Path>/StatusMonitor.h"
StatusMonitor* status_monitor = new StatusMonitor;
status_monitor->InsertLog("INFO", "Log output test.");

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

No branches or pull requests

1 participant