kdeui: add definitions for default fonts

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2022-01-17 07:10:52 +02:00
parent a3d01272c0
commit 70001acb2c
2 changed files with 16 additions and 28 deletions

View file

@ -341,26 +341,25 @@ struct KFontData
// NOTE: keep in sync with kdebase/workspace/kcontrol/fonts/fonts.cpp
static const char GeneralId[] = "General";
static const char DefaultFont[] = "Sans Serif";
static const KFontData DefaultFontData[KGlobalSettingsData::FontTypesCount] =
{
#if QT_VERSION < 0x041200
{ GeneralId, "font", DefaultFont, 9, -1, QFont::SansSerif },
{ GeneralId, "fixed", "Monospace", 9, -1, QFont::TypeWriter },
{ GeneralId, "toolBarFont", DefaultFont, 8, -1, QFont::SansSerif },
{ GeneralId, "menuFont", DefaultFont, 9, -1, QFont::SansSerif },
{ "WM", "activeFont", DefaultFont, 8, -1, QFont::SansSerif },
{ GeneralId, "taskbarFont", DefaultFont, 9, -1, QFont::SansSerif },
{ GeneralId, "smallestReadableFont", DefaultFont, 8, -1, QFont::SansSerif }
{ GeneralId, "font", KDE_DEFAULT_FONT, 9, -1, QFont::SansSerif },
{ GeneralId, "fixed", KDE_DEFAULT_FIXED_FONT, 9, -1, QFont::TypeWriter },
{ GeneralId, "toolBarFont", KDE_DEFAULT_FONT, 8, -1, QFont::SansSerif },
{ GeneralId, "menuFont", KDE_DEFAULT_FONT, 9, -1, QFont::SansSerif },
{ "WM", "activeFont", KDE_DEFAULT_FONT, 8, -1, QFont::SansSerif },
{ GeneralId, "taskbarFont", KDE_DEFAULT_FONT, 9, -1, QFont::SansSerif },
{ GeneralId, "smallestReadableFont", KDE_DEFAULT_FONT, 8, -1, QFont::SansSerif }
#else
{ GeneralId, "font", DefaultFont, 9, -1 },
{ GeneralId, "fixed", "Monospace", 9, -1 },
{ GeneralId, "toolBarFont", DefaultFont, 8, -1 },
{ GeneralId, "menuFont", DefaultFont, 9, -1 },
{ "WM", "activeFont", DefaultFont, 8, -1 },
{ GeneralId, "taskbarFont", DefaultFont, 9, -1 },
{ GeneralId, "smallestReadableFont", DefaultFont, 8, -1 }
{ GeneralId, "font", KDE_DEFAULT_FONT, 9, -1 },
{ GeneralId, "fixed", KDE_DEFAULT_FIXED_FONT, 9, -1 },
{ GeneralId, "toolBarFont", KDE_DEFAULT_FONT, 8, -1 },
{ GeneralId, "menuFont", KDE_DEFAULT_FONT, 9, -1 },
{ "WM", "activeFont", KDE_DEFAULT_FONT, 8, -1 },
{ GeneralId, "taskbarFont", KDE_DEFAULT_FONT, 9, -1 },
{ GeneralId, "smallestReadableFont", KDE_DEFAULT_FONT, 8, -1 }
#endif
};

View file

@ -42,19 +42,8 @@
#define KDE_DEFAULT_SHADE_SORT_COLUMN true
#define KDE_DEFAULT_ALLOW_DEFAULT_BACKGROUND_IMAGES true
#define KDE_DEFAULT_NATURAL_SORTING true
// browser window color defaults, ripped from khtml
#define HTML_DEFAULT_LNK_COLOR Qt::blue
#define HTML_DEFAULT_TXT_COLOR Qt::black
#define HTML_DEFAULT_VLNK_COLOR Qt::magenta
#define HTML_DEFAULT_BASE_COLOR Qt::white
#define HTML_DEFAULT_VIEW_FONT "Sans Serif"
#define HTML_DEFAULT_VIEW_FIXED_FONT "Monospace"
#define HTML_DEFAULT_VIEW_SERIF_FONT "Serif"
#define HTML_DEFAULT_VIEW_SANSSERIF_FONT "Sans Serif"
#define HTML_DEFAULT_VIEW_CURSIVE_FONT "Sans Serif"
#define HTML_DEFAULT_VIEW_FANTASY_FONT "Sans Serif"
#define HTML_DEFAULT_MIN_FONT_SIZE 7
#define KDE_DEFAULT_FONT "Sans Serif"
#define KDE_DEFAULT_FIXED_FONT "Monospace"
// misc overrides
#define BUG_REPORT_URL "https://github.com/fluxer/katana/issues"