mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-11-05 17:43:23 -08:00
[Fonts] Keep ChatView on the app font and share the report log font
- ChatLog's unset fallback is qApp->font() again: ChatView never set a font before the role existed, so an unset role must not switch chat and the game log to monospace at the system GeneralFont size. - Move the monospace fallback the report dialogs used before into report_utils::reportLogFont(), which returns the theme's ChatLog role when it is set and the old monospace otherwise. tab_report, dlg_my_reports and dlg_report_user now share it, so they cannot drift and they honour a themed size instead of overriding it.
This commit is contained in:
parent
2a3a31c24c
commit
145f7adf73
7 changed files with 39 additions and 34 deletions
|
|
@ -154,6 +154,8 @@ public:
|
|||
* ChatLog, serif basis for CardText, the application font for the
|
||||
* remaining roles). */
|
||||
QFont appFont(AppFont::Role role) const;
|
||||
/** @brief Whether the active theme defines this role in fonts.toml. */
|
||||
bool hasAppFont(AppFont::Role role) const;
|
||||
/** @brief Resolves an application font role against the startup font only,
|
||||
* ignoring any previewed config in currentFonts. Editors that show
|
||||
* "what this role resolves to" must use this, because appFont()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue