1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-01-29 07:52:50 -05:00

General code cleanups

This commit is contained in:
bbedward
2025-08-02 16:18:12 -04:00
parent 2cf7497324
commit 599118c63e
68 changed files with 102 additions and 1241 deletions

View File

@@ -10,18 +10,14 @@ Text {
color: Theme.surfaceText
font.pixelSize: Appearance.fontSize.normal
font.family: {
// Use system default
var requestedFont = isMonospace ? Prefs.monoFontFamily : Prefs.fontFamily;
var defaultFont = isMonospace ? Prefs.defaultMonoFontFamily : Prefs.defaultFontFamily;
// If user hasn't overridden the font and we're using the default
if (requestedFont === defaultFont) {
var availableFonts = Qt.fontFamilies();
if (!availableFonts.includes(requestedFont))
return isMonospace ? "Monospace" : "DejaVu Sans";
}
// Either user overrode it, or default font is available
return requestedFont;
}
font.weight: Prefs.fontWeight