1
0
mirror of https://github.com/Swordfish90/cool-retro-term.git synced 2026-02-08 00:32:27 +00:00

Update default profiles and fix a bunch of smaller issues.

This commit is contained in:
Filippo Scognamiglio
2026-01-10 18:26:40 +01:00
parent f518345430
commit b4e1077cb1
4 changed files with 371 additions and 175 deletions

View File

@@ -129,9 +129,9 @@ int main(int argc, char *argv[])
// Manage import paths for Linux and OSX. // Manage import paths for Linux and OSX.
QStringList importPathList = engine.importPathList(); QStringList importPathList = engine.importPathList();
importPathList.prepend(QCoreApplication::applicationDirPath() + "/qmltermwidget"); importPathList.append(QCoreApplication::applicationDirPath() + "/qmltermwidget");
importPathList.prepend(QCoreApplication::applicationDirPath() + "/../PlugIns"); importPathList.append(QCoreApplication::applicationDirPath() + "/../PlugIns");
importPathList.prepend(QCoreApplication::applicationDirPath() + "/../../../qmltermwidget"); importPathList.append(QCoreApplication::applicationDirPath() + "/../../../qmltermwidget");
engine.setImportPathList(importPathList); engine.setImportPathList(importPathList);
engine.load(QUrl(QStringLiteral ("qrc:/main.qml"))); engine.load(QUrl(QStringLiteral ("qrc:/main.qml")));

View File

@@ -175,7 +175,7 @@ QtObject {
var pixelSize = fontManager.item.pixelSize var pixelSize = fontManager.item.pixelSize
var lineSpacing = fontManager.item.lineSpacing var lineSpacing = fontManager.item.lineSpacing
var screenScaling = fontManager.item.screenScaling var screenScaling = fontManager.item.screenScaling
var fontWidth = fontManager.item.defaultFontWidth * appSettings.fontWidth var fontWidth = (fontManager.item.baseWidth ?? 1.0) * appSettings.fontWidth
var fontFamily = fontManager.item.family var fontFamily = fontManager.item.family
var isSystemFont = fontManager.item.isSystemFont var isSystemFont = fontManager.item.isSystemFont
var lowResolutionFont = fontManager.item.lowResolutionFont; var lowResolutionFont = fontManager.item.lowResolutionFont;
@@ -267,20 +267,17 @@ QtObject {
"windowScaling": windowScaling, "windowScaling": windowScaling,
"showTerminalSize": showTerminalSize, "showTerminalSize": showTerminalSize,
"fontScaling": fontScaling, "fontScaling": fontScaling,
"fontName": fontName,
"fontSource": fontSource,
"showMenubar": showMenubar, "showMenubar": showMenubar,
"bloomQuality": bloomQuality, "bloomQuality": bloomQuality,
"burnInQuality": burnInQuality, "burnInQuality": burnInQuality,
"useCustomCommand": useCustomCommand, "useCustomCommand": useCustomCommand,
"customCommand": customCommand, "customCommand": customCommand
"lineSpacing": lineSpacing
} }
return stringify(settings) return stringify(settings)
} }
function composeProfileObject() { function composeProfileObject() {
var settings = { var profile = {
"backgroundColor": _backgroundColor, "backgroundColor": _backgroundColor,
"fontColor": _fontColor, "fontColor": _fontColor,
"flickering": flickering, "flickering": flickering,
@@ -309,7 +306,7 @@ QtObject {
"frameColor": _frameColor, "frameColor": _frameColor,
"frameShininess": _frameShininess "frameShininess": _frameShininess
} }
return settings return profile
} }
function composeProfileString() { function composeProfileString() {
@@ -360,9 +357,7 @@ QtObject {
width = settings.width !== undefined ? settings.width : width width = settings.width !== undefined ? settings.width : width
height = settings.height !== undefined ? settings.height : height height = settings.height !== undefined ? settings.height : height
fontName = settings.fontName !== undefined ? settings.fontName : fontName
fontScaling = settings.fontScaling !== undefined ? settings.fontScaling : fontScaling fontScaling = settings.fontScaling !== undefined ? settings.fontScaling : fontScaling
fontSource = settings.fontSource !== undefined ? settings.fontSource : fontSource
showMenubar = settings.showMenubar !== undefined ? settings.showMenubar : showMenubar showMenubar = settings.showMenubar !== undefined ? settings.showMenubar : showMenubar
@@ -480,13 +475,13 @@ QtObject {
ListElement { ListElement {
text: "Default Amber" text: "Default Amber"
obj_string: '{ obj_string: '{
"ambientLight": 0.2, "ambientLight": 0.3,
"backgroundColor": "#000000", "backgroundColor": "#000000",
"bloom": 0.5538, "bloom": 0.6,
"brightness": 0.5, "brightness": 0.5,
"burnIn": 0.2517, "burnIn": 0.3,
"chromaColor": 0.2483, "chromaColor": 0.2,
"contrast": 0.7959, "contrast": 0.8,
"flickering": 0.1, "flickering": 0.1,
"fontColor": "#ff8100", "fontColor": "#ff8100",
"fontName": "TERMINUS_SCALED", "fontName": "TERMINUS_SCALED",
@@ -494,281 +489,461 @@ QtObject {
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.2, "glowingLine": 0.2,
"horizontalSync": 0.08, "horizontalSync": 0.1,
"jitter": 0.1997, "jitter": 0.2,
"rasterization": 0, "rasterization": 0,
"rbgShift": 0, "rbgShift": 0,
"saturationColor": 0.2483, "saturationColor": 0.2,
"screenCurvature": 0.3, "screenCurvature": 0.4,
"staticNoise": 0.1198, "screenRadius": 0.3,
"staticNoise": 0.1,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.3,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.1, "frameSize": 0.1,
"frameColor": "#ffffff", "frameColor": "#f2d4a7",
"frameShininess": 0.2 "frameShininess": 0.3
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "Monochrome Green" text: "Monochrome Green"
obj_string: '{ obj_string: '{
"ambientLight": 0.2, "ambientLight": 0.3,
"backgroundColor": "#000000", "backgroundColor": "#000000",
"bloom": 0.5538, "bloom": 0.5,
"brightness": 0.5, "brightness": 0.5,
"burnIn": 0.2517, "burnIn": 0.3,
"chromaColor": 0.0, "chromaColor": 0.0,
"contrast": 0.7959, "contrast": 0.8,
"flickering": 0.1, "flickering": 0.1,
"fontColor": "#0ccc68", "fontColor": "#0ccc68",
"fontName": "TERMINUS_SCALED", "fontName": "EXCELSIOR_SCALED",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.2, "glowingLine": 0.2,
"horizontalSync": 0.08, "horizontalSync": 0.1,
"jitter": 0.1997, "jitter": 0.2,
"rasterization": 0, "rasterization": 0,
"rbgShift": 0, "rbgShift": 0,
"saturationColor": 0.0, "saturationColor": 0.0,
"screenCurvature": 0.3, "screenCurvature": 0.7,
"staticNoise": 0.1198, "screenRadius": 0.6,
"staticNoise": 0.1,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.3,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.1, "frameSize": 0.1,
"frameColor": "#ffffff", "frameColor": "#bdeed2",
"frameShininess": 0.2 "frameShininess": 0.1
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "Green Scanlines" text: "Deep Blue"
obj_string: '{ obj_string: '{
"ambientLight": 0, "ambientLight": 0.0,
"backgroundColor": "#000000", "backgroundColor": "#000000",
"bloom": 0.6, "bloom": 0.6,
"brightness": 0.5, "brightness": 0.5,
"burnIn": 0.3, "burnIn": 0.3,
"chromaColor": 0.5, "chromaColor": 1.0,
"contrast": 0.6, "contrast": 0.8,
"flickering": 0.1, "flickering": 0.1,
"fontColor": "#7cff4f", "fontColor": "#7fb4ff",
"fontName": "PRO_FONT_SCALED", "fontName": "COZETTE_SCALED",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.2, "glowingLine": 0.2,
"horizontalSync": 0.151, "horizontalSync": 0.1,
"jitter": 0.11, "jitter": 0.2,
"rasterization": 1, "rasterization": 0,
"rbgShift": 0, "rbgShift": 0,
"saturationColor": 0.5, "saturationColor": 0.2,
"screenCurvature": 0.3, "screenCurvature": 1.0,
"staticNoise": 0.15, "screenRadius": 0.3,
"staticNoise": 0.1,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.3,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.1, "frameSize": 0.1,
"frameColor": "#ffffff", "frameColor": "#ffffff",
"frameShininess": 0.2 "frameShininess": 0.9
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "Default Pixelated" text: "Commodore 64"
obj_string: '{ obj_string: '{
"ambientLight": 0, "ambientLight": 0.4,
"backgroundColor": "#000000", "backgroundColor": "#3b3b8f",
"bloom": 0.4045, "bloom": 0.4,
"brightness": 0.6041, "brightness": 0.6,
"burnIn": 0.1024, "burnIn": 0.1,
"chromaColor": 0.7517, "chromaColor": 0.0,
"contrast": 0.7473, "contrast": 0.7,
"flickering": 0.1962, "flickering": 0.1,
"fontColor": "#ffffff", "fontColor": "#a9a7ff",
"fontName": "COMMODORE_PET", "fontName": "COMMODORE_64_SCALED",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.2, "glowingLine": 0.1,
"horizontalSync": 0.151, "horizontalSync": 0.0,
"jitter": 0, "jitter": 0.0,
"rasterization": 2, "rasterization": 1,
"rbgShift": 0, "rbgShift": 0,
"saturationColor": 0, "saturationColor": 0,
"screenCurvature": 0, "screenCurvature": 0.5,
"staticNoise": 0.15, "screenRadius": 0.4,
"staticNoise": 0.1,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.3,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.1, "frameSize": 0.5,
"frameColor": "#ffffff", "frameColor": "#444444",
"frameShininess": 0.2 "frameShininess": 0.0
}'
builtin: true
}
ListElement {
text: "Commodore PET"
obj_string: '{
"ambientLight": 0.0,
"backgroundColor": "#000000",
"bloom": 0.4,
"brightness": 0.5,
"burnIn": 0.4,
"chromaColor": 0,
"contrast": 0.8,
"flickering": 0.2,
"fontColor": "#ffffff",
"fontName": "COMMODORE_PET_SCALED",
"fontSource": 0,
"fontWidth": 1.25,
"lineSpacing": 0.1,
"glowingLine": 0.3,
"horizontalSync": 0.2,
"jitter": 0.15,
"rasterization": 1,
"rbgShift": 0.1,
"saturationColor": 0,
"screenCurvature": 1.0,
"screenRadius": 1.0,
"staticNoise": 0.2,
"windowOpacity": 1,
"margin": 0.2,
"blinkingCursor": false,
"frameSize": 0.8,
"frameColor": "#000000",
"frameShininess": 0.6
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "Apple ][" text: "Apple ]["
obj_string: '{ obj_string: '{
"ambientLight": 0.3038, "ambientLight": 1.0,
"backgroundColor": "#000000", "backgroundColor": "#001100",
"bloom": 0.5, "bloom": 0.3,
"brightness": 0.5, "brightness": 0.5,
"burnIn": 0.5017, "burnIn": 0.3,
"chromaColor": 0, "chromaColor": 0,
"contrast": 0.85, "contrast": 0.8,
"flickering": 0.2, "flickering": 0.2,
"fontColor": "#00d56d", "fontColor": "#4dff6b",
"fontName": "APPLE_II", "fontName": "APPLE_II_SCALED",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1.25,
"lineSpacing": 0.1,
"glowingLine": 0.22,
"horizontalSync": 0.16,
"jitter": 0.1,
"rasterization": 1,
"rbgShift": 0,
"saturationColor": 0,
"screenCurvature": 0.5,
"staticNoise": 0.099,
"windowOpacity": 1,
"margin": 0.5,
"blinkingCursor": false,
"frameSize": 0.2,
"frameColor": "#ffffff",
"frameShininess": 0.2
}'
builtin: true
}
ListElement {
text: "Vintage"
obj_string: '{
"ambientLight": 0.5,
"backgroundColor": "#000000",
"bloom": 0.4983,
"brightness": 0.5014,
"burnIn": 0.4983,
"chromaColor": 0,
"contrast": 0.7473,
"flickering": 0.9,
"fontColor": "#00ff3e",
"fontName": "COMMODORE_PET",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.3, "glowingLine": 0.3,
"horizontalSync": 0.42, "horizontalSync": 0.2,
"jitter": 0.4, "jitter": 0.2,
"rasterization": 1, "rasterization": 1,
"rbgShift": 0.2969, "rbgShift": 0.1,
"saturationColor": 0, "saturationColor": 0,
"screenCurvature": 0.5, "screenCurvature": 1.0,
"staticNoise": 0.2969, "screenRadius": 1.0,
"staticNoise": 0.2,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.0,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.5, "frameSize": 0.5,
"frameColor": "#ffffff", "frameColor": "#ffffff",
"frameShininess": 0.2 "frameShininess": 0.8
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "IBM Dos" text: "Atari 400"
obj_string: '{ obj_string: '{
"ambientLight": 0.151, "ambientLight": 0.1,
"backgroundColor": "#0f1f5a",
"bloom": 0.1,
"brightness": 0.6,
"burnIn": 0.2,
"chromaColor": 0,
"contrast": 0.9,
"flickering": 0.1,
"fontColor": "#8ed6ff",
"fontName": "ATARI_400_SCALED",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.1,
"horizontalSync": 0.0,
"jitter": 0.0,
"rasterization": 1,
"rbgShift": 0.0,
"saturationColor": 0,
"screenCurvature": 0.3,
"screenRadius": 0.5,
"staticNoise": 0.1,
"windowOpacity": 1,
"margin": 0.2,
"blinkingCursor": false,
"frameSize": 0.4,
"frameColor": "#8ed6ff",
"frameShininess": 0.3
}'
builtin: true
}
ListElement {
text: "IBM VGA 8x16"
obj_string: '{
"ambientLight": 0.2,
"backgroundColor": "#000000", "backgroundColor": "#000000",
"bloom": 0.2969, "bloom": 0.2,
"brightness": 0.5, "brightness": 0.6,
"burnIn": 0.0469, "burnIn": 0.1,
"chromaColor": 1, "chromaColor": 0.5,
"contrast": 0.85, "contrast": 1.0,
"flickering": 0.0955, "flickering": 0.1,
"fontColor": "#ffffff", "fontColor": "#c0c0c0",
"fontName": "IBM_VGA_8x16", "fontName": "IBM_VGA_8x16",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.1545, "glowingLine": 0.1,
"horizontalSync": 0, "horizontalSync": 0.0,
"jitter": 0.1545, "jitter": 0.0,
"rasterization": 0, "rasterization": 1,
"rbgShift": 0.3524, "rbgShift": 0.15,
"saturationColor": 0, "saturationColor": 0,
"screenCurvature": 0.4, "screenCurvature": 0.3,
"staticNoise": 0.0503, "screenRadius": 0.2,
"staticNoise": 0.0,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.2,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.2, "frameSize": 0.1,
"frameColor": "#ffffff", "frameColor": "#ffffff",
"frameShininess": 0.2 "frameShininess": 0.3
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "IBM 3278" text: "IBM 3278"
obj_string: '{ obj_string: '{
"ambientLight": 0.1, "ambientLight": 0.2,
"backgroundColor": "#000000", "backgroundColor": "#000000",
"bloom": 0.2969, "bloom": 0.2,
"brightness": 0.5, "brightness": 0.5,
"burnIn": 0.6, "burnIn": 0.7,
"chromaColor": 0, "chromaColor": 0,
"contrast": 0.85, "contrast": 0.8,
"flickering": 0, "flickering": 0,
"fontColor": "#0ccc68", "fontColor": "#3cff7a",
"fontName": "IBM_3278", "fontName": "IBM_3278",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0, "glowingLine": 0.0,
"horizontalSync": 0, "horizontalSync": 0,
"jitter": 0, "jitter": 0,
"rasterization": 0, "rasterization": 4,
"rbgShift": 0, "rbgShift": 0,
"saturationColor": 0, "saturationColor": 0,
"screenCurvature": 0.2, "screenCurvature": 0,
"staticNoise": 0, "screenRadius": 0.0,
"staticNoise": 0.0,
"windowOpacity": 1, "windowOpacity": 1,
"margin": 0.5, "margin": 0.1,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0.1, "frameSize": 0,
"frameColor": "#ffffff", "frameColor": "#ffffff",
"frameShininess": 0.2 "frameShininess": 0.2
}' }'
builtin: true builtin: true
} }
ListElement { ListElement {
text: "Futuristic" text: "Neon Cyan"
obj_string: '{ obj_string: '{
"ambientLight": 0, "ambientLight": 0.1,
"backgroundColor": "#000000", "backgroundColor": "#001018",
"bloom": 0.5017, "bloom": 0.6,
"brightness": 0.5014, "brightness": 0.6,
"burnIn": 0.0955, "burnIn": 0.1,
"chromaColor": 1, "chromaColor": 1,
"contrast": 0.85, "contrast": 0.9,
"flickering": 0.2, "flickering": 0.1,
"fontColor": "#729fcf", "fontColor": "#52f7ff",
"fontName": "TERMINUS", "fontName": "IOSEVKA",
"fontSource": 0, "fontSource": 0,
"fontWidth": 1, "fontWidth": 1,
"lineSpacing": 0.1, "lineSpacing": 0.1,
"glowingLine": 0.1476, "glowingLine": 0.2,
"horizontalSync": 0, "horizontalSync": 0.0,
"jitter": 0.099, "jitter": 0.1,
"rasterization": 0, "rasterization": 4,
"rbgShift": 0, "rbgShift": 0.0,
"saturationColor": 0.4983, "saturationColor": 0.6,
"screenCurvature": 0, "screenCurvature": 0,
"staticNoise": 0.0955, "screenRadius": 0.0,
"staticNoise": 0.1,
"windowOpacity": 0.8,
"margin": 0.1,
"blinkingCursor": false,
"frameSize": 0,
"frameColor": "#52f7ff",
"frameShininess": 0.2
}'
builtin: true
}
ListElement {
text: "Ghost Terminal"
obj_string: '{
"ambientLight": 0.3,
"backgroundColor": "#0b1014",
"bloom": 0.3,
"brightness": 0.6,
"burnIn": 0.2,
"chromaColor": 0,
"contrast": 0.5,
"flickering": 0.0,
"fontColor": "#a6b3c0",
"fontName": "JETBRAINS_MONO",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.1,
"horizontalSync": 0.0,
"jitter": 0.0,
"rasterization": 4,
"rbgShift": 0.1,
"saturationColor": 0.0,
"screenCurvature": 0,
"screenRadius": 0.0,
"staticNoise": 0.1,
"windowOpacity": 0.7, "windowOpacity": 0.7,
"margin": 0.1, "margin": 0.1,
"blinkingCursor": false, "blinkingCursor": false,
"frameSize": 0, "frameSize": 0,
"frameColor": "#ffffff", "frameColor": "#9aa7b3",
"frameShininess": 0.2
}'
builtin: true
}
ListElement {
text: "Plasma"
obj_string: '{
"ambientLight": 0.1,
"backgroundColor": "#070014",
"bloom": 0.7,
"brightness": 0.6,
"burnIn": 0.1,
"chromaColor": 1,
"contrast": 0.8,
"flickering": 0.1,
"fontColor": "#ff9bd6",
"fontName": "FIRA_CODE",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.2,
"horizontalSync": 0.0,
"jitter": 0.1,
"rasterization": 4,
"rbgShift": 0.1,
"saturationColor": 0.8,
"screenCurvature": 0,
"screenRadius": 0.0,
"staticNoise": 0.1,
"windowOpacity": 1.0,
"margin": 0.1,
"blinkingCursor": false,
"frameSize": 0,
"frameColor": "#ff9bd6",
"frameShininess": 0.2
}'
builtin: true
}
ListElement {
text: "Boring"
obj_string: '{
"ambientLight": 0.1,
"backgroundColor": "#000000",
"bloom": 0.5,
"brightness": 0.5,
"burnIn": 0.05,
"chromaColor": 1,
"contrast": 0.8,
"flickering": 0.0,
"fontColor": "#ffffff",
"fontName": "JETBRAINS_MONO",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.1,
"horizontalSync": 0,
"jitter": 0.0,
"rasterization": 4,
"rbgShift": 0,
"saturationColor": 0.0,
"screenCurvature": 0,
"screenRadius": 0.0,
"staticNoise": 0.0,
"windowOpacity": 1.0,
"margin": 0.0,
"blinkingCursor": false,
"frameSize": 0,
"frameColor": "#c0c0c0",
"frameShininess": 0.2
}'
builtin: true
}
ListElement {
text: "E-Ink"
obj_string: '{
"ambientLight": 0.6,
"backgroundColor": "#f2f2ec",
"bloom": 0.0,
"brightness": 1.0,
"burnIn": 0.6,
"chromaColor": 0,
"contrast": 0.5,
"flickering": 0.0,
"fontColor": "#101010",
"fontName": "HACK",
"fontSource": 0,
"fontWidth": 1,
"lineSpacing": 0.1,
"glowingLine": 0.0,
"horizontalSync": 0.0,
"jitter": 0.0,
"rasterization": 4,
"rbgShift": 0,
"saturationColor": 0,
"screenCurvature": 0,
"screenRadius": 0.0,
"staticNoise": 0.0,
"windowOpacity": 1,
"margin": 0.1,
"blinkingCursor": false,
"frameSize": 0,
"frameColor": "#d0d0c8",
"frameShininess": 0.2 "frameShininess": 0.2
}' }'
builtin: true builtin: true

View File

@@ -37,6 +37,8 @@ QtObject {
property int pixelSize: lowResolutionFont ? _font.pixelSize : targetPixelHeight property int pixelSize: lowResolutionFont ? _font.pixelSize : targetPixelHeight
property real baseWidth: _font.baseWidth ?? 1.0
// Line spacing expressed as a relative factor for all fonts. // Line spacing expressed as a relative factor for all fonts.
property real lineSpacingFactor: appSettings.lineSpacing property real lineSpacingFactor: appSettings.lineSpacing
property int lineSpacing: Math.round(targetPixelHeight * lineSpacingFactor) property int lineSpacing: Math.round(targetPixelHeight * lineSpacingFactor)
@@ -54,7 +56,7 @@ QtObject {
property bool isSystemFont: fontlist.get(selectedFontIndex).isSystemFont property bool isSystemFont: fontlist.get(selectedFontIndex).isSystemFont
property string family: fontlist.get(selectedFontIndex).family property string family: fontlist.get(selectedFontIndex).family ?? ""
// There are two kind of fonts: low resolution and high resolution. // There are two kind of fonts: low resolution and high resolution.
// Low resolution font sets the lowResolutionFont property to true. // Low resolution font sets the lowResolutionFont property to true.
@@ -68,6 +70,7 @@ QtObject {
name: "TERMINUS_SCALED" name: "TERMINUS_SCALED"
text: "Terminus" text: "Terminus"
source: "fonts/terminus/TerminusTTF-4.49.3.ttf" source: "fonts/terminus/TerminusTTF-4.49.3.ttf"
baseWidth: 1.0
pixelSize: 12 pixelSize: 12
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -76,6 +79,7 @@ QtObject {
name: "EXCELSIOR_SCALED" name: "EXCELSIOR_SCALED"
text: "Fixedsys Excelsior" text: "Fixedsys Excelsior"
source: "fonts/fixedsys-excelsior/FSEX301-L2.ttf" source: "fonts/fixedsys-excelsior/FSEX301-L2.ttf"
baseWidth: 1.0
pixelSize: 16 pixelSize: 16
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -85,6 +89,7 @@ QtObject {
name: "GREYBEARD_SCALED" name: "GREYBEARD_SCALED"
text: "Greybeard" text: "Greybeard"
source: "fonts/greybeard/Greybeard-16px.ttf" source: "fonts/greybeard/Greybeard-16px.ttf"
baseWidth: 1.0
pixelSize: 16 pixelSize: 16
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -94,6 +99,7 @@ QtObject {
name: "COMMODORE_PET_SCALED" name: "COMMODORE_PET_SCALED"
text: "Commodore PET" text: "Commodore PET"
source: "fonts/pet-me/PetMe.ttf" source: "fonts/pet-me/PetMe.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -103,6 +109,7 @@ QtObject {
name: "COZETTE_SCALED" name: "COZETTE_SCALED"
text: "Cozette" text: "Cozette"
source: "fonts/cozette/CozetteVector.ttf" source: "fonts/cozette/CozetteVector.ttf"
baseWidth: 1.0
pixelSize: 13 pixelSize: 13
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -111,6 +118,7 @@ QtObject {
name: "UNSCII_8_SCALED" name: "UNSCII_8_SCALED"
text: "Unscii 8" text: "Unscii 8"
source: "fonts/unscii/unscii-8.ttf" source: "fonts/unscii/unscii-8.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -120,6 +128,7 @@ QtObject {
name: "UNSCII_8_THIN_SCALED" name: "UNSCII_8_THIN_SCALED"
text: "Unscii 8 Thin" text: "Unscii 8 Thin"
source: "fonts/unscii/unscii-8-thin.ttf" source: "fonts/unscii/unscii-8-thin.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -129,6 +138,7 @@ QtObject {
name: "UNSCII_16_SCALED" name: "UNSCII_16_SCALED"
text: "Unscii 16" text: "Unscii 16"
source: "fonts/unscii/unscii-16-full.ttf" source: "fonts/unscii/unscii-16-full.ttf"
baseWidth: 1.0
pixelSize: 16 pixelSize: 16
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -138,6 +148,7 @@ QtObject {
name: "APPLE_II_SCALED" name: "APPLE_II_SCALED"
text: "Apple ][" text: "Apple ]["
source: "fonts/apple2/PrintChar21.ttf" source: "fonts/apple2/PrintChar21.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -147,6 +158,7 @@ QtObject {
name: "ATARI_400_SCALED" name: "ATARI_400_SCALED"
text: "Atari 400-800" text: "Atari 400-800"
source: "fonts/atari-400-800/AtariClassic-Regular.ttf" source: "fonts/atari-400-800/AtariClassic-Regular.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -156,6 +168,7 @@ QtObject {
name: "COMMODORE_64_SCALED" name: "COMMODORE_64_SCALED"
text: "Commodore 64" text: "Commodore 64"
source: "fonts/pet-me/PetMe64.ttf" source: "fonts/pet-me/PetMe64.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -165,6 +178,7 @@ QtObject {
name: "IBM_EGA_8x8" name: "IBM_EGA_8x8"
text: "IBM EGA 8x8" text: "IBM EGA 8x8"
source: "fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf" source: "fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf"
baseWidth: 0.5
pixelSize: 8 pixelSize: 8
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -174,6 +188,7 @@ QtObject {
name: "IBM_VGA_8x16" name: "IBM_VGA_8x16"
text: "IBM VGA 8x16" text: "IBM VGA 8x16"
source: "fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf" source: "fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf"
baseWidth: 1.0
pixelSize: 16 pixelSize: 16
lowResolutionFont: true lowResolutionFont: true
isSystemFont: false isSystemFont: false
@@ -183,7 +198,8 @@ QtObject {
name: "TERMINUS" name: "TERMINUS"
text: "Terminus" text: "Terminus"
source: "fonts/terminus/TerminusTTF-4.49.3.ttf" source: "fonts/terminus/TerminusTTF-4.49.3.ttf"
pixelSize: 35 baseWidth: 1.0
pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false
} }
@@ -191,7 +207,8 @@ QtObject {
name: "HACK" name: "HACK"
text: "Hack" text: "Hack"
source: "fonts/hack/Hack-Regular.ttf" source: "fonts/hack/Hack-Regular.ttf"
pixelSize: 35 baseWidth: 1.0
pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false
} }
@@ -199,7 +216,8 @@ QtObject {
name: "FIRA_CODE" name: "FIRA_CODE"
text: "Fira Code" text: "Fira Code"
source: "fonts/fira-code/FiraCode-Medium.ttf" source: "fonts/fira-code/FiraCode-Medium.ttf"
pixelSize: 35 baseWidth: 1.0
pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false
} }
@@ -207,7 +225,8 @@ QtObject {
name: "IOSEVKA" name: "IOSEVKA"
text: "Iosevka" text: "Iosevka"
source: "fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf" source: "fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf"
pixelSize: 35 baseWidth: 1.0
pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false
} }
@@ -215,7 +234,8 @@ QtObject {
name: "JETBRAINS_MONO" name: "JETBRAINS_MONO"
text: "JetBrains Mono" text: "JetBrains Mono"
source: "fonts/jetbrains-mono/JetBrainsMono-Medium.ttf" source: "fonts/jetbrains-mono/JetBrainsMono-Medium.ttf"
pixelSize: 35 baseWidth: 1.0
pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false
} }
@@ -223,6 +243,7 @@ QtObject {
name: "IBM_3278" name: "IBM_3278"
text: "IBM 3278" text: "IBM 3278"
source: "fonts/ibm-3278/3270-Regular.ttf" source: "fonts/ibm-3278/3270-Regular.ttf"
baseWidth: 1.0
pixelSize: 32 pixelSize: 32
lowResolutionFont: false lowResolutionFont: false
isSystemFont: false isSystemFont: false