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

Add Qt::FontRole data #45

Merged
merged 2 commits into from
Feb 16, 2024
Merged

Add Qt::FontRole data #45

merged 2 commits into from
Feb 16, 2024

Conversation

Overflwn
Copy link
Collaborator

This is related to #35 and just adds the ability to change the Qt::FontRole for a specific logger. It works just like the background and foreground colors.

I also added a "Bold" checkbox to the toolbar which demonstrates this feature. Unit tests are also included in this PR.

Additionally, I made a small change to the style popup, it resets the QLineEdit and QCheckBox values if the std::optionals are std::nullopt.

Copy link

codecov bot commented Feb 15, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (670aea5) 97.95% compared to head (3d9e12c) 98.04%.

Files Patch % Lines
src/qspdlog_model.cpp 96.15% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #45      +/-   ##
==========================================
+ Coverage   97.95%   98.04%   +0.09%     
==========================================
  Files          10       10              
  Lines         928     1022      +94     
==========================================
+ Hits          909     1002      +93     
- Misses         19       20       +1     
Flag Coverage Δ
uitests 98.04% <99.00%> (+0.09%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@arsdever arsdever self-assigned this Feb 15, 2024
Copy link
Owner

@arsdever arsdever left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, looks great 👍🏼.

Please pass through a clang-format tool after fixing the comments. The formatting seems to be odd.

src/qspdlog_style_dialog.cpp Outdated Show resolved Hide resolved
src/qspdlog_model.cpp Outdated Show resolved Hide resolved
@arsdever
Copy link
Owner

With this PR applied, the sample dialog and the resulting log messages look like this

Screenshot 2024-02-16 122145
Screenshot 2024-02-16 122137

@Overflwn
Copy link
Collaborator Author

@arsdever I applied your suggestions and fixes

@Overflwn Overflwn merged commit 7db5341 into arsdever:main Feb 16, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants