mirror of
https://github.com/Swordfish90/cool-retro-term.git
synced 2026-02-08 08:42:22 +00:00
Compare commits
19 Commits
1.2.0
...
qt6-improv
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6747b8dd7c | ||
|
|
cf68aca735 | ||
|
|
265caf0df7 | ||
|
|
477621dd3e | ||
|
|
f77dad0c47 | ||
|
|
4faa6d522d | ||
|
|
ef11a4b7ef | ||
|
|
3bcf11264b | ||
|
|
68af947687 | ||
|
|
002c85e35f | ||
|
|
fed2bf21fe | ||
|
|
3f51308057 | ||
|
|
70d7d1b9ce | ||
|
|
c1082f2e3e | ||
|
|
7038b30381 | ||
|
|
1d73abda51 | ||
|
|
f157648d1e | ||
|
|
d4baaeccfc | ||
|
|
d412b66c6e |
98
.github/workflows/appimage.yml
vendored
Normal file
98
.github/workflows/appimage.yml
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
name: "ci"
|
||||
|
||||
on:
|
||||
push:
|
||||
tags: "**"
|
||||
workflow_dispatch:
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
jobs:
|
||||
appimage:
|
||||
runs-on: ubuntu-18.04
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
submodules: true
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo add-apt-repository -y ppa:beineri/opt-qt-5.15.2-bionic
|
||||
sudo apt-get update -qq
|
||||
sudo apt-get install -y \
|
||||
build-essential make wget libgl1-mesa-dev \
|
||||
qt515declarative qt515graphicaleffects \
|
||||
qt515quickcontrols qt515quickcontrols2
|
||||
|
||||
- name: Download QT appimage builder
|
||||
run: |
|
||||
wget -c -O linuxdeployqt.AppImage \
|
||||
https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage
|
||||
chmod a+x linuxdeployqt.AppImage
|
||||
|
||||
- name: Build project
|
||||
run: |
|
||||
source /opt/qt*/bin/qt*-env.sh && \
|
||||
qmake -v && \
|
||||
qmake CONFIG+=release PREFIX=/usr && \
|
||||
make -j$(nproc)
|
||||
|
||||
- name: Install to appdir
|
||||
run: |
|
||||
source /opt/qt*/bin/qt*-env.sh && \
|
||||
make INSTALL_ROOT=appdir -j$(nproc) install
|
||||
|
||||
- name: Extract version number
|
||||
run: |
|
||||
# Extract version for linuxdeployqt to name the file. Use the tag as
|
||||
# release name but remove prefix.
|
||||
echo "VERSION=$(echo '${{ github.ref }}' | sed 's;.*/;;')" >> $GITHUB_ENV
|
||||
|
||||
- name: Build appimage directory
|
||||
run: |
|
||||
mkdir -p \
|
||||
appdir/usr/bin \
|
||||
appdir/usr/lib \
|
||||
appdir/usr/share/applications \
|
||||
appdir/usr/share/metainfo \
|
||||
appdir/usr/share/icons/hicolor/128x128/apps
|
||||
|
||||
cp cool-retro-term appdir/usr/bin/
|
||||
cp cool-retro-term.desktop appdir/usr/share/applications/
|
||||
cp packaging/appdata/cool-retro-term.appdata.xml appdir/usr/share/metainfo/
|
||||
cp app/icons/128x128/cool-retro-term.png appdir/usr/share/icons/hicolor/128x128/apps/
|
||||
cp -r ./app/qml appdir/usr/
|
||||
# Workaround for https://github.com/probonopd/linuxdeployqt/issues/78
|
||||
cp -r ./qmltermwidget/QMLTermWidget appdir/usr/qml/
|
||||
|
||||
find appdir | sort
|
||||
|
||||
- name: Build appimage
|
||||
run: |
|
||||
source /opt/qt*/bin/qt*-env.sh && \
|
||||
./linuxdeployqt.AppImage appdir/usr/share/applications/cool-retro-term.desktop \
|
||||
-verbose=1 -appimage \
|
||||
-qmldir=./app/qml/ \
|
||||
-qmldir=./qmltermwidget/
|
||||
env:
|
||||
# Unset environment variables
|
||||
QTDIR:
|
||||
QT_PLUGIN_PATH:
|
||||
LD_LIBRARY_PATH:
|
||||
|
||||
- name: Upload release
|
||||
uses: softprops/action-gh-release@v1
|
||||
with:
|
||||
body: appimage release
|
||||
files: ./**/Cool_Retro_Term-*-x86_64.AppImage
|
||||
|
||||
- name: Clean up
|
||||
if: always()
|
||||
run: |
|
||||
find appdir -executable -type f -exec ldd {} \; | grep " => /usr" | cut -d " " -f 2-3 | sort | uniq
|
||||
make clean
|
||||
rm -rf appdir
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -43,6 +43,7 @@ Makefile*
|
||||
# Excludes compiled files
|
||||
imports
|
||||
cool-retro-term
|
||||
build
|
||||
|
||||
# Mac OSX
|
||||
|
||||
|
||||
17
app/app.pro
17
app/app.pro
@@ -15,6 +15,23 @@ macx:ICON = icons/crt.icns
|
||||
|
||||
RESOURCES += qml/resources.qrc
|
||||
|
||||
# Shader compilation (Qt Shader Baker)
|
||||
QSB_BIN = $$[QT_HOST_BINS]/qsb
|
||||
isEmpty(QSB_BIN): QSB_BIN = $$[QT_INSTALL_BINS]/qsb
|
||||
|
||||
SHADERS_DIR = $${_PRO_FILE_PWD_}/shaders
|
||||
SHADERS += $$files($$SHADERS_DIR/*.frag) $$files($$SHADERS_DIR/*.vert)
|
||||
|
||||
qsb.input = SHADERS
|
||||
qsb.output = ../../app/shaders/${QMAKE_FILE_NAME}.qsb
|
||||
qsb.commands = $$QSB_BIN --glsl \"100 es,120,150\" --hlsl 50 --msl 12 --qt6 -o ${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
|
||||
qsb.clean = $$qsb.output
|
||||
qsb.name = qsb ${QMAKE_FILE_IN}
|
||||
qsb.variable_out = QSB_FILES
|
||||
QMAKE_EXTRA_COMPILERS += qsb
|
||||
PRE_TARGETDEPS += $$QSB_FILES
|
||||
OTHER_FILES += $$SHADERS $$QSB_FILES
|
||||
|
||||
#########################################
|
||||
## INTALLS
|
||||
#########################################
|
||||
|
||||
44
app/main.cpp
44
app/main.cpp
@@ -17,6 +17,11 @@
|
||||
#include <fileio.h>
|
||||
#include <monospacefontmanager.h>
|
||||
|
||||
#if defined(Q_OS_MAC)
|
||||
#include <CoreFoundation/CoreFoundation.h>
|
||||
#include <QStyleFactory>
|
||||
#endif
|
||||
|
||||
QString getNamedArgument(QStringList args, QString name, QString defaultName)
|
||||
{
|
||||
int index = args.indexOf(name);
|
||||
@@ -31,33 +36,37 @@ QString getNamedArgument(QStringList args, QString name)
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
// Some environmental variable are necessary on certain platforms.
|
||||
|
||||
// This disables QT appmenu under Ubuntu, which is not working with QML apps.
|
||||
setenv("QT_QPA_PLATFORMTHEME", "", 1);
|
||||
|
||||
// Disable Connections slot warnings
|
||||
QLoggingCategory::setFilterRules("qt.qml.connections.warning=false");
|
||||
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::Round);
|
||||
|
||||
#if defined (Q_OS_LINUX)
|
||||
setenv("QSG_RENDER_LOOP", "threaded", 0);
|
||||
#endif
|
||||
// #if defined (Q_OS_LINUX)
|
||||
// setenv("QSG_RENDER_LOOP", "threaded", 0);
|
||||
// #endif
|
||||
|
||||
#if defined(Q_OS_MAC)
|
||||
// This allows UTF-8 characters usage in OSX.
|
||||
setenv("LC_CTYPE", "UTF-8", 1);
|
||||
|
||||
// Ensure key repeat works for letter keys (disable macOS press-and-hold for this app).
|
||||
CFPreferencesSetAppValue(CFSTR("ApplePressAndHoldEnabled"), kCFBooleanFalse, kCFPreferencesCurrentApplication);
|
||||
CFPreferencesAppSynchronize(kCFPreferencesCurrentApplication);
|
||||
|
||||
// Qt6 macOS default look is still lacking, so let's force Fusion for now
|
||||
QQuickStyle::setStyle(QStringLiteral("Fusion"));
|
||||
#endif
|
||||
|
||||
if (argc>1 && (!strcmp(argv[1],"-h") || !strcmp(argv[1],"--help"))) {
|
||||
QTextStream cout(stdout, QIODevice::WriteOnly);
|
||||
cout << "Usage: " << argv[0] << " [--default-settings] [--workdir <dir>] [--program <prog>] [-p|--profile <prof>] [--fullscreen] [-h|--help]" << endl;
|
||||
cout << " --default-settings Run cool-retro-term with the default settings" << endl;
|
||||
cout << " --workdir <dir> Change working directory to 'dir'" << endl;
|
||||
cout << " -e <cmd> Command to execute. This option will catch all following arguments, so use it as the last option." << endl;
|
||||
cout << " -T <title> Set window title to 'title'." << endl;
|
||||
cout << " --fullscreen Run cool-retro-term in fullscreen." << endl;
|
||||
cout << " -p|--profile <prof> Run cool-retro-term with the given profile." << endl;
|
||||
cout << " -h|--help Print this help." << endl;
|
||||
cout << " --verbose Print additional information such as profiles and settings." << endl;
|
||||
cout << "Usage: " << argv[0] << " [--default-settings] [--workdir <dir>] [--program <prog>] [-p|--profile <prof>] [--fullscreen] [-h|--help]" << Qt::endl;
|
||||
cout << " --default-settings Run cool-retro-term with the default settings" << Qt::endl;
|
||||
cout << " --workdir <dir> Change working directory to 'dir'" << Qt::endl;
|
||||
cout << " -e <cmd> Command to execute. This option will catch all following arguments, so use it as the last option." << Qt::endl;
|
||||
cout << " -T <title> Set window title to 'title'." << Qt::endl;
|
||||
cout << " --fullscreen Run cool-retro-term in fullscreen." << Qt::endl;
|
||||
cout << " -p|--profile <prof> Run cool-retro-term with the given profile." << Qt::endl;
|
||||
cout << " -h|--help Print this help." << Qt::endl;
|
||||
cout << " --verbose Print additional information such as profiles and settings." << Qt::endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -65,7 +74,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
if (argc>1 && (!strcmp(argv[1],"-v") || !strcmp(argv[1],"--version"))) {
|
||||
QTextStream cout(stdout, QIODevice::WriteOnly);
|
||||
cout << "cool-retro-term " << appVersion << endl;
|
||||
cout << "cool-retro-term " << appVersion << Qt::endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -101,6 +110,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
engine.rootContext()->setContextProperty("workdir", getNamedArgument(args, "--workdir", "$HOME"));
|
||||
engine.rootContext()->setContextProperty("fileIO", &fileIO);
|
||||
engine.rootContext()->setContextProperty("monospaceFontManager", &monospaceFontManager);
|
||||
engine.rootContext()->setContextProperty("monospaceSystemFonts", monospaceFontManager.retrieveMonospaceFonts());
|
||||
|
||||
engine.rootContext()->setContextProperty("devicePixelRatio", app.devicePixelRatio());
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "monospacefontmanager.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QFont>
|
||||
|
||||
MonospaceFontManager::MonospaceFontManager(QObject *parent) : QObject(parent)
|
||||
{
|
||||
@@ -23,3 +24,27 @@ QStringList MonospaceFontManager::retrieveMonospaceFonts() {
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
void MonospaceFontManager::setFontSubstitutions(const QString &family, const QStringList &substitutes)
|
||||
{
|
||||
if (family.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
QFont::removeSubstitutions(family);
|
||||
|
||||
if (substitutes.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
QFont::insertSubstitutions(family, substitutes);
|
||||
}
|
||||
|
||||
void MonospaceFontManager::removeFontSubstitution(const QString &family)
|
||||
{
|
||||
if (family.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
QFont::removeSubstitutions(family);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
#include <QObject>
|
||||
#include <QFontDatabase>
|
||||
#include <QStringList>
|
||||
|
||||
class MonospaceFontManager : public QObject
|
||||
{
|
||||
@@ -10,6 +11,10 @@ class MonospaceFontManager : public QObject
|
||||
public:
|
||||
explicit MonospaceFontManager(QObject *parent = nullptr);
|
||||
Q_INVOKABLE QStringList retrieveMonospaceFonts();
|
||||
|
||||
public slots:
|
||||
Q_INVOKABLE void setFontSubstitutions(const QString &family, const QStringList &substitutes);
|
||||
void removeFontSubstitution(const QString &family);
|
||||
};
|
||||
|
||||
#endif // MONOSPACEFONTMANAGER_H
|
||||
|
||||
@@ -22,7 +22,7 @@ import QtQuick.Controls 2.2
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Window 2.0
|
||||
|
||||
Window {
|
||||
ApplicationWindow {
|
||||
id: dialogwindow
|
||||
title: qsTr("About")
|
||||
width: 600
|
||||
@@ -37,6 +37,7 @@ Window {
|
||||
Text {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
text: "cool-retro-term"
|
||||
color: palette.text
|
||||
font {
|
||||
bold: true
|
||||
pointSize: 18
|
||||
@@ -100,6 +101,7 @@ Window {
|
||||
Text {
|
||||
Layout.alignment: Qt.AlignCenter
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
color: palette.text
|
||||
text: appSettings.version + "\n" + qsTr(
|
||||
"Author: ") + "Filippo Scognamiglio\n" + qsTr(
|
||||
"Email: ") + "flscogna@gmail.com\n" + qsTr(
|
||||
@@ -115,7 +117,8 @@ Window {
|
||||
TextArea {
|
||||
readOnly: true
|
||||
wrapMode: TextEdit.Wrap
|
||||
text: "Copyright (c) 2013-2021 Filippo Scognamiglio <flscogna@gmail.com>\n\n"
|
||||
color: palette.text
|
||||
text: "Copyright (c) 2013-2025 Filippo Scognamiglio <flscogna@gmail.com>\n\n"
|
||||
+ "https://github.com/Swordfish90/cool-retro-term\n\n" +
|
||||
"cool-retro-term is free software: you can redistribute it and/or modify "
|
||||
+ "it under the terms of the GNU General Public License as published by "
|
||||
|
||||
@@ -31,8 +31,10 @@ QtObject {
|
||||
readonly property real minimumFontScaling: 0.25
|
||||
readonly property real maximumFontScaling: 2.50
|
||||
|
||||
readonly property real minBurnInFadeTime: 160
|
||||
readonly property real maxBurnInFadeTime: 1600
|
||||
readonly property int defaultMargin: 16
|
||||
|
||||
readonly property real minBurnInFadeTime: 0.16
|
||||
readonly property real maxBurnInFadeTime: 1.6
|
||||
|
||||
property bool isMacOS: Qt.platform.os === "osx"
|
||||
|
||||
@@ -50,7 +52,7 @@ QtObject {
|
||||
property bool showTerminalSize: true
|
||||
property real windowScaling: 1.0
|
||||
|
||||
property real fps: 20
|
||||
property int effectsFrameSkip: 2
|
||||
property bool verbose: false
|
||||
|
||||
property real bloomQuality: 0.5
|
||||
@@ -58,7 +60,7 @@ QtObject {
|
||||
|
||||
property bool blinkingCursor: false
|
||||
|
||||
onWindowScalingChanged: handleFontChanged()
|
||||
onWindowScalingChanged: updateFont()
|
||||
|
||||
// PROFILE SETTINGS ///////////////////////////////////////////////////////
|
||||
property real windowOpacity: 1.0
|
||||
@@ -110,64 +112,114 @@ QtObject {
|
||||
readonly property int scanline_rasterization: 1
|
||||
readonly property int pixel_rasterization: 2
|
||||
readonly property int subpixel_rasterization: 3
|
||||
readonly property int modern_rasterization: 4
|
||||
|
||||
property int rasterization: no_rasterization
|
||||
|
||||
readonly property int bundled_fonts: 0
|
||||
readonly property int system_fonts: 1
|
||||
|
||||
property int fontSource: bundled_fonts
|
||||
|
||||
// FONTS //////////////////////////////////////////////////////////////////
|
||||
readonly property real baseFontScaling: 0.75
|
||||
property real fontScaling: 1.0
|
||||
property real totalFontScaling: baseFontScaling * fontScaling
|
||||
|
||||
property real fontWidth: 1.0
|
||||
property real lineSpacing: 0.1
|
||||
|
||||
property bool lowResolutionFont: false
|
||||
|
||||
property var fontNames: ["TERMINUS_SCALED", "COMMODORE_PET", "COMMODORE_PET"]
|
||||
property var fontlist: fontManager.item.fontlist
|
||||
property string fontName: "TERMINUS_SCALED"
|
||||
property var fontlist: fontManager.item ? fontManager.item.fontlist : null
|
||||
|
||||
signal terminalFontChanged(string fontFamily, int pixelSize, int lineSpacing, real screenScaling, real fontWidth)
|
||||
property var filteredFontList: ListModel {}
|
||||
|
||||
function updateFont() {
|
||||
if (!fontManager.item || !fontlist) return
|
||||
|
||||
filteredFontList.clear()
|
||||
var currentFontInList = false
|
||||
|
||||
for (var i = 0; i < fontlist.count; i++) {
|
||||
var font = fontlist.get(i)
|
||||
var isBundled = !font.isSystemFont
|
||||
var isSystem = font.isSystemFont
|
||||
|
||||
var matchesSource = (fontSource === bundled_fonts && isBundled) || (fontSource === system_fonts && isSystem)
|
||||
|
||||
if (!matchesSource) continue
|
||||
|
||||
var modernMode = rasterization === modern_rasterization
|
||||
var matchesRasterization = font.isSystemFont || (modernMode == !font.lowResolutionFont)
|
||||
|
||||
if (matchesRasterization) {
|
||||
filteredFontList.append(font)
|
||||
if (font.name === fontName) {
|
||||
currentFontInList = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!currentFontInList && filteredFontList.count > 0) {
|
||||
fontName = filteredFontList.get(0).name
|
||||
}
|
||||
|
||||
var index = getIndexByName(fontName)
|
||||
if (index === undefined) return
|
||||
|
||||
fontManager.item.selectedFontIndex = index
|
||||
fontManager.item.scaling = totalFontScaling
|
||||
|
||||
var fontSourcePath = fontManager.item.source
|
||||
var pixelSize = fontManager.item.pixelSize
|
||||
var lineSpacing = fontManager.item.lineSpacing
|
||||
var screenScaling = fontManager.item.screenScaling
|
||||
var fontWidth = fontManager.item.defaultFontWidth * appSettings.fontWidth
|
||||
var fontFamily = fontManager.item.family
|
||||
var isSystemFont = fontManager.item.isSystemFont
|
||||
var fallbackFontFamily = ""
|
||||
|
||||
lowResolutionFont = fontManager.item.lowResolutionFont
|
||||
|
||||
if (!isSystemFont) {
|
||||
fontLoader.source = fontSourcePath
|
||||
fontFamily = fontLoader.name
|
||||
}
|
||||
|
||||
fallbackFontLoader.source = ""
|
||||
var fallbackName = fontManager.item.fallbackName
|
||||
if (fallbackName && fallbackName !== fontName) {
|
||||
var fallbackFont = getFontByName(fallbackName)
|
||||
if (fallbackFont) {
|
||||
fallbackFontLoader.source = fallbackFont.source
|
||||
fallbackFontFamily = fallbackFontLoader.name
|
||||
}
|
||||
}
|
||||
|
||||
terminalFontChanged(fontFamily, pixelSize, lineSpacing, screenScaling, fontWidth, fallbackFontFamily)
|
||||
}
|
||||
|
||||
onFontSourceChanged: updateFont()
|
||||
onRasterizationChanged: updateFont()
|
||||
onFontNameChanged: updateFont()
|
||||
|
||||
signal terminalFontChanged(string fontFamily, int pixelSize, int lineSpacing, real screenScaling, real fontWidth, string fallbackFontFamily)
|
||||
|
||||
signal initializedSettings
|
||||
|
||||
property Loader fontManager: Loader {
|
||||
states: [
|
||||
State {
|
||||
when: rasterization == no_rasterization
|
||||
PropertyChanges {
|
||||
target: fontManager
|
||||
source: "Fonts.qml"
|
||||
}
|
||||
},
|
||||
State {
|
||||
when: rasterization == scanline_rasterization
|
||||
PropertyChanges {
|
||||
target: fontManager
|
||||
source: "FontScanlines.qml"
|
||||
}
|
||||
},
|
||||
State {
|
||||
when: rasterization == pixel_rasterization
|
||||
PropertyChanges {
|
||||
target: fontManager
|
||||
source: "FontPixels.qml"
|
||||
}
|
||||
},
|
||||
State {
|
||||
when: rasterization == subpixel_rasterization
|
||||
PropertyChanges {
|
||||
target: fontManager
|
||||
source: "FontPixels.qml"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
onLoaded: handleFontChanged()
|
||||
source: "Fonts.qml"
|
||||
onLoaded: updateFont()
|
||||
}
|
||||
|
||||
property FontLoader fontLoader: FontLoader {}
|
||||
property FontLoader fallbackFontLoader: FontLoader {}
|
||||
|
||||
onTotalFontScalingChanged: handleFontChanged()
|
||||
onFontWidthChanged: handleFontChanged()
|
||||
onTotalFontScalingChanged: updateFont()
|
||||
onFontWidthChanged: updateFont()
|
||||
onLineSpacingChanged: updateFont()
|
||||
|
||||
function getIndexByName(name) {
|
||||
for (var i = 0; i < fontlist.count; i++) {
|
||||
@@ -178,44 +230,22 @@ QtObject {
|
||||
return 0 // If the font is not available default to 0.
|
||||
}
|
||||
|
||||
function getFontByName(name) {
|
||||
for (var i = 0; i < fontlist.count; i++) {
|
||||
var font = fontlist.get(i)
|
||||
if (name === font.name) {
|
||||
return font
|
||||
}
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
function incrementScaling() {
|
||||
fontScaling = Math.min(fontScaling + 0.05, maximumFontScaling)
|
||||
handleFontChanged()
|
||||
}
|
||||
|
||||
function decrementScaling() {
|
||||
fontScaling = Math.max(fontScaling - 0.05, minimumFontScaling)
|
||||
handleFontChanged()
|
||||
}
|
||||
|
||||
function handleFontChanged() {
|
||||
if (!fontManager.item)
|
||||
return
|
||||
|
||||
var index = getIndexByName(fontNames[rasterization])
|
||||
if (index === undefined)
|
||||
return
|
||||
|
||||
fontManager.item.selectedFontIndex = index
|
||||
fontManager.item.scaling = totalFontScaling
|
||||
|
||||
var fontSource = fontManager.item.source
|
||||
var pixelSize = fontManager.item.pixelSize
|
||||
var lineSpacing = fontManager.item.lineSpacing
|
||||
var screenScaling = fontManager.item.screenScaling
|
||||
var fontWidth = fontManager.item.defaultFontWidth * appSettings.fontWidth
|
||||
var fontFamily = fontManager.item.family
|
||||
var isSystemFont = fontManager.item.isSystemFont
|
||||
|
||||
lowResolutionFont = fontManager.item.lowResolutionFont
|
||||
|
||||
if (!isSystemFont) {
|
||||
fontLoader.source = fontSource
|
||||
fontFamily = fontLoader.name
|
||||
}
|
||||
|
||||
terminalFontChanged(fontFamily, pixelSize, lineSpacing, screenScaling,
|
||||
fontWidth)
|
||||
}
|
||||
|
||||
property Storage storage: Storage {}
|
||||
@@ -229,7 +259,7 @@ QtObject {
|
||||
|
||||
function composeSettingsString() {
|
||||
var settings = {
|
||||
"fps": fps,
|
||||
"effectsFrameSkip": effectsFrameSkip,
|
||||
"x": x,
|
||||
"y": y,
|
||||
"width": width,
|
||||
@@ -237,12 +267,14 @@ QtObject {
|
||||
"windowScaling": windowScaling,
|
||||
"showTerminalSize": showTerminalSize,
|
||||
"fontScaling": fontScaling,
|
||||
"fontNames": fontNames,
|
||||
"fontName": fontName,
|
||||
"fontSource": fontSource,
|
||||
"showMenubar": showMenubar,
|
||||
"bloomQuality": bloomQuality,
|
||||
"burnInQuality": burnInQuality,
|
||||
"useCustomCommand": useCustomCommand,
|
||||
"customCommand": customCommand
|
||||
"customCommand": customCommand,
|
||||
"lineSpacing": lineSpacing
|
||||
}
|
||||
return stringify(settings)
|
||||
}
|
||||
@@ -267,7 +299,8 @@ QtObject {
|
||||
"contrast": contrast,
|
||||
"ambientLight": ambientLight,
|
||||
"windowOpacity": windowOpacity,
|
||||
"fontName": fontNames[rasterization],
|
||||
"fontName": fontName,
|
||||
"fontSource": fontSource,
|
||||
"fontWidth": fontWidth,
|
||||
"margin": _margin,
|
||||
"blinkingCursor": blinkingCursor,
|
||||
@@ -315,7 +348,7 @@ QtObject {
|
||||
showTerminalSize = settings.showTerminalSize
|
||||
!== undefined ? settings.showTerminalSize : showTerminalSize
|
||||
|
||||
fps = settings.fps !== undefined ? settings.fps : fps
|
||||
effectsFrameSkip = settings.effectsFrameSkip !== undefined ? settings.effectsFrameSkip : effectsFrameSkip
|
||||
windowScaling = settings.windowScaling
|
||||
!== undefined ? settings.windowScaling : windowScaling
|
||||
|
||||
@@ -324,8 +357,9 @@ QtObject {
|
||||
width = settings.width !== undefined ? settings.width : width
|
||||
height = settings.height !== undefined ? settings.height : height
|
||||
|
||||
fontNames = settings.fontNames !== undefined ? settings.fontNames : fontNames
|
||||
fontName = settings.fontName !== undefined ? settings.fontName : fontName
|
||||
fontScaling = settings.fontScaling !== undefined ? settings.fontScaling : fontScaling
|
||||
fontSource = settings.fontSource !== undefined ? settings.fontSource : fontSource
|
||||
|
||||
showMenubar = settings.showMenubar !== undefined ? settings.showMenubar : showMenubar
|
||||
|
||||
@@ -373,16 +407,15 @@ QtObject {
|
||||
windowOpacity = settings.windowOpacity
|
||||
!== undefined ? settings.windowOpacity : windowOpacity
|
||||
|
||||
fontNames[rasterization] = settings.fontName
|
||||
!== undefined ? settings.fontName : fontNames[rasterization]
|
||||
fontName = settings.fontName !== undefined ? settings.fontName : fontName
|
||||
fontSource = settings.fontSource !== undefined ? settings.fontSource : fontSource
|
||||
fontWidth = settings.fontWidth !== undefined ? settings.fontWidth : fontWidth
|
||||
lineSpacing = settings.lineSpacing !== undefined ? settings.lineSpacing : lineSpacing
|
||||
|
||||
_margin = settings.margin !== undefined ? settings.margin : _margin
|
||||
_frameMargin = settings.frameMargin !== undefined ? settings.frameMargin : _frameMargin
|
||||
|
||||
blinkingCursor = settings.blinkingCursor !== undefined ? settings.blinkingCursor : blinkingCursor
|
||||
|
||||
handleFontChanged()
|
||||
}
|
||||
|
||||
function storeCustomProfiles() {
|
||||
@@ -451,7 +484,9 @@ QtObject {
|
||||
"flickering": 0.1,
|
||||
"fontColor": "#ff8100",
|
||||
"fontName": "TERMINUS_SCALED",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.2,
|
||||
"horizontalSync": 0.08,
|
||||
"jitter": 0.1997,
|
||||
@@ -480,6 +515,7 @@ QtObject {
|
||||
"flickering": 0.1,
|
||||
"fontColor": "#0ccc68",
|
||||
"fontName": "TERMINUS_SCALED",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"glowingLine": 0.2,
|
||||
"horizontalSync": 0.08,
|
||||
@@ -509,7 +545,9 @@ QtObject {
|
||||
"flickering": 0.1,
|
||||
"fontColor": "#7cff4f",
|
||||
"fontName": "PRO_FONT_SCALED",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.2,
|
||||
"horizontalSync": 0.151,
|
||||
"jitter": 0.11,
|
||||
@@ -538,7 +576,9 @@ QtObject {
|
||||
"flickering": 0.1962,
|
||||
"fontColor": "#ffffff",
|
||||
"fontName": "COMMODORE_PET",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.2,
|
||||
"horizontalSync": 0.151,
|
||||
"jitter": 0,
|
||||
@@ -567,7 +607,9 @@ QtObject {
|
||||
"flickering": 0.2,
|
||||
"fontColor": "#00d56d",
|
||||
"fontName": "APPLE_II",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.22,
|
||||
"horizontalSync": 0.16,
|
||||
"jitter": 0.1,
|
||||
@@ -596,7 +638,9 @@ QtObject {
|
||||
"flickering": 0.9,
|
||||
"fontColor": "#00ff3e",
|
||||
"fontName": "COMMODORE_PET",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.3,
|
||||
"horizontalSync": 0.42,
|
||||
"jitter": 0.4,
|
||||
@@ -624,8 +668,10 @@ QtObject {
|
||||
"contrast": 0.85,
|
||||
"flickering": 0.0955,
|
||||
"fontColor": "#ffffff",
|
||||
"fontName": "IBM_DOS",
|
||||
"fontName": "IBM_VGA_8x16",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.1545,
|
||||
"horizontalSync": 0,
|
||||
"jitter": 0.1545,
|
||||
@@ -654,7 +700,9 @@ QtObject {
|
||||
"flickering": 0,
|
||||
"fontColor": "#0ccc68",
|
||||
"fontName": "IBM_3278",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0,
|
||||
"horizontalSync": 0,
|
||||
"jitter": 0,
|
||||
@@ -683,7 +731,9 @@ QtObject {
|
||||
"flickering": 0.2,
|
||||
"fontColor": "#729fcf",
|
||||
"fontName": "TERMINUS",
|
||||
"fontSource": 0,
|
||||
"fontWidth": 1,
|
||||
"lineSpacing": 0.1,
|
||||
"glowingLine": 0.1476,
|
||||
"horizontalSync": 0,
|
||||
"jitter": 0.099,
|
||||
|
||||
@@ -102,58 +102,50 @@ Loader {
|
||||
}
|
||||
}
|
||||
|
||||
ShaderLibrary {
|
||||
id: shaderLibrary
|
||||
}
|
||||
|
||||
ShaderEffect {
|
||||
id: burnInShaderEffect
|
||||
|
||||
property variant txt_source: kterminalSource
|
||||
property variant burnInSource: burnInEffectSource
|
||||
property real burnInTime: burnInFadeTime
|
||||
property real lastUpdate: burnInEffect.lastUpdate
|
||||
property real burnInLastUpdate: burnInEffect.lastUpdate
|
||||
property real prevLastUpdate: burnInEffect.prevLastUpdate
|
||||
|
||||
anchors.fill: parent
|
||||
blending: false
|
||||
|
||||
fragmentShader:
|
||||
"#ifdef GL_ES
|
||||
precision mediump float;
|
||||
#endif\n" +
|
||||
// Extra uniforms required by shared block
|
||||
property real qt_Opacity: 1.0
|
||||
property real time: timeManager.time
|
||||
property color fontColor: appSettings.fontColor
|
||||
property color backgroundColor: appSettings.backgroundColor
|
||||
property real shadowLength: 0
|
||||
property size virtualResolution: Qt.size(width, height)
|
||||
property real rasterizationIntensity: 0
|
||||
property int rasterizationMode: 0
|
||||
property real burnIn: appSettings.burnIn
|
||||
property real staticNoise: 0
|
||||
property real screenCurvature: 0
|
||||
property real glowingLine: 0
|
||||
property real chromaColor: 0
|
||||
property size jitterDisplacement: Qt.size(0, 0)
|
||||
property real ambientLight: 0
|
||||
property real jitter: 0
|
||||
property real horizontalSync: 0
|
||||
property real horizontalSyncStrength: 0
|
||||
property real flickering: 0
|
||||
property real displayTerminalFrame: 0
|
||||
property size scaleNoiseSize: Qt.size(0, 0)
|
||||
property real screen_brightness: 1.0
|
||||
property real bloom: 0
|
||||
property real rbgShift: 0
|
||||
property real screenShadowCoeff: 0
|
||||
property real frameShadowCoeff: 0
|
||||
property color frameColor: backgroundColor
|
||||
property size margin: Qt.size(0, 0)
|
||||
|
||||
"uniform lowp float qt_Opacity;" +
|
||||
"uniform lowp sampler2D txt_source;" +
|
||||
|
||||
"varying highp vec2 qt_TexCoord0;
|
||||
|
||||
uniform lowp sampler2D burnInSource;
|
||||
uniform highp float burnInTime;
|
||||
|
||||
uniform highp float lastUpdate;
|
||||
|
||||
uniform highp float prevLastUpdate;" +
|
||||
|
||||
shaderLibrary.rgb2grey +
|
||||
|
||||
"void main() {
|
||||
vec2 coords = qt_TexCoord0;
|
||||
|
||||
vec3 txtColor = texture2D(txt_source, coords).rgb;
|
||||
vec4 accColor = texture2D(burnInSource, coords);
|
||||
|
||||
float prevMask = accColor.a;
|
||||
float currMask = rgb2grey(txtColor);
|
||||
|
||||
highp float blurDecay = clamp((lastUpdate - prevLastUpdate) * burnInTime, 0.0, 1.0);
|
||||
blurDecay = max(0.0, blurDecay - prevMask);
|
||||
vec3 blurColor = accColor.rgb - vec3(blurDecay);
|
||||
vec3 color = max(blurColor, txtColor);
|
||||
|
||||
gl_FragColor = vec4(color, currMask);
|
||||
}
|
||||
"
|
||||
fragmentShader: "qrc:/shaders/burn_in.frag.qsb"
|
||||
vertexShader: "qrc:/shaders/passthrough.vert.qsb"
|
||||
|
||||
onStatusChanged: if (log) console.log(log) //Print warning messages
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*******************************************************************************/
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Dialogs 1.1
|
||||
import QtQuick.Dialogs
|
||||
|
||||
Item {
|
||||
id: rootItem
|
||||
@@ -31,11 +31,13 @@ Item {
|
||||
id: colorDialog
|
||||
title: qsTr("Choose a color")
|
||||
modality: Qt.ApplicationModal
|
||||
visible: false
|
||||
selectedColor: rootItem.color
|
||||
|
||||
//This is a workaround to a Qt 5.2 bug.
|
||||
onColorChanged: if (!appSettings.isMacOS) colorSelected(color)
|
||||
onAccepted: if (appSettings.isMacOS) colorSelected(color)
|
||||
onSelectedColorChanged: {
|
||||
if (!appSettings.isMacOS && visible)
|
||||
colorSelected(selectedColor)
|
||||
}
|
||||
onAccepted: colorSelected(selectedColor)
|
||||
}
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
@@ -57,6 +59,6 @@ Item {
|
||||
}
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: colorDialog.visible = true
|
||||
onClicked: colorDialog.open()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,107 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2013-2021 "Filippo Scognamiglio"
|
||||
* https://github.com/Swordfish90/cool-retro-term
|
||||
*
|
||||
* This file is part of cool-retro-term.
|
||||
*
|
||||
* cool-retro-term is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*******************************************************************************/
|
||||
import QtQuick 2.2
|
||||
|
||||
QtObject {
|
||||
property int selectedFontIndex
|
||||
property real scaling
|
||||
property var _font: fontlist.get(selectedFontIndex)
|
||||
property var source: _font.source
|
||||
property int pixelSize: _font.pixelSize
|
||||
property int lineSpacing: _font.lineSpacing
|
||||
property real screenScaling: scaling * _font.baseScaling
|
||||
property real defaultFontWidth: fontlist.get(selectedFontIndex).fontWidth
|
||||
property bool lowResolutionFont: true
|
||||
|
||||
property ListModel fontlist: ListModel {
|
||||
ListElement {
|
||||
name: "COMMODORE_PET"
|
||||
text: "Commodore PET (1977)"
|
||||
source: "fonts/1977-commodore-pet/PetMe.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_PC"
|
||||
text: "IBM PC (1981)"
|
||||
source: "fonts/1981-ibm-pc/PxPlus_IBM_BIOS.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
ListElement {
|
||||
name: "PROGGY_TINY"
|
||||
text: "Proggy Tiny (Modern)"
|
||||
source: "fonts/modern-proggy-tiny/ProggyTiny.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 16
|
||||
baseScaling: 3.3
|
||||
fontWidth: 0.9
|
||||
}
|
||||
ListElement {
|
||||
name: "TERMINUS_SCALED"
|
||||
text: "Terminus (Modern)"
|
||||
source: "fonts/modern-terminus/TerminusTTF-4.46.0.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
}
|
||||
ListElement {
|
||||
name: "PRO_FONT_SCALED"
|
||||
text: "Pro Font (Modern)"
|
||||
source: "fonts/modern-pro-font-win-tweaked/ProFontWindows.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
}
|
||||
ListElement {
|
||||
name: "APPLE_II"
|
||||
text: "Apple ][ (1977)"
|
||||
source: "fonts/1977-apple2/PrintChar21.ttf"
|
||||
lineSpacing: 2
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.9
|
||||
}
|
||||
ListElement {
|
||||
name: "ATARI_400"
|
||||
text: "Atari 400-800 (1979)"
|
||||
source: "fonts/1979-atari-400-800/AtariClassic-Regular.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
ListElement {
|
||||
name: "COMMODORE_64"
|
||||
text: "Commodore 64 (1982)"
|
||||
source: "fonts/1982-commodore64/C64_Pro_Mono-STYLE.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,107 +0,0 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2013-2021 "Filippo Scognamiglio"
|
||||
* https://github.com/Swordfish90/cool-retro-term
|
||||
*
|
||||
* This file is part of cool-retro-term.
|
||||
*
|
||||
* cool-retro-term is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*******************************************************************************/
|
||||
import QtQuick 2.2
|
||||
|
||||
QtObject {
|
||||
property int selectedFontIndex
|
||||
property real scaling
|
||||
property var _font: fontlist.get(selectedFontIndex)
|
||||
property var source: _font.source
|
||||
property int pixelSize: _font.pixelSize
|
||||
property int lineSpacing: _font.lineSpacing
|
||||
property real screenScaling: scaling * _font.baseScaling
|
||||
property real defaultFontWidth: fontlist.get(selectedFontIndex).fontWidth
|
||||
property bool lowResolutionFont: true
|
||||
|
||||
property ListModel fontlist: ListModel {
|
||||
ListElement {
|
||||
name: "COMMODORE_PET"
|
||||
text: "Commodore PET (1977)"
|
||||
source: "fonts/1977-commodore-pet/PetMe.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_PC"
|
||||
text: "IBM PC (1981)"
|
||||
source: "fonts/1981-ibm-pc/PxPlus_IBM_BIOS.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
ListElement {
|
||||
name: "PROGGY_TINY"
|
||||
text: "Proggy Tiny (Modern)"
|
||||
source: "fonts/modern-proggy-tiny/ProggyTiny.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 16
|
||||
baseScaling: 3.3
|
||||
fontWidth: 0.9
|
||||
}
|
||||
ListElement {
|
||||
name: "TERMINUS_SCALED"
|
||||
text: "Terminus (Modern)"
|
||||
source: "fonts/modern-terminus/TerminusTTF-4.46.0.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
}
|
||||
ListElement {
|
||||
name: "PRO_FONT_SCALED"
|
||||
text: "Pro Font (Modern)"
|
||||
source: "fonts/modern-pro-font-win-tweaked/ProFontWindows.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
}
|
||||
ListElement {
|
||||
name: "APPLE_II"
|
||||
text: "Apple ][ (1977)"
|
||||
source: "fonts/1977-apple2/PrintChar21.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
}
|
||||
ListElement {
|
||||
name: "ATARI_400"
|
||||
text: "Atari 400-800 (1979)"
|
||||
source: "fonts/1979-atari-400-800/AtariClassic-Regular.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
}
|
||||
ListElement {
|
||||
name: "COMMODORE_64"
|
||||
text: "Commodore 64 (1982)"
|
||||
source: "fonts/1982-commodore64/C64_Pro_Mono-STYLE.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2013-2021 "Filippo Scognamiglio"
|
||||
* https://github.com/Swordfish90/cool-retro-term
|
||||
@@ -26,18 +27,35 @@ QtObject {
|
||||
property var _font: fontlist.get(selectedFontIndex)
|
||||
property bool lowResolutionFont: _font.lowResolutionFont
|
||||
|
||||
property int pixelSize: lowResolutionFont ? _font.pixelSize : _font.pixelSize * scaling
|
||||
// Reference height (in pixels) that represents the "normal" on-screen size at scaling=1.0.
|
||||
// Adjust this single value to tune how large fonts appear by default.
|
||||
property int baseFontPixelHeight: 32
|
||||
|
||||
property int lineSpacing: lowResolutionFont ? _font.lineSpacing : pixelSize * _font.lineSpacing
|
||||
// Target pixel height we want on screen for the current zoom level. Low-res fonts will be scaled
|
||||
// up to this height, high-res fonts render directly at this size.
|
||||
property real targetPixelHeight: baseFontPixelHeight * scaling
|
||||
|
||||
property real screenScaling: lowResolutionFont ? _font.baseScaling * scaling : 1.0
|
||||
property int pixelSize: lowResolutionFont ? _font.pixelSize : targetPixelHeight
|
||||
|
||||
property real defaultFontWidth: fontlist.get(selectedFontIndex).fontWidth
|
||||
// Line spacing expressed as a relative factor for all fonts.
|
||||
property real lineSpacingFactor: appSettings.lineSpacing
|
||||
property int lineSpacing: Math.round(targetPixelHeight * lineSpacingFactor)
|
||||
|
||||
property string family: fontlist.get(selectedFontIndex).family
|
||||
// Use total line height (glyph + spacing) for scaling computations on low-res fonts.
|
||||
property real nativeLineHeight: _font.pixelSize + Math.round(
|
||||
_font.pixelSize * lineSpacingFactor)
|
||||
property real targetLineHeight: targetPixelHeight + lineSpacing
|
||||
|
||||
// Scale low-res font textures to hit the target line height; high-res fonts don't need scaling.
|
||||
property real screenScaling: lowResolutionFont ? targetLineHeight / nativeLineHeight : 1.0
|
||||
|
||||
// Uniform default font width (user width scaling still applies).
|
||||
property real defaultFontWidth: 1.0
|
||||
|
||||
property bool isSystemFont: fontlist.get(selectedFontIndex).isSystemFont
|
||||
|
||||
property string family: fontlist.get(selectedFontIndex).family
|
||||
|
||||
// There are two kind of fonts: low resolution and high resolution.
|
||||
// Low resolution font sets the lowResolutionFont property to true.
|
||||
// They are rendered at a fixed pixel size and the texture is upscaled
|
||||
@@ -48,178 +66,166 @@ QtObject {
|
||||
property ListModel fontlist: ListModel {
|
||||
ListElement {
|
||||
name: "TERMINUS_SCALED"
|
||||
text: "Terminus (Modern)"
|
||||
source: "fonts/modern-terminus/TerminusTTF-4.46.0.ttf"
|
||||
lineSpacing: 1
|
||||
text: "Terminus"
|
||||
source: "fonts/terminus/TerminusTTF-4.49.3.ttf"
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "PRO_FONT_SCALED"
|
||||
text: "Pro Font (Modern)"
|
||||
source: "fonts/modern-pro-font-win-tweaked/ProFontWindows.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 12
|
||||
baseScaling: 3.0
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "EXCELSIOR_SCALED"
|
||||
text: "Fixedsys Excelsior (Modern)"
|
||||
source: "fonts/modern-fixedsys-excelsior/FSEX301-L2.ttf"
|
||||
lineSpacing: 0
|
||||
text: "Fixedsys Excelsior"
|
||||
source: "fonts/fixedsys-excelsior/FSEX301-L2.ttf"
|
||||
pixelSize: 16
|
||||
baseScaling: 2.4
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_16_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "GREYBEARD_SCALED"
|
||||
text: "Greybeard"
|
||||
source: "fonts/greybeard/Greybeard-16px.ttf"
|
||||
pixelSize: 16
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
fallbackName: "UNSCII_16_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "COMMODORE_PET_SCALED"
|
||||
text: "Commodore PET (1977)"
|
||||
source: "fonts/1977-commodore-pet/PetMe.ttf"
|
||||
lineSpacing: 3
|
||||
text: "Commodore PET"
|
||||
source: "fonts/pet-me/PetMe.ttf"
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "PROGGY_TINY_SCALED"
|
||||
text: "Proggy Tiny (Modern)"
|
||||
source: "fonts/modern-proggy-tiny/ProggyTiny.ttf"
|
||||
lineSpacing: 1
|
||||
pixelSize: 16
|
||||
baseScaling: 3.3
|
||||
fontWidth: 0.9
|
||||
name: "COZETTE_SCALED"
|
||||
text: "Cozette"
|
||||
source: "fonts/cozette/CozetteVector.ttf"
|
||||
pixelSize: 13
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "UNSCII_8_SCALED"
|
||||
text: "Unscii 8"
|
||||
source: "fonts/unscii/unscii-8.ttf"
|
||||
pixelSize: 8
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "UNSCII_8_THIN_SCALED"
|
||||
text: "Unscii 8 Thin"
|
||||
source: "fonts/unscii/unscii-8-thin.ttf"
|
||||
pixelSize: 8
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "UNSCII_16_SCALED"
|
||||
text: "Unscii 16"
|
||||
source: "fonts/unscii/unscii-16-full.ttf"
|
||||
pixelSize: 16
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
fallbackName: "UNSCII_16_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "APPLE_II_SCALED"
|
||||
text: "Apple ][ (1977)"
|
||||
source: "fonts/1977-apple2/PrintChar21.ttf"
|
||||
lineSpacing: 3
|
||||
text: "Apple ]["
|
||||
source: "fonts/apple2/PrintChar21.ttf"
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "ATARI_400_SCALED"
|
||||
text: "Atari 400-800 (1979)"
|
||||
source: "fonts/1979-atari-400-800/AtariClassic-Regular.ttf"
|
||||
lineSpacing: 3
|
||||
text: "Atari 400-800"
|
||||
source: "fonts/atari-400-800/AtariClassic-Regular.ttf"
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_PC_SCALED"
|
||||
text: "IBM PC (1981)"
|
||||
source: "fonts/1981-ibm-pc/PxPlus_IBM_BIOS.ttf"
|
||||
lineSpacing: 3
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.8
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "COMMODORE_64_SCALED"
|
||||
text: "Commodore 64 (1982)"
|
||||
source: "fonts/1982-commodore64/C64_Pro_Mono-STYLE.ttf"
|
||||
lineSpacing: 3
|
||||
text: "Commodore 64"
|
||||
source: "fonts/pet-me/PetMe64.ttf"
|
||||
pixelSize: 8
|
||||
baseScaling: 3.5
|
||||
fontWidth: 0.7
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_DOS"
|
||||
text: "IBM DOS (1985)"
|
||||
source: "fonts/1985-ibm-pc-vga/PxPlus_IBM_VGA8.ttf"
|
||||
lineSpacing: 3
|
||||
name: "IBM_EGA_8x8"
|
||||
text: "IBM EGA 8x8"
|
||||
source: "fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf"
|
||||
pixelSize: 8
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
fallbackName: "UNSCII_8_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_VGA_8x16"
|
||||
text: "IBM VGA 8x16"
|
||||
source: "fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf"
|
||||
pixelSize: 16
|
||||
baseScaling: 2.0
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: true
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "HERMIT"
|
||||
text: "HD: Hermit (Modern)"
|
||||
source: "fonts/modern-hermit/Hermit-medium.otf"
|
||||
lineSpacing: 0.05
|
||||
pixelSize: 27
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
fallbackName: "UNSCII_16_SCALED"
|
||||
}
|
||||
ListElement {
|
||||
name: "TERMINUS"
|
||||
text: "HD: Terminus (Modern)"
|
||||
source: "fonts/modern-terminus/TerminusTTF-4.46.0.ttf"
|
||||
lineSpacing: 0.1
|
||||
text: "Terminus"
|
||||
source: "fonts/terminus/TerminusTTF-4.49.3.ttf"
|
||||
pixelSize: 35
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "PRO_FONT"
|
||||
text: "HD: Pro Font (Modern)"
|
||||
source: "fonts/modern-pro-font-win-tweaked/ProFontWindows.ttf"
|
||||
lineSpacing: 0.1
|
||||
name: "HACK"
|
||||
text: "Hack"
|
||||
source: "fonts/hack/Hack-Regular.ttf"
|
||||
pixelSize: 35
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "INCONSOLATA"
|
||||
text: "HD: Inconsolata (Modern)"
|
||||
source: "fonts/modern-inconsolata/Inconsolata.otf"
|
||||
lineSpacing: 0.1
|
||||
name: "FIRA_CODE"
|
||||
text: "Fira Code"
|
||||
source: "fonts/fira-code/FiraCode-Medium.ttf"
|
||||
pixelSize: 35
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
}
|
||||
ListElement {
|
||||
name: "IOSEVKA"
|
||||
text: "Iosevka"
|
||||
source: "fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf"
|
||||
pixelSize: 35
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
}
|
||||
ListElement {
|
||||
name: "JETBRAINS_MONO"
|
||||
text: "JetBrains Mono"
|
||||
source: "fonts/jetbrains-mono/JetBrainsMono-Medium.ttf"
|
||||
pixelSize: 35
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
ListElement {
|
||||
name: "IBM_3278"
|
||||
text: "HD: IBM 3278 (1971)"
|
||||
source: "fonts/1971-ibm-3278/3270-Regular.ttf"
|
||||
lineSpacing: 0.2
|
||||
text: "IBM 3278"
|
||||
source: "fonts/ibm-3278/3270-Regular.ttf"
|
||||
pixelSize: 32
|
||||
fontWidth: 1.0
|
||||
lowResolutionFont: false
|
||||
isSystemFont: false
|
||||
family: ""
|
||||
}
|
||||
}
|
||||
|
||||
@@ -233,16 +239,15 @@ QtObject {
|
||||
}
|
||||
fontlist.append(convertToListElement(families[i]))
|
||||
}
|
||||
appSettings.updateFont()
|
||||
}
|
||||
|
||||
function convertToListElement(family) {
|
||||
return {
|
||||
"name": "System: " + family,
|
||||
"text": qsTr("System: ") + family,
|
||||
"name": family,
|
||||
"text": family,
|
||||
"source": "",
|
||||
"lineSpacing": 0.1,
|
||||
"pixelSize": 30,
|
||||
"fontWidth": 1.0,
|
||||
"baseScaling": 1.0,
|
||||
"lowResolutionFont": false,
|
||||
"isSystemFont": true,
|
||||
|
||||
@@ -21,7 +21,7 @@ import QtQuick 2.2
|
||||
import QtQuick.Window 2.0
|
||||
import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.1
|
||||
import QtQuick.Dialogs
|
||||
|
||||
Window {
|
||||
id: insertnamedialog
|
||||
|
||||
@@ -145,16 +145,26 @@ Item{
|
||||
}
|
||||
}
|
||||
|
||||
function handleFontChanged(fontFamily, pixelSize, lineSpacing, screenScaling, fontWidth) {
|
||||
function handleFontChanged(fontFamily, pixelSize, lineSpacing, screenScaling, fontWidth, fallbackFontFamily) {
|
||||
kterminal.antialiasText = !appSettings.lowResolutionFont;
|
||||
font.pixelSize = pixelSize;
|
||||
font.family = fontFamily;
|
||||
var updatedFont = Qt.font({
|
||||
family: fontFamily,
|
||||
pixelSize: pixelSize
|
||||
});
|
||||
kterminal.font = updatedFont;
|
||||
|
||||
terminalContainer.fontWidth = fontWidth;
|
||||
terminalContainer.screenScaling = screenScaling;
|
||||
scaleTexture = Math.max(1.0, Math.floor(screenScaling * appSettings.windowScaling));
|
||||
|
||||
kterminal.lineSpacing = lineSpacing;
|
||||
|
||||
var fallbackChain = [];
|
||||
if (fallbackFontFamily && fallbackFontFamily.length > 0) {
|
||||
fallbackChain.push(fallbackFontFamily);
|
||||
}
|
||||
fallbackChain.push(appSettings.isMacOS ? "Menlo" : "Monospace");
|
||||
monospaceFontManager.setFontSubstitutions(fontFamily, fallbackChain);
|
||||
}
|
||||
|
||||
function startSession() {
|
||||
@@ -182,7 +192,7 @@ Item{
|
||||
Component.onCompleted: {
|
||||
appSettings.terminalFontChanged.connect(handleFontChanged);
|
||||
appSettings.initializedSettings.connect(startSession);
|
||||
appSettings.handleFontChanged()
|
||||
appSettings.updateFont()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -208,31 +218,31 @@ Item{
|
||||
acceptedButtons: Qt.LeftButton | Qt.MiddleButton | Qt.RightButton
|
||||
anchors.fill: parent
|
||||
cursorShape: kterminal.terminalUsesMouse ? Qt.ArrowCursor : Qt.IBeamCursor
|
||||
onWheel:{
|
||||
if(wheel.modifiers & Qt.ControlModifier){
|
||||
onWheel: function(wheel) {
|
||||
if (wheel.modifiers & Qt.ControlModifier) {
|
||||
wheel.angleDelta.y > 0 ? zoomIn.trigger() : zoomOut.trigger();
|
||||
} else {
|
||||
var coord = correctDistortion(wheel.x, wheel.y);
|
||||
kterminal.simulateWheel(coord.x, coord.y, wheel.buttons, wheel.modifiers, wheel.angleDelta);
|
||||
}
|
||||
}
|
||||
onDoubleClicked: {
|
||||
onDoubleClicked: function(mouse) {
|
||||
var coord = correctDistortion(mouse.x, mouse.y);
|
||||
kterminal.simulateMouseDoubleClick(coord.x, coord.y, mouse.button, mouse.buttons, mouse.modifiers);
|
||||
}
|
||||
onPressed: {
|
||||
if((!kterminal.terminalUsesMouse || mouse.modifiers & Qt.ShiftModifier) && mouse.button == Qt.RightButton) {
|
||||
onPressed: function(mouse) {
|
||||
if ((!kterminal.terminalUsesMouse || mouse.modifiers & Qt.ShiftModifier) && mouse.button == Qt.RightButton) {
|
||||
contextmenu.popup();
|
||||
} else {
|
||||
var coord = correctDistortion(mouse.x, mouse.y);
|
||||
kterminal.simulateMousePress(coord.x, coord.y, mouse.button, mouse.buttons, mouse.modifiers)
|
||||
}
|
||||
}
|
||||
onReleased: {
|
||||
onReleased: function(mouse) {
|
||||
var coord = correctDistortion(mouse.x, mouse.y);
|
||||
kterminal.simulateMouseRelease(coord.x, coord.y, mouse.button, mouse.buttons, mouse.modifiers);
|
||||
}
|
||||
onPositionChanged: {
|
||||
onPositionChanged: function(mouse) {
|
||||
var coord = correctDistortion(mouse.x, mouse.y);
|
||||
kterminal.simulateMouseMove(coord.x, coord.y, mouse.button, mouse.buttons, mouse.modifiers);
|
||||
}
|
||||
|
||||
@@ -27,7 +27,9 @@ import "Components"
|
||||
ColumnLayout {
|
||||
GroupBox {
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
title: qsTr("Command")
|
||||
padding: appSettings.defaultMargin
|
||||
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
@@ -60,9 +62,32 @@ ColumnLayout {
|
||||
}
|
||||
}
|
||||
|
||||
GroupBox {
|
||||
title: qsTr("Cursor")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
CheckBox {
|
||||
id: blinkingCursor
|
||||
text: qsTr("Blinking Cursor")
|
||||
checked: appSettings.blinkingCursor
|
||||
onCheckedChanged: appSettings.blinkingCursor = checked
|
||||
}
|
||||
Binding {
|
||||
target: blinkingCursor
|
||||
property: "checked"
|
||||
value: appSettings.blinkingCursor
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GroupBox {
|
||||
title: qsTr("Performance")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
GridLayout {
|
||||
anchors.fill: parent
|
||||
columns: 4
|
||||
@@ -73,24 +98,17 @@ ColumnLayout {
|
||||
Slider {
|
||||
Layout.fillWidth: true
|
||||
Layout.columnSpan: 2
|
||||
id: fpsSlider
|
||||
onValueChanged: {
|
||||
if (enabled) {
|
||||
appSettings.fps = value !== 60 ? value + 1 : 0
|
||||
}
|
||||
}
|
||||
id: effectsFpsSlider
|
||||
onValueChanged: appSettings.effectsFrameSkip = Math.round(value)
|
||||
stepSize: 1
|
||||
enabled: false
|
||||
Component.onCompleted: {
|
||||
from = 0
|
||||
to = 60
|
||||
value = appSettings.fps !== 0 ? appSettings.fps - 1 : 60
|
||||
enabled = true
|
||||
}
|
||||
enabled: true
|
||||
from: 5
|
||||
to: 1
|
||||
value: appSettings.effectsFrameSkip
|
||||
}
|
||||
|
||||
SizedLabel {
|
||||
text: appSettings.fps !== 0 ? appSettings.fps : qsTr("Max")
|
||||
text: Math.round(100 / Math.max(1, Math.round(effectsFpsSlider.value))) + "%"
|
||||
}
|
||||
Label {
|
||||
text: qsTr("Texture Quality")
|
||||
@@ -99,15 +117,11 @@ ColumnLayout {
|
||||
id: txtslider
|
||||
Layout.fillWidth: true
|
||||
Layout.columnSpan: 2
|
||||
onValueChanged: if (enabled)
|
||||
appSettings.windowScaling = value
|
||||
onValueChanged: appSettings.windowScaling = value
|
||||
stepSize: 0.05
|
||||
enabled: false
|
||||
Component.onCompleted: {
|
||||
from = 0.25 //Without this value gets set to 0.5
|
||||
value = appSettings.windowScaling
|
||||
enabled = true
|
||||
}
|
||||
enabled: true
|
||||
from: 0.25
|
||||
value: appSettings.windowScaling
|
||||
}
|
||||
SizedLabel {
|
||||
text: Math.round(txtslider.value * 100) + "%"
|
||||
@@ -120,15 +134,11 @@ ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
Layout.columnSpan: 2
|
||||
id: bloomSlider
|
||||
onValueChanged: if (enabled)
|
||||
appSettings.bloomQuality = value
|
||||
onValueChanged: appSettings.bloomQuality = value
|
||||
stepSize: 0.05
|
||||
enabled: false
|
||||
Component.onCompleted: {
|
||||
from = 0.25
|
||||
value = appSettings.bloomQuality
|
||||
enabled = true
|
||||
}
|
||||
enabled: true
|
||||
from: 0.25
|
||||
value: appSettings.bloomQuality
|
||||
}
|
||||
SizedLabel {
|
||||
text: Math.round(bloomSlider.value * 100) + "%"
|
||||
@@ -141,15 +151,11 @@ ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
id: burnInSlider
|
||||
Layout.columnSpan: 2
|
||||
onValueChanged: if (enabled)
|
||||
appSettings.burnInQuality = value
|
||||
onValueChanged: appSettings.burnInQuality = value
|
||||
stepSize: 0.05
|
||||
enabled: false
|
||||
Component.onCompleted: {
|
||||
from = 0.25
|
||||
value = appSettings.burnInQuality
|
||||
enabled = true
|
||||
}
|
||||
enabled: true
|
||||
from: 0.25
|
||||
value: appSettings.burnInQuality
|
||||
}
|
||||
SizedLabel {
|
||||
text: Math.round(burnInSlider.value * 100) + "%"
|
||||
|
||||
@@ -22,64 +22,68 @@ import QtQuick.Controls 2.0
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
spacing: 2
|
||||
|
||||
GroupBox {
|
||||
title: qsTr("Effects")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
|
||||
CheckableSlider {
|
||||
name: qsTr("Bloom")
|
||||
onNewValue: appSettings.bloom = newValue
|
||||
onNewValue: function(newValue) { appSettings.bloom = newValue }
|
||||
value: appSettings.bloom
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("BurnIn")
|
||||
onNewValue: appSettings.burnIn = newValue
|
||||
onNewValue: function(newValue) { appSettings.burnIn = newValue }
|
||||
value: appSettings.burnIn
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Static Noise")
|
||||
onNewValue: appSettings.staticNoise = newValue
|
||||
onNewValue: function(newValue) { appSettings.staticNoise = newValue }
|
||||
value: appSettings.staticNoise
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Jitter")
|
||||
onNewValue: appSettings.jitter = newValue
|
||||
onNewValue: function(newValue) { appSettings.jitter = newValue }
|
||||
value: appSettings.jitter
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Glow Line")
|
||||
onNewValue: appSettings.glowingLine = newValue
|
||||
onNewValue: function(newValue) { appSettings.glowingLine = newValue }
|
||||
value: appSettings.glowingLine
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Screen Curvature")
|
||||
onNewValue: appSettings.screenCurvature = newValue
|
||||
onNewValue: function(newValue) { appSettings.screenCurvature = newValue }
|
||||
value: appSettings.screenCurvature
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Ambient Light")
|
||||
onNewValue: appSettings.ambientLight = newValue
|
||||
onNewValue: function(newValue) { appSettings.ambientLight = newValue }
|
||||
value: appSettings.ambientLight
|
||||
enabled: appSettings.framesIndex !== 0
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Flickering")
|
||||
onNewValue: appSettings.flickering = newValue
|
||||
onNewValue: function(newValue) { appSettings.flickering = newValue }
|
||||
value: appSettings.flickering
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Horizontal Sync")
|
||||
onNewValue: appSettings.horizontalSync = newValue
|
||||
onNewValue: function(newValue) { appSettings.horizontalSync = newValue }
|
||||
value: appSettings.horizontalSync
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("RGB Shift")
|
||||
onNewValue: appSettings.rbgShift = newValue
|
||||
onNewValue: function(newValue) { appSettings.rbgShift = newValue }
|
||||
value: appSettings.rbgShift
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,12 +20,14 @@
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Controls 2.4
|
||||
import QtQuick.Layouts 1.1
|
||||
import QtQuick.Dialogs 1.1
|
||||
import QtQuick.Dialogs
|
||||
|
||||
ColumnLayout {
|
||||
GroupBox {
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
title: qsTr("Profile")
|
||||
padding: appSettings.defaultMargin
|
||||
RowLayout {
|
||||
anchors.fill: parent
|
||||
ListView {
|
||||
@@ -183,6 +185,8 @@ ColumnLayout {
|
||||
GroupBox {
|
||||
title: qsTr("Screen")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
GridLayout {
|
||||
anchors.fill: parent
|
||||
columns: 2
|
||||
@@ -237,6 +241,7 @@ ColumnLayout {
|
||||
MessageDialog {
|
||||
id: messageDialog
|
||||
title: qsTr("File Error")
|
||||
buttons: MessageDialog.Ok
|
||||
onAccepted: {
|
||||
messageDialog.close()
|
||||
}
|
||||
@@ -248,10 +253,8 @@ ColumnLayout {
|
||||
|
||||
sourceComponent: FileDialog {
|
||||
nameFilters: ["Json files (*.json)"]
|
||||
selectMultiple: false
|
||||
selectFolder: false
|
||||
selectExisting: fileDialog.selectExisting
|
||||
onAccepted: callBack(fileUrl)
|
||||
fileMode: fileDialog.selectExisting ? FileDialog.OpenFile : FileDialog.SaveFile
|
||||
onAccepted: callBack(selectedFile)
|
||||
}
|
||||
|
||||
onSelectExistingChanged: reload()
|
||||
|
||||
@@ -25,27 +25,50 @@ import QtQml 2.0
|
||||
import "Components"
|
||||
|
||||
ColumnLayout {
|
||||
|
||||
GroupBox {
|
||||
title: qsTr("Font")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
GridLayout {
|
||||
anchors.fill: parent
|
||||
columns: 2
|
||||
Label {
|
||||
text: qsTr("Rasterization")
|
||||
text: qsTr("Source")
|
||||
}
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
RadioButton {
|
||||
text: qsTr("Bundled")
|
||||
checked: appSettings.fontSource === appSettings.bundled_fonts
|
||||
onClicked: {
|
||||
appSettings.fontSource = appSettings.bundled_fonts
|
||||
}
|
||||
}
|
||||
RadioButton {
|
||||
text: qsTr("System")
|
||||
checked: appSettings.fontSource === appSettings.system_fonts
|
||||
onClicked: {
|
||||
appSettings.fontSource = appSettings.system_fonts
|
||||
}
|
||||
}
|
||||
}
|
||||
Label {
|
||||
text: qsTr("Rendering")
|
||||
enabled: appSettings.fontSource === appSettings.bundled_fonts
|
||||
}
|
||||
ComboBox {
|
||||
id: rasterizationBox
|
||||
id: renderingBox
|
||||
|
||||
property string selectedElement: model[currentIndex]
|
||||
|
||||
Layout.fillWidth: true
|
||||
model: [qsTr("Default"), qsTr("Scanlines"), qsTr("Pixels"), qsTr("Sub-Pixels")]
|
||||
model: [qsTr("Default"), qsTr("Scanlines"), qsTr("Pixels"), qsTr("Sub-Pixels"), qsTr("Modern")]
|
||||
currentIndex: appSettings.rasterization
|
||||
onCurrentIndexChanged: {
|
||||
appSettings.rasterization = currentIndex
|
||||
}
|
||||
enabled: appSettings.fontSource === appSettings.bundled_fonts
|
||||
}
|
||||
Label {
|
||||
text: qsTr("Name")
|
||||
@@ -53,18 +76,32 @@ ColumnLayout {
|
||||
ComboBox {
|
||||
id: fontChanger
|
||||
Layout.fillWidth: true
|
||||
model: appSettings.fontlist
|
||||
model: appSettings.filteredFontList
|
||||
textRole: "text"
|
||||
onActivated: {
|
||||
var name = appSettings.fontlist.get(index).name
|
||||
appSettings.fontNames[appSettings.rasterization] = name
|
||||
appSettings.handleFontChanged()
|
||||
var font = appSettings.filteredFontList.get(index)
|
||||
|
||||
// If selecting a high-res font while not in Modern mode,
|
||||
// switch to Modern to render at full resolution.
|
||||
if (!font.lowResolutionFont && appSettings.rasterization !== appSettings.modern_rasterization) {
|
||||
appSettings.rasterization = appSettings.modern_rasterization
|
||||
}
|
||||
// If selecting a low-res font while in Modern mode, switch back to default.
|
||||
if (font.lowResolutionFont && appSettings.rasterization === appSettings.modern_rasterization) {
|
||||
appSettings.rasterization = appSettings.no_rasterization
|
||||
}
|
||||
|
||||
appSettings.fontName = font.name
|
||||
}
|
||||
function updateIndex() {
|
||||
var name = appSettings.fontNames[appSettings.rasterization]
|
||||
var index = appSettings.getIndexByName(name)
|
||||
if (index !== undefined)
|
||||
currentIndex = index
|
||||
for (var i = 0; i < appSettings.filteredFontList.count; i++) {
|
||||
var font = appSettings.filteredFontList.get(i)
|
||||
if (font.name === appSettings.fontName) {
|
||||
currentIndex = i
|
||||
return
|
||||
}
|
||||
}
|
||||
currentIndex = 0
|
||||
}
|
||||
Connections {
|
||||
target: appSettings
|
||||
@@ -72,6 +109,10 @@ ColumnLayout {
|
||||
onTerminalFontChanged: {
|
||||
fontChanger.updateIndex()
|
||||
}
|
||||
|
||||
onFilteredFontListChanged: {
|
||||
fontChanger.updateIndex()
|
||||
}
|
||||
}
|
||||
Component.onCompleted: updateIndex()
|
||||
}
|
||||
@@ -111,41 +152,43 @@ ColumnLayout {
|
||||
text: Math.round(widthChanger.value * 100) + "%"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
GroupBox {
|
||||
title: qsTr("Cursor")
|
||||
Layout.fillWidth: true
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
CheckBox {
|
||||
id: blinkingCursor
|
||||
text: qsTr("Blinking Cursor")
|
||||
checked: appSettings.blinkingCursor
|
||||
onCheckedChanged: appSettings.blinkingCursor = checked
|
||||
Label {
|
||||
text: qsTr("Line Spacing")
|
||||
}
|
||||
Binding {
|
||||
target: blinkingCursor
|
||||
property: "checked"
|
||||
value: appSettings.blinkingCursor
|
||||
RowLayout {
|
||||
Layout.fillWidth: true
|
||||
Slider {
|
||||
Layout.fillWidth: true
|
||||
id: lineSpacingChanger
|
||||
onValueChanged: appSettings.lineSpacing = value
|
||||
value: appSettings.lineSpacing
|
||||
stepSize: 0.01
|
||||
from: 0.0
|
||||
to: 1.0
|
||||
}
|
||||
SizedLabel {
|
||||
text: Math.round(lineSpacingChanger.value * 100) + "%"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
GroupBox {
|
||||
title: qsTr("Colors")
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
padding: appSettings.defaultMargin
|
||||
ColumnLayout {
|
||||
anchors.fill: parent
|
||||
ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
CheckableSlider {
|
||||
name: qsTr("Chroma Color")
|
||||
onNewValue: appSettings.chromaColor = newValue
|
||||
onNewValue: function(newValue) { appSettings.chromaColor = newValue }
|
||||
value: appSettings.chromaColor
|
||||
}
|
||||
CheckableSlider {
|
||||
name: qsTr("Saturation Color")
|
||||
onNewValue: appSettings.saturationColor = newValue
|
||||
onNewValue: function(newValue) { appSettings.saturationColor = newValue }
|
||||
value: appSettings.saturationColor
|
||||
enabled: appSettings.chromaColor !== 0
|
||||
}
|
||||
|
||||
@@ -22,18 +22,16 @@ import QtQuick 2.2
|
||||
import QtQuick.Controls 2.1
|
||||
import QtQuick.Window 2.1
|
||||
import QtQuick.Layouts 1.3
|
||||
import QtQuick.Dialogs 1.1
|
||||
import QtQuick.Dialogs
|
||||
|
||||
Window {
|
||||
ApplicationWindow {
|
||||
id: settings_window
|
||||
title: qsTr("Settings")
|
||||
width: 640
|
||||
height: 640
|
||||
|
||||
property int tabmargins: 15
|
||||
height: 480
|
||||
|
||||
Item {
|
||||
anchors { fill: parent; margins: tabmargins }
|
||||
anchors { fill: parent; }
|
||||
|
||||
TabBar {
|
||||
id: bar
|
||||
@@ -52,24 +50,21 @@ Window {
|
||||
}
|
||||
}
|
||||
|
||||
Frame {
|
||||
StackLayout {
|
||||
anchors {
|
||||
top: bar.bottom
|
||||
left: parent.left
|
||||
right: parent.right
|
||||
bottom: parent.bottom
|
||||
margins: 16
|
||||
}
|
||||
|
||||
StackLayout {
|
||||
anchors.fill: parent
|
||||
currentIndex: bar.currentIndex
|
||||
|
||||
currentIndex: bar.currentIndex
|
||||
|
||||
SettingsGeneralTab { }
|
||||
SettingsTerminalTab { }
|
||||
SettingsEffectsTab { }
|
||||
SettingsAdvancedTab { }
|
||||
}
|
||||
SettingsGeneralTab { }
|
||||
SettingsTerminalTab { }
|
||||
SettingsEffectsTab { }
|
||||
SettingsAdvancedTab { }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,8 @@ import QtQuick 2.0
|
||||
|
||||
QtObject {
|
||||
property string rasterizationShader:
|
||||
(appSettings.rasterization === appSettings.no_rasterization ? "
|
||||
((appSettings.rasterization === appSettings.no_rasterization) ||
|
||||
(appSettings.rasterization === appSettings.modern_rasterization) ? "
|
||||
lowp vec3 applyRasterization(vec2 screenCoords, lowp vec3 texel, vec2 virtualResolution, float intensity) {
|
||||
return texel;
|
||||
}" : "") +
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
*******************************************************************************/
|
||||
|
||||
import QtQuick 2.2
|
||||
import QtGraphicalEffects 1.0
|
||||
|
||||
import "utils.js" as Utils
|
||||
|
||||
@@ -45,469 +44,174 @@ Item {
|
||||
screenResolution.height / virtualResolution.height
|
||||
)
|
||||
|
||||
ShaderEffect {
|
||||
id: dynamicShader
|
||||
|
||||
property ShaderLibrary shaderLibrary: ShaderLibrary { }
|
||||
|
||||
property ShaderEffectSource screenBuffer: frameBuffer
|
||||
property ShaderEffectSource burnInSource: burnInEffect.source
|
||||
property ShaderEffectSource frameSource: terminalFrameLoader.item
|
||||
|
||||
property color fontColor: parent.fontColor
|
||||
property color backgroundColor: parent.backgroundColor
|
||||
property real screenCurvature: parent.screenCurvature
|
||||
property real chromaColor: parent.chromaColor
|
||||
property real ambientLight: parent.ambientLight
|
||||
|
||||
property real flickering: appSettings.flickering
|
||||
property real horizontalSync: appSettings.horizontalSync
|
||||
property real horizontalSyncStrength: Utils.lint(0.05, 0.35, horizontalSync)
|
||||
property real glowingLine: appSettings.glowingLine * 0.2
|
||||
|
||||
// Fast burnin properties
|
||||
property real burnIn: appSettings.burnIn
|
||||
property real burnInLastUpdate: burnInEffect.lastUpdate
|
||||
property real burnInTime: burnInEffect.burnInFadeTime
|
||||
|
||||
property real jitter: appSettings.jitter
|
||||
property size jitterDisplacement: Qt.size(0.007 * jitter, 0.002 * jitter)
|
||||
property real shadowLength: 0.25 * screenCurvature * Utils.lint(0.50, 1.5, ambientLight)
|
||||
property real staticNoise: appSettings.staticNoise
|
||||
property size scaleNoiseSize: Qt.size((width * 0.75) / (noiseTexture.width * appSettings.windowScaling * appSettings.totalFontScaling),
|
||||
(height * 0.75) / (noiseTexture.height * appSettings.windowScaling * appSettings.totalFontScaling))
|
||||
|
||||
property size virtualResolution: parent.virtualResolution
|
||||
|
||||
// Rasterization might display oversamping issues if virtual resolution is close to physical display resolution.
|
||||
// We progressively disable rasterization from 4x up to 2x resolution.
|
||||
property real rasterizationIntensity: Utils.smoothstep(2.0, 4.0, _screenDensity)
|
||||
|
||||
property real displayTerminalFrame: appSettings._frameMargin > 0 || appSettings.screenCurvature > 0
|
||||
|
||||
property real time: timeManager.time
|
||||
property ShaderEffectSource noiseSource: noiseShaderSource
|
||||
|
||||
// If something goes wrong activate the fallback version of the shader.
|
||||
property bool fallBack: false
|
||||
|
||||
anchors.fill: parent
|
||||
blending: false
|
||||
|
||||
//Smooth random texture used for flickering effect.
|
||||
Image {
|
||||
id: noiseTexture
|
||||
source: "images/allNoise512.png"
|
||||
width: 512
|
||||
height: 512
|
||||
fillMode: Image.Tile
|
||||
visible: false
|
||||
}
|
||||
ShaderEffectSource {
|
||||
id: noiseShaderSource
|
||||
sourceItem: noiseTexture
|
||||
wrapMode: ShaderEffectSource.Repeat
|
||||
visible: false
|
||||
smooth: true
|
||||
}
|
||||
|
||||
//Print the number with a reasonable precision for the shader.
|
||||
function str(num){
|
||||
return num.toFixed(8);
|
||||
}
|
||||
|
||||
vertexShader: "
|
||||
uniform highp mat4 qt_Matrix;
|
||||
uniform highp float time;
|
||||
|
||||
attribute highp vec4 qt_Vertex;
|
||||
attribute highp vec2 qt_MultiTexCoord0;
|
||||
|
||||
varying highp vec2 qt_TexCoord0;" +
|
||||
|
||||
(!fallBack ? "
|
||||
uniform sampler2D noiseSource;" : "") +
|
||||
|
||||
(!fallBack && flickering !== 0.0 ?"
|
||||
varying lowp float brightness;
|
||||
uniform lowp float flickering;" : "") +
|
||||
|
||||
(!fallBack && horizontalSync !== 0.0 ?"
|
||||
uniform lowp float horizontalSyncStrength;
|
||||
varying lowp float distortionScale;
|
||||
varying lowp float distortionFreq;" : "") +
|
||||
|
||||
"
|
||||
void main() {
|
||||
qt_TexCoord0 = qt_MultiTexCoord0;
|
||||
vec2 coords = vec2(fract(time/(1024.0*2.0)), fract(time/(1024.0*1024.0)));" +
|
||||
|
||||
(!fallBack && (flickering !== 0.0 || horizontalSync !== 0.0) ?
|
||||
"vec4 initialNoiseTexel = texture2D(noiseSource, coords);"
|
||||
: "") +
|
||||
|
||||
(!fallBack && flickering !== 0.0 ? "
|
||||
brightness = 1.0 + (initialNoiseTexel.g - 0.5) * flickering;"
|
||||
: "") +
|
||||
|
||||
(!fallBack && horizontalSync !== 0.0 ? "
|
||||
float randval = horizontalSyncStrength - initialNoiseTexel.r;
|
||||
distortionScale = step(0.0, randval) * randval * horizontalSyncStrength;
|
||||
distortionFreq = mix(4.0, 40.0, initialNoiseTexel.g);"
|
||||
: "") +
|
||||
|
||||
"gl_Position = qt_Matrix * qt_Vertex;
|
||||
}"
|
||||
|
||||
fragmentShader: "
|
||||
#ifdef GL_ES
|
||||
precision mediump float;
|
||||
#endif
|
||||
|
||||
uniform sampler2D screenBuffer;
|
||||
uniform highp float qt_Opacity;
|
||||
uniform highp float time;
|
||||
varying highp vec2 qt_TexCoord0;
|
||||
|
||||
uniform highp vec4 fontColor;
|
||||
uniform highp vec4 backgroundColor;
|
||||
uniform lowp float shadowLength;
|
||||
|
||||
uniform highp vec2 virtualResolution;
|
||||
uniform lowp float rasterizationIntensity;\n" +
|
||||
|
||||
(burnIn !== 0 ? "
|
||||
uniform sampler2D burnInSource;
|
||||
uniform highp float burnInLastUpdate;
|
||||
uniform highp float burnInTime;" : "") +
|
||||
(staticNoise !== 0 ? "
|
||||
uniform highp float staticNoise;" : "") +
|
||||
(((staticNoise !== 0 || jitter !== 0) ||(fallBack && (flickering || horizontalSync))) ? "
|
||||
uniform lowp sampler2D noiseSource;
|
||||
uniform highp vec2 scaleNoiseSize;" : "") +
|
||||
(displayTerminalFrame ? "
|
||||
uniform lowp sampler2D frameSource;" : "") +
|
||||
(screenCurvature !== 0 ? "
|
||||
uniform highp float screenCurvature;" : "") +
|
||||
(glowingLine !== 0 ? "
|
||||
uniform highp float glowingLine;" : "") +
|
||||
(chromaColor !== 0 ? "
|
||||
uniform lowp float chromaColor;" : "") +
|
||||
(jitter !== 0 ? "
|
||||
uniform lowp vec2 jitterDisplacement;" : "") +
|
||||
(ambientLight !== 0 ? "
|
||||
uniform lowp float ambientLight;" : "") +
|
||||
|
||||
(fallBack && horizontalSync !== 0 ? "
|
||||
uniform lowp float horizontalSyncStrength;" : "") +
|
||||
(fallBack && flickering !== 0.0 ?"
|
||||
uniform lowp float flickering;" : "") +
|
||||
(!fallBack && flickering !== 0 ? "
|
||||
varying lowp float brightness;"
|
||||
: "") +
|
||||
(!fallBack && horizontalSync !== 0 ? "
|
||||
varying lowp float distortionScale;
|
||||
varying lowp float distortionFreq;" : "") +
|
||||
|
||||
(glowingLine !== 0 ? "
|
||||
float randomPass(vec2 coords){
|
||||
return fract(smoothstep(-120.0, 0.0, coords.y - (virtualResolution.y + 120.0) * fract(time * 0.00015)));
|
||||
}" : "") +
|
||||
|
||||
shaderLibrary.min2 +
|
||||
shaderLibrary.rgb2grey +
|
||||
shaderLibrary.rasterizationShader +
|
||||
|
||||
"
|
||||
float isInScreen(vec2 v) {
|
||||
return min2(step(0.0, v) - step(1.0, v));
|
||||
}
|
||||
|
||||
vec2 barrel(vec2 v, vec2 cc) {" +
|
||||
|
||||
(screenCurvature !== 0 ? "
|
||||
float distortion = dot(cc, cc) * screenCurvature;
|
||||
return (v - cc * (1.0 + distortion) * distortion);"
|
||||
:
|
||||
"return v;") +
|
||||
"}" +
|
||||
|
||||
"vec3 convertWithChroma(vec3 inColor) {
|
||||
vec3 outColor = inColor;" +
|
||||
|
||||
(chromaColor !== 0 ?
|
||||
"outColor = fontColor.rgb * mix(vec3(rgb2grey(inColor)), inColor, chromaColor);"
|
||||
:
|
||||
"outColor = fontColor.rgb * rgb2grey(inColor);") +
|
||||
|
||||
" return outColor;
|
||||
}" +
|
||||
|
||||
"void main() {" +
|
||||
"vec2 cc = vec2(0.5) - qt_TexCoord0;" +
|
||||
"float distance = length(cc);" +
|
||||
|
||||
//FallBack if there are problems
|
||||
(fallBack && (flickering !== 0.0 || horizontalSync !== 0.0) ?
|
||||
"vec2 initialCoords = vec2(fract(time/(1024.0*2.0)), fract(time/(1024.0*1024.0)));
|
||||
vec4 initialNoiseTexel = texture2D(noiseSource, initialCoords);"
|
||||
: "") +
|
||||
(fallBack && flickering !== 0.0 ? "
|
||||
float brightness = 1.0 + (initialNoiseTexel.g - 0.5) * flickering;"
|
||||
: "") +
|
||||
(fallBack && horizontalSync !== 0.0 ? "
|
||||
float randval = horizontalSyncStrength - initialNoiseTexel.r;
|
||||
float distortionScale = step(0.0, randval) * randval * horizontalSyncStrength;
|
||||
float distortionFreq = mix(4.0, 40.0, initialNoiseTexel.g);"
|
||||
: "") +
|
||||
|
||||
(staticNoise ? "
|
||||
float noise = staticNoise;" : "") +
|
||||
|
||||
(screenCurvature !== 0 ? "
|
||||
vec2 staticCoords = barrel(qt_TexCoord0, cc);"
|
||||
:"
|
||||
vec2 staticCoords = qt_TexCoord0;") +
|
||||
|
||||
"vec2 coords = qt_TexCoord0;" +
|
||||
|
||||
(horizontalSync !== 0 ? "
|
||||
float dst = sin((coords.y + time * 0.001) * distortionFreq);
|
||||
coords.x += dst * distortionScale;" +
|
||||
|
||||
(staticNoise ? "
|
||||
noise += distortionScale * 7.0;" : "")
|
||||
|
||||
: "") +
|
||||
|
||||
(jitter !== 0 || staticNoise !== 0 ?
|
||||
"vec4 noiseTexel = texture2D(noiseSource, scaleNoiseSize * coords + vec2(fract(time / 51.0), fract(time / 237.0)));"
|
||||
: "") +
|
||||
|
||||
(jitter !== 0 ? "
|
||||
vec2 offset = vec2(noiseTexel.b, noiseTexel.a) - vec2(0.5);
|
||||
vec2 txt_coords = coords + offset * jitterDisplacement;"
|
||||
: "vec2 txt_coords = coords;") +
|
||||
ShaderEffect {
|
||||
id: dynamicShader
|
||||
|
||||
property ShaderEffectSource screenBuffer: frameBuffer
|
||||
property ShaderEffectSource burnInSource: burnInEffect.source
|
||||
property ShaderEffectSource frameSource: terminalFrameLoader.item
|
||||
|
||||
property color fontColor: parent.fontColor
|
||||
property color backgroundColor: parent.backgroundColor
|
||||
property real screenCurvature: parent.screenCurvature
|
||||
property real chromaColor: parent.chromaColor
|
||||
property real ambientLight: parent.ambientLight
|
||||
|
||||
property real flickering: appSettings.flickering
|
||||
property real horizontalSync: appSettings.horizontalSync
|
||||
property real horizontalSyncStrength: Utils.lint(0.05, 0.35, horizontalSync)
|
||||
property real glowingLine: appSettings.glowingLine * 0.2
|
||||
|
||||
// Fast burnin properties
|
||||
property real burnIn: appSettings.burnIn
|
||||
property real burnInLastUpdate: burnInEffect.lastUpdate
|
||||
property real burnInTime: burnInEffect.burnInFadeTime
|
||||
|
||||
property real jitter: appSettings.jitter
|
||||
property size jitterDisplacement: Qt.size(0.007 * jitter, 0.002 * jitter)
|
||||
property real shadowLength: 0.25 * screenCurvature * Utils.lint(0.50, 1.5, ambientLight)
|
||||
property real staticNoise: appSettings.staticNoise
|
||||
property size scaleNoiseSize: Qt.size((width * 0.75) / (noiseTexture.width * appSettings.windowScaling * appSettings.totalFontScaling),
|
||||
(height * 0.75) / (noiseTexture.height * appSettings.windowScaling * appSettings.totalFontScaling))
|
||||
|
||||
"float color = 0.0001;" +
|
||||
property size virtualResolution: parent.virtualResolution
|
||||
|
||||
(staticNoise !== 0 ? "
|
||||
float noiseVal = noiseTexel.a;
|
||||
color += noiseVal * noise * (1.0 - distance * 1.3);" : "") +
|
||||
|
||||
(glowingLine !== 0 ? "
|
||||
color += randomPass(coords * virtualResolution) * glowingLine;" : "") +
|
||||
|
||||
"vec3 txt_color = texture2D(screenBuffer, txt_coords).rgb;" +
|
||||
|
||||
(burnIn !== 0 ? "
|
||||
vec4 txt_blur = texture2D(burnInSource, staticCoords);
|
||||
float blurDecay = clamp((time - burnInLastUpdate) * burnInTime, 0.0, 1.0);
|
||||
vec3 burnInColor = 0.65 * (txt_blur.rgb - vec3(blurDecay));
|
||||
txt_color = max(txt_color, convertWithChroma(burnInColor));"
|
||||
: "") +
|
||||
|
||||
"txt_color += fontColor.rgb * vec3(color);" +
|
||||
|
||||
"txt_color = applyRasterization(staticCoords, txt_color, virtualResolution, rasterizationIntensity);\n" +
|
||||
|
||||
"vec3 finalColor = txt_color;" +
|
||||
|
||||
(flickering !== 0 ? "
|
||||
finalColor *= brightness;" : "") +
|
||||
|
||||
(ambientLight !== 0 ? "
|
||||
finalColor += vec3(ambientLight) * (1.0 - distance) * (1.0 - distance);" : "") +
|
||||
|
||||
(displayTerminalFrame ?
|
||||
"vec4 frameColor = texture2D(frameSource, qt_TexCoord0);
|
||||
finalColor = mix(finalColor, frameColor.rgb, frameColor.a);"
|
||||
: "") +
|
||||
|
||||
"gl_FragColor = vec4(finalColor, qt_Opacity);" +
|
||||
"}"
|
||||
|
||||
onStatusChanged: {
|
||||
// Print warning messages
|
||||
if (log)
|
||||
console.log(log);
|
||||
|
||||
// Activate fallback mode
|
||||
if (status == ShaderEffect.Error) {
|
||||
fallBack = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loader {
|
||||
id: terminalFrameLoader
|
||||
|
||||
active: dynamicShader.displayTerminalFrame
|
||||
|
||||
width: staticShader.width
|
||||
height: staticShader.height
|
||||
|
||||
sourceComponent: ShaderEffectSource {
|
||||
|
||||
sourceItem: terminalFrame
|
||||
hideSource: true
|
||||
visible: false
|
||||
format: ShaderEffectSource.RGBA
|
||||
|
||||
TerminalFrame {
|
||||
id: terminalFrame
|
||||
blending: false
|
||||
anchors.fill: parent
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ShaderLibrary {
|
||||
id: shaderLibrary
|
||||
}
|
||||
|
||||
ShaderEffect {
|
||||
id: staticShader
|
||||
|
||||
width: parent.width * appSettings.windowScaling
|
||||
height: parent.height * appSettings.windowScaling
|
||||
|
||||
property ShaderEffectSource source: parent.source
|
||||
property ShaderEffectSource bloomSource: parent.bloomSource
|
||||
|
||||
property color fontColor: parent.fontColor
|
||||
property color backgroundColor: parent.backgroundColor
|
||||
property real bloom: appSettings.bloom * 2.5
|
||||
|
||||
property real screenCurvature: parent.screenCurvature
|
||||
|
||||
property real chromaColor: appSettings.chromaColor;
|
||||
|
||||
property real rbgShift: (appSettings.rbgShift / width) * appSettings.totalFontScaling // TODO FILIPPO width here is wrong.
|
||||
|
||||
property int rasterization: appSettings.rasterization
|
||||
|
||||
property real screen_brightness: Utils.lint(0.5, 1.5, appSettings.brightness)
|
||||
|
||||
property real ambientLight: parent.ambientLight
|
||||
|
||||
property size virtualResolution: parent.virtualResolution
|
||||
|
||||
blending: false
|
||||
visible: false
|
||||
|
||||
//Print the number with a reasonable precision for the shader.
|
||||
function str(num){
|
||||
return num.toFixed(8);
|
||||
}
|
||||
|
||||
fragmentShader: "
|
||||
#ifdef GL_ES
|
||||
precision mediump float;
|
||||
#endif
|
||||
|
||||
uniform sampler2D source;
|
||||
uniform highp float qt_Opacity;
|
||||
varying highp vec2 qt_TexCoord0;
|
||||
|
||||
uniform highp vec4 fontColor;
|
||||
uniform highp vec4 backgroundColor;
|
||||
uniform lowp float screen_brightness;
|
||||
|
||||
uniform highp vec2 virtualResolution;" +
|
||||
|
||||
(bloom !== 0 ? "
|
||||
uniform highp sampler2D bloomSource;
|
||||
uniform lowp float bloom;" : "") +
|
||||
|
||||
(screenCurvature !== 0 ? "
|
||||
uniform highp float screenCurvature;" : "") +
|
||||
|
||||
(chromaColor !== 0 ? "
|
||||
uniform lowp float chromaColor;" : "") +
|
||||
|
||||
(rbgShift !== 0 ? "
|
||||
uniform lowp float rbgShift;" : "") +
|
||||
|
||||
(ambientLight !== 0 ? "
|
||||
uniform lowp float ambientLight;" : "") +
|
||||
|
||||
shaderLibrary.min2 +
|
||||
shaderLibrary.sum2 +
|
||||
shaderLibrary.rgb2grey +
|
||||
|
||||
"vec3 convertWithChroma(vec3 inColor) {
|
||||
vec3 outColor = inColor;" +
|
||||
|
||||
(chromaColor !== 0 ?
|
||||
"outColor = fontColor.rgb * mix(vec3(rgb2grey(inColor)), inColor, chromaColor);"
|
||||
:
|
||||
"outColor = fontColor.rgb * rgb2grey(inColor);") +
|
||||
|
||||
" return outColor;
|
||||
}" +
|
||||
|
||||
shaderLibrary.rasterizationShader +
|
||||
|
||||
"void main() {" +
|
||||
"vec2 cc = vec2(0.5) - qt_TexCoord0;" +
|
||||
|
||||
(screenCurvature !== 0 ? "
|
||||
float distortion = dot(cc, cc) * screenCurvature;
|
||||
vec2 curvatureCoords = (qt_TexCoord0 - cc * (1.0 + distortion) * distortion);
|
||||
vec2 txt_coords = - 2.0 * curvatureCoords + 3.0 * step(vec2(0.0), curvatureCoords) * curvatureCoords - 3.0 * step(vec2(1.0), curvatureCoords) * curvatureCoords;"
|
||||
:"
|
||||
vec2 txt_coords = qt_TexCoord0;") +
|
||||
|
||||
"vec3 txt_color = texture2D(source, txt_coords).rgb;" +
|
||||
|
||||
(rbgShift !== 0 ? "
|
||||
vec2 displacement = vec2(12.0, 0.0) * rbgShift;
|
||||
vec3 rightColor = texture2D(source, txt_coords + displacement).rgb;
|
||||
vec3 leftColor = texture2D(source, txt_coords - displacement).rgb;
|
||||
txt_color.r = leftColor.r * 0.10 + rightColor.r * 0.30 + txt_color.r * 0.60;
|
||||
txt_color.g = leftColor.g * 0.20 + rightColor.g * 0.20 + txt_color.g * 0.60;
|
||||
txt_color.b = leftColor.b * 0.30 + rightColor.b * 0.10 + txt_color.b * 0.60;
|
||||
" : "") +
|
||||
|
||||
"txt_color += vec3(0.0001);" +
|
||||
"float greyscale_color = rgb2grey(txt_color);" +
|
||||
|
||||
(screenCurvature !== 0 ? "
|
||||
float reflectionMask = sum2(step(vec2(0.0), curvatureCoords) - step(vec2(1.0), curvatureCoords));
|
||||
reflectionMask = clamp(reflectionMask, 0.0, 1.0);"
|
||||
:
|
||||
"float reflectionMask = 1.0;") +
|
||||
|
||||
(chromaColor !== 0 ?
|
||||
"vec3 foregroundColor = mix(fontColor.rgb, txt_color * fontColor.rgb / greyscale_color, chromaColor);
|
||||
vec3 finalColor = mix(backgroundColor.rgb, foregroundColor, greyscale_color * reflectionMask);"
|
||||
:
|
||||
"vec3 finalColor = mix(backgroundColor.rgb, fontColor.rgb, greyscale_color * reflectionMask);") +
|
||||
|
||||
(bloom !== 0 ?
|
||||
"vec4 bloomFullColor = texture2D(bloomSource, txt_coords);
|
||||
vec3 bloomColor = bloomFullColor.rgb;
|
||||
float bloomAlpha = bloomFullColor.a;
|
||||
bloomColor = convertWithChroma(bloomColor);
|
||||
finalColor += clamp(bloomColor * bloom * bloomAlpha, 0.0, 0.5);"
|
||||
: "") +
|
||||
|
||||
"finalColor *= screen_brightness;" +
|
||||
|
||||
"gl_FragColor = vec4(finalColor, qt_Opacity);" +
|
||||
"}"
|
||||
|
||||
onStatusChanged: {
|
||||
// Print warning messages
|
||||
if (log) console.log(log);
|
||||
}
|
||||
}
|
||||
|
||||
ShaderEffectSource {
|
||||
id: frameBuffer
|
||||
visible: false
|
||||
sourceItem: staticShader
|
||||
hideSource: true
|
||||
}
|
||||
// Rasterization might display oversamping issues if virtual resolution is close to physical display resolution.
|
||||
// We progressively disable rasterization from 4x up to 2x resolution.
|
||||
property real rasterizationIntensity: Utils.smoothstep(2.0, 4.0, _screenDensity)
|
||||
property int rasterizationMode: appSettings.rasterization
|
||||
|
||||
property real displayTerminalFrame: appSettings._frameMargin > 0 || appSettings.screenCurvature > 0
|
||||
|
||||
property real time: timeManager.time
|
||||
property ShaderEffectSource noiseSource: noiseShaderSource
|
||||
|
||||
// Extra uniforms expected by the shared uniform block
|
||||
property real screenShadowCoeff: 0
|
||||
property real frameShadowCoeff: 0
|
||||
property color frameColor: backgroundColor
|
||||
property size margin: Qt.size(0, 0)
|
||||
property real prevLastUpdate: burnInEffect.prevLastUpdate
|
||||
property real screen_brightness: Utils.lint(0.5, 1.5, appSettings.brightness)
|
||||
property real bloom: appSettings.bloom
|
||||
property real rbgShift: (appSettings.rbgShift / Math.max(width, 1)) * appSettings.totalFontScaling
|
||||
|
||||
anchors.fill: parent
|
||||
blending: false
|
||||
|
||||
Image {
|
||||
id: noiseTexture
|
||||
source: "images/allNoise512.png"
|
||||
width: 512
|
||||
height: 512
|
||||
fillMode: Image.Tile
|
||||
visible: false
|
||||
}
|
||||
ShaderEffectSource {
|
||||
id: noiseShaderSource
|
||||
sourceItem: noiseTexture
|
||||
wrapMode: ShaderEffectSource.Repeat
|
||||
visible: false
|
||||
smooth: true
|
||||
}
|
||||
|
||||
vertexShader: "qrc:/shaders/terminal_dynamic.vert.qsb"
|
||||
fragmentShader: "qrc:/shaders/terminal_dynamic.frag.qsb"
|
||||
|
||||
onStatusChanged: if (log) console.log(log)
|
||||
}
|
||||
|
||||
Loader {
|
||||
id: terminalFrameLoader
|
||||
|
||||
active: dynamicShader.displayTerminalFrame
|
||||
|
||||
width: staticShader.width
|
||||
height: staticShader.height
|
||||
|
||||
sourceComponent: ShaderEffectSource {
|
||||
|
||||
sourceItem: terminalFrame
|
||||
hideSource: true
|
||||
visible: false
|
||||
format: ShaderEffectSource.RGBA
|
||||
|
||||
TerminalFrame {
|
||||
id: terminalFrame
|
||||
blending: false
|
||||
anchors.fill: parent
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ShaderLibrary {
|
||||
id: shaderLibrary
|
||||
}
|
||||
|
||||
ShaderEffect {
|
||||
id: staticShader
|
||||
|
||||
width: parent.width * appSettings.windowScaling
|
||||
height: parent.height * appSettings.windowScaling
|
||||
|
||||
property ShaderEffectSource source: parent.source
|
||||
property ShaderEffectSource bloomSource: parent.bloomSource
|
||||
|
||||
property color fontColor: parent.fontColor
|
||||
property color backgroundColor: parent.backgroundColor
|
||||
property real bloom: bloomSource ? appSettings.bloom * 2.5 : 0
|
||||
|
||||
property real screenCurvature: parent.screenCurvature
|
||||
|
||||
property real chromaColor: appSettings.chromaColor;
|
||||
|
||||
property real rbgShift: (appSettings.rbgShift / width) * appSettings.totalFontScaling
|
||||
|
||||
property int rasterization: appSettings.rasterization
|
||||
|
||||
property real screen_brightness: Utils.lint(0.5, 1.5, appSettings.brightness)
|
||||
|
||||
property real ambientLight: parent.ambientLight
|
||||
|
||||
property size virtualResolution: parent.virtualResolution
|
||||
|
||||
// Extra uniforms to match shared uniform block
|
||||
property real time: timeManager.time
|
||||
property real shadowLength: 0
|
||||
property real rasterizationIntensity: Utils.smoothstep(2.0, 4.0, _screenDensity)
|
||||
property int rasterizationMode: appSettings.rasterization
|
||||
property real burnInLastUpdate: burnInEffect.lastUpdate
|
||||
property real burnInTime: burnInEffect.burnInFadeTime
|
||||
property real burnIn: appSettings.burnIn
|
||||
property real staticNoise: appSettings.staticNoise
|
||||
property real glowingLine: appSettings.glowingLine * 0.2
|
||||
property size jitterDisplacement: Qt.size(0, 0)
|
||||
property real jitter: appSettings.jitter
|
||||
property real horizontalSync: appSettings.horizontalSync
|
||||
property real horizontalSyncStrength: Utils.lint(0.05, 0.35, horizontalSync)
|
||||
property real flickering: appSettings.flickering
|
||||
property real displayTerminalFrame: dynamicShader.displayTerminalFrame
|
||||
property size scaleNoiseSize: Qt.size((width * 0.75) / (512 * appSettings.windowScaling * appSettings.totalFontScaling),
|
||||
(height * 0.75) / (512 * appSettings.windowScaling * appSettings.totalFontScaling))
|
||||
property real screenShadowCoeff: 0
|
||||
property real frameShadowCoeff: 0
|
||||
property color frameColor: backgroundColor
|
||||
property size margin: Qt.size(0, 0)
|
||||
property real prevLastUpdate: burnInEffect.prevLastUpdate
|
||||
|
||||
blending: false
|
||||
visible: false
|
||||
|
||||
vertexShader: "qrc:/shaders/passthrough.vert.qsb"
|
||||
fragmentShader: "qrc:/shaders/terminal_static.frag.qsb"
|
||||
|
||||
onStatusChanged: if (log) console.log(log)
|
||||
}
|
||||
|
||||
ShaderEffectSource {
|
||||
id: frameBuffer
|
||||
visible: false
|
||||
sourceItem: staticShader
|
||||
hideSource: true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*******************************************************************************/
|
||||
import QtQuick 2.2
|
||||
import QtGraphicalEffects 1.0
|
||||
import Qt5Compat.GraphicalEffects
|
||||
|
||||
import "utils.js" as Utils
|
||||
|
||||
@@ -38,6 +38,7 @@ ShaderTerminal {
|
||||
terminalWindow.width * devicePixelRatio * appSettings.windowScaling,
|
||||
terminalWindow.height * devicePixelRatio * appSettings.windowScaling
|
||||
)
|
||||
bloomSource: bloomSourceLoader.item
|
||||
|
||||
TimeManager {
|
||||
id: timeManager
|
||||
@@ -75,6 +76,4 @@ ShaderTerminal {
|
||||
visible: false
|
||||
}
|
||||
}
|
||||
|
||||
bloomSource: bloomSourceLoader.item
|
||||
}
|
||||
|
||||
@@ -40,65 +40,36 @@ ShaderEffect {
|
||||
appSettings.frameMargin / height * appSettings.windowScaling
|
||||
)
|
||||
|
||||
ShaderLibrary {
|
||||
id: shaderLibrary
|
||||
}
|
||||
// Uniforms required by the shared block
|
||||
property real qt_Opacity: 1.0
|
||||
property real time: timeManager.time
|
||||
property color fontColor: appSettings.fontColor
|
||||
property color backgroundColor: appSettings.backgroundColor
|
||||
property real shadowLength: 0
|
||||
property size virtualResolution: Qt.size(width, height)
|
||||
property real rasterizationIntensity: 0
|
||||
property int rasterizationMode: 0
|
||||
property real burnInLastUpdate: 0
|
||||
property real burnInTime: 0
|
||||
property real burnIn: 0
|
||||
property real staticNoise: 0
|
||||
property real glowingLine: 0
|
||||
property real chromaColor: 0
|
||||
property size jitterDisplacement: Qt.size(0, 0)
|
||||
property real ambientLight: _ambientLight
|
||||
property real jitter: 0
|
||||
property real horizontalSync: 0
|
||||
property real horizontalSyncStrength: 0
|
||||
property real flickering: 0
|
||||
property real displayTerminalFrame: 0
|
||||
property size scaleNoiseSize: Qt.size(0, 0)
|
||||
property real screen_brightness: 1.0
|
||||
property real bloom: 0
|
||||
property real rbgShift: 0
|
||||
property real prevLastUpdate: 0
|
||||
|
||||
fragmentShader: "
|
||||
#ifdef GL_ES
|
||||
precision mediump float;
|
||||
#endif
|
||||
|
||||
uniform lowp float screenCurvature;
|
||||
uniform lowp float screenShadowCoeff;
|
||||
uniform lowp float frameShadowCoeff;
|
||||
uniform highp float qt_Opacity;
|
||||
uniform lowp vec4 frameColor;
|
||||
uniform mediump vec2 margin;
|
||||
|
||||
varying highp vec2 qt_TexCoord0;
|
||||
|
||||
vec2 distortCoordinates(vec2 coords){
|
||||
vec2 cc = (coords - vec2(0.5));
|
||||
float dist = dot(cc, cc) * screenCurvature;
|
||||
return (coords + cc * (1.0 + dist) * dist);
|
||||
}
|
||||
" +
|
||||
|
||||
shaderLibrary.max2 +
|
||||
shaderLibrary.min2 +
|
||||
shaderLibrary.prod2 +
|
||||
shaderLibrary.sum2 +
|
||||
|
||||
"
|
||||
|
||||
vec2 positiveLog(vec2 x) {
|
||||
return clamp(log(x), vec2(0.0), vec2(100.0));
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 staticCoords = qt_TexCoord0;
|
||||
vec2 coords = distortCoordinates(staticCoords) * (vec2(1.0) + margin * 2.0) - margin;
|
||||
|
||||
vec2 vignetteCoords = staticCoords * (1.0 - staticCoords.yx);
|
||||
float vignette = pow(prod2(vignetteCoords) * 15.0, 0.25);
|
||||
|
||||
vec3 color = frameColor.rgb * vec3(1.0 - vignette);
|
||||
float alpha = 0.0;
|
||||
|
||||
float frameShadow = max2(positiveLog(-coords * frameShadowCoeff + vec2(1.0)) + positiveLog(coords * frameShadowCoeff - (vec2(frameShadowCoeff) - vec2(1.0))));
|
||||
frameShadow = max(sqrt(frameShadow), 0.0);
|
||||
color *= frameShadow;
|
||||
alpha = sum2(1.0 - step(vec2(0.0), coords) + step(vec2(1.0), coords));
|
||||
alpha = clamp(alpha, 0.0, 1.0);
|
||||
alpha *= mix(1.0, 0.9, frameShadow);
|
||||
|
||||
float screenShadow = 1.0 - prod2(positiveLog(coords * screenShadowCoeff + vec2(1.0)) * positiveLog(-coords * screenShadowCoeff + vec2(screenShadowCoeff + 1.0)));
|
||||
alpha = max(0.8 * screenShadow, alpha);
|
||||
|
||||
gl_FragColor = vec4(color * alpha, alpha);
|
||||
}
|
||||
"
|
||||
vertexShader: "qrc:/shaders/passthrough.vert.qsb"
|
||||
fragmentShader: "qrc:/shaders/terminal_frame.frag.qsb"
|
||||
|
||||
onStatusChanged: if (log) console.log(log) //Print warning messages
|
||||
}
|
||||
|
||||
@@ -17,22 +17,29 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*******************************************************************************/
|
||||
import QtQuick 2.2
|
||||
import QtQuick
|
||||
|
||||
Timer {
|
||||
default property bool enableTimer: false
|
||||
property real time
|
||||
QtObject {
|
||||
id: timeManager
|
||||
|
||||
NumberAnimation on time {
|
||||
from: 0
|
||||
to: 100000
|
||||
running: appSettings.fps === 0 && enableTimer
|
||||
duration: 100000
|
||||
loops: Animation.Infinite
|
||||
property bool enableTimer: false
|
||||
property real time: 0
|
||||
|
||||
property int framesPerUpdate: Math.max(1, appSettings.effectsFrameSkip)
|
||||
property int _frameCounter: 0
|
||||
|
||||
property var frameDriver: FrameAnimation {
|
||||
running: enableTimer
|
||||
onTriggered: {
|
||||
timeManager._frameCounter += 1
|
||||
|
||||
if (timeManager._frameCounter >= timeManager.framesPerUpdate) {
|
||||
time = elapsedTime
|
||||
timeManager._frameCounter = 0
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onTriggered: time += interval
|
||||
running: appSettings.fps !== 0 && enableTimer
|
||||
interval: Math.round(1000 / appSettings.fps)
|
||||
repeat: true
|
||||
onEnableTimerChanged: if (!enableTimer) _frameCounter = 0
|
||||
onFramesPerUpdateChanged: _frameCounter = 0
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -1,8 +0,0 @@
|
||||
|
||||
Fonts in this package are (c) 2010-2014 Style.
|
||||
|
||||
This license is applicable to each font file included in this package in all their variants (ttf, eot, woff, woff2, svg).
|
||||
|
||||
You MAY NOT: sell this font; include/redistribute the font in any font collection regardless of pricing; provide the font for direct download from any web site, modify or rename the font. You MAY: link to "http://style64.org/c64-truetype" in order for others to download and install the font; embed the font (without any modification or file renaming) for display on any web site using @font-face rules; use this font in static images and vector art; include this font (without any modification or file renaming) as part of a software package but ONLY if said software package is freely provided to end users. You may also contact us to negotiate a (possibly commercial) license for your use outside of these guidelines at "http://style64.org/contact-style".
|
||||
|
||||
At all times the most recent version of this license can be found at "http://style64.org/c64-truetype/license".
|
||||
@@ -1,428 +0,0 @@
|
||||
Attribution-ShareAlike 4.0 International
|
||||
|
||||
=======================================================================
|
||||
|
||||
Creative Commons Corporation ("Creative Commons") is not a law firm and
|
||||
does not provide legal services or legal advice. Distribution of
|
||||
Creative Commons public licenses does not create a lawyer-client or
|
||||
other relationship. Creative Commons makes its licenses and related
|
||||
information available on an "as-is" basis. Creative Commons gives no
|
||||
warranties regarding its licenses, any material licensed under their
|
||||
terms and conditions, or any related information. Creative Commons
|
||||
disclaims all liability for damages resulting from their use to the
|
||||
fullest extent possible.
|
||||
|
||||
Using Creative Commons Public Licenses
|
||||
|
||||
Creative Commons public licenses provide a standard set of terms and
|
||||
conditions that creators and other rights holders may use to share
|
||||
original works of authorship and other material subject to copyright
|
||||
and certain other rights specified in the public license below. The
|
||||
following considerations are for informational purposes only, are not
|
||||
exhaustive, and do not form part of our licenses.
|
||||
|
||||
Considerations for licensors: Our public licenses are
|
||||
intended for use by those authorized to give the public
|
||||
permission to use material in ways otherwise restricted by
|
||||
copyright and certain other rights. Our licenses are
|
||||
irrevocable. Licensors should read and understand the terms
|
||||
and conditions of the license they choose before applying it.
|
||||
Licensors should also secure all rights necessary before
|
||||
applying our licenses so that the public can reuse the
|
||||
material as expected. Licensors should clearly mark any
|
||||
material not subject to the license. This includes other CC-
|
||||
licensed material, or material used under an exception or
|
||||
limitation to copyright. More considerations for licensors:
|
||||
wiki.creativecommons.org/Considerations_for_licensors
|
||||
|
||||
Considerations for the public: By using one of our public
|
||||
licenses, a licensor grants the public permission to use the
|
||||
licensed material under specified terms and conditions. If
|
||||
the licensor's permission is not necessary for any reason--for
|
||||
example, because of any applicable exception or limitation to
|
||||
copyright--then that use is not regulated by the license. Our
|
||||
licenses grant only permissions under copyright and certain
|
||||
other rights that a licensor has authority to grant. Use of
|
||||
the licensed material may still be restricted for other
|
||||
reasons, including because others have copyright or other
|
||||
rights in the material. A licensor may make special requests,
|
||||
such as asking that all changes be marked or described.
|
||||
Although not required by our licenses, you are encouraged to
|
||||
respect those requests where reasonable. More_considerations
|
||||
for the public:
|
||||
wiki.creativecommons.org/Considerations_for_licensees
|
||||
|
||||
=======================================================================
|
||||
|
||||
Creative Commons Attribution-ShareAlike 4.0 International Public
|
||||
License
|
||||
|
||||
By exercising the Licensed Rights (defined below), You accept and agree
|
||||
to be bound by the terms and conditions of this Creative Commons
|
||||
Attribution-ShareAlike 4.0 International Public License ("Public
|
||||
License"). To the extent this Public License may be interpreted as a
|
||||
contract, You are granted the Licensed Rights in consideration of Your
|
||||
acceptance of these terms and conditions, and the Licensor grants You
|
||||
such rights in consideration of benefits the Licensor receives from
|
||||
making the Licensed Material available under these terms and
|
||||
conditions.
|
||||
|
||||
|
||||
Section 1 -- Definitions.
|
||||
|
||||
a. Adapted Material means material subject to Copyright and Similar
|
||||
Rights that is derived from or based upon the Licensed Material
|
||||
and in which the Licensed Material is translated, altered,
|
||||
arranged, transformed, or otherwise modified in a manner requiring
|
||||
permission under the Copyright and Similar Rights held by the
|
||||
Licensor. For purposes of this Public License, where the Licensed
|
||||
Material is a musical work, performance, or sound recording,
|
||||
Adapted Material is always produced where the Licensed Material is
|
||||
synched in timed relation with a moving image.
|
||||
|
||||
b. Adapter's License means the license You apply to Your Copyright
|
||||
and Similar Rights in Your contributions to Adapted Material in
|
||||
accordance with the terms and conditions of this Public License.
|
||||
|
||||
c. BY-SA Compatible License means a license listed at
|
||||
creativecommons.org/compatiblelicenses, approved by Creative
|
||||
Commons as essentially the equivalent of this Public License.
|
||||
|
||||
d. Copyright and Similar Rights means copyright and/or similar rights
|
||||
closely related to copyright including, without limitation,
|
||||
performance, broadcast, sound recording, and Sui Generis Database
|
||||
Rights, without regard to how the rights are labeled or
|
||||
categorized. For purposes of this Public License, the rights
|
||||
specified in Section 2(b)(1)-(2) are not Copyright and Similar
|
||||
Rights.
|
||||
|
||||
e. Effective Technological Measures means those measures that, in the
|
||||
absence of proper authority, may not be circumvented under laws
|
||||
fulfilling obligations under Article 11 of the WIPO Copyright
|
||||
Treaty adopted on December 20, 1996, and/or similar international
|
||||
agreements.
|
||||
|
||||
f. Exceptions and Limitations means fair use, fair dealing, and/or
|
||||
any other exception or limitation to Copyright and Similar Rights
|
||||
that applies to Your use of the Licensed Material.
|
||||
|
||||
g. License Elements means the license attributes listed in the name
|
||||
of a Creative Commons Public License. The License Elements of this
|
||||
Public License are Attribution and ShareAlike.
|
||||
|
||||
h. Licensed Material means the artistic or literary work, database,
|
||||
or other material to which the Licensor applied this Public
|
||||
License.
|
||||
|
||||
i. Licensed Rights means the rights granted to You subject to the
|
||||
terms and conditions of this Public License, which are limited to
|
||||
all Copyright and Similar Rights that apply to Your use of the
|
||||
Licensed Material and that the Licensor has authority to license.
|
||||
|
||||
j. Licensor means the individual(s) or entity(ies) granting rights
|
||||
under this Public License.
|
||||
|
||||
k. Share means to provide material to the public by any means or
|
||||
process that requires permission under the Licensed Rights, such
|
||||
as reproduction, public display, public performance, distribution,
|
||||
dissemination, communication, or importation, and to make material
|
||||
available to the public including in ways that members of the
|
||||
public may access the material from a place and at a time
|
||||
individually chosen by them.
|
||||
|
||||
l. Sui Generis Database Rights means rights other than copyright
|
||||
resulting from Directive 96/9/EC of the European Parliament and of
|
||||
the Council of 11 March 1996 on the legal protection of databases,
|
||||
as amended and/or succeeded, as well as other essentially
|
||||
equivalent rights anywhere in the world.
|
||||
|
||||
m. You means the individual or entity exercising the Licensed Rights
|
||||
under this Public License. Your has a corresponding meaning.
|
||||
|
||||
|
||||
Section 2 -- Scope.
|
||||
|
||||
a. License grant.
|
||||
|
||||
1. Subject to the terms and conditions of this Public License,
|
||||
the Licensor hereby grants You a worldwide, royalty-free,
|
||||
non-sublicensable, non-exclusive, irrevocable license to
|
||||
exercise the Licensed Rights in the Licensed Material to:
|
||||
|
||||
a. reproduce and Share the Licensed Material, in whole or
|
||||
in part; and
|
||||
|
||||
b. produce, reproduce, and Share Adapted Material.
|
||||
|
||||
2. Exceptions and Limitations. For the avoidance of doubt, where
|
||||
Exceptions and Limitations apply to Your use, this Public
|
||||
License does not apply, and You do not need to comply with
|
||||
its terms and conditions.
|
||||
|
||||
3. Term. The term of this Public License is specified in Section
|
||||
6(a).
|
||||
|
||||
4. Media and formats; technical modifications allowed. The
|
||||
Licensor authorizes You to exercise the Licensed Rights in
|
||||
all media and formats whether now known or hereafter created,
|
||||
and to make technical modifications necessary to do so. The
|
||||
Licensor waives and/or agrees not to assert any right or
|
||||
authority to forbid You from making technical modifications
|
||||
necessary to exercise the Licensed Rights, including
|
||||
technical modifications necessary to circumvent Effective
|
||||
Technological Measures. For purposes of this Public License,
|
||||
simply making modifications authorized by this Section 2(a)
|
||||
(4) never produces Adapted Material.
|
||||
|
||||
5. Downstream recipients.
|
||||
|
||||
a. Offer from the Licensor -- Licensed Material. Every
|
||||
recipient of the Licensed Material automatically
|
||||
receives an offer from the Licensor to exercise the
|
||||
Licensed Rights under the terms and conditions of this
|
||||
Public License.
|
||||
|
||||
b. Additional offer from the Licensor -- Adapted Material.
|
||||
Every recipient of Adapted Material from You
|
||||
automatically receives an offer from the Licensor to
|
||||
exercise the Licensed Rights in the Adapted Material
|
||||
under the conditions of the Adapter's License You apply.
|
||||
|
||||
c. No downstream restrictions. You may not offer or impose
|
||||
any additional or different terms or conditions on, or
|
||||
apply any Effective Technological Measures to, the
|
||||
Licensed Material if doing so restricts exercise of the
|
||||
Licensed Rights by any recipient of the Licensed
|
||||
Material.
|
||||
|
||||
6. No endorsement. Nothing in this Public License constitutes or
|
||||
may be construed as permission to assert or imply that You
|
||||
are, or that Your use of the Licensed Material is, connected
|
||||
with, or sponsored, endorsed, or granted official status by,
|
||||
the Licensor or others designated to receive attribution as
|
||||
provided in Section 3(a)(1)(A)(i).
|
||||
|
||||
b. Other rights.
|
||||
|
||||
1. Moral rights, such as the right of integrity, are not
|
||||
licensed under this Public License, nor are publicity,
|
||||
privacy, and/or other similar personality rights; however, to
|
||||
the extent possible, the Licensor waives and/or agrees not to
|
||||
assert any such rights held by the Licensor to the limited
|
||||
extent necessary to allow You to exercise the Licensed
|
||||
Rights, but not otherwise.
|
||||
|
||||
2. Patent and trademark rights are not licensed under this
|
||||
Public License.
|
||||
|
||||
3. To the extent possible, the Licensor waives any right to
|
||||
collect royalties from You for the exercise of the Licensed
|
||||
Rights, whether directly or through a collecting society
|
||||
under any voluntary or waivable statutory or compulsory
|
||||
licensing scheme. In all other cases the Licensor expressly
|
||||
reserves any right to collect such royalties.
|
||||
|
||||
|
||||
Section 3 -- License Conditions.
|
||||
|
||||
Your exercise of the Licensed Rights is expressly made subject to the
|
||||
following conditions.
|
||||
|
||||
a. Attribution.
|
||||
|
||||
1. If You Share the Licensed Material (including in modified
|
||||
form), You must:
|
||||
|
||||
a. retain the following if it is supplied by the Licensor
|
||||
with the Licensed Material:
|
||||
|
||||
i. identification of the creator(s) of the Licensed
|
||||
Material and any others designated to receive
|
||||
attribution, in any reasonable manner requested by
|
||||
the Licensor (including by pseudonym if
|
||||
designated);
|
||||
|
||||
ii. a copyright notice;
|
||||
|
||||
iii. a notice that refers to this Public License;
|
||||
|
||||
iv. a notice that refers to the disclaimer of
|
||||
warranties;
|
||||
|
||||
v. a URI or hyperlink to the Licensed Material to the
|
||||
extent reasonably practicable;
|
||||
|
||||
b. indicate if You modified the Licensed Material and
|
||||
retain an indication of any previous modifications; and
|
||||
|
||||
c. indicate the Licensed Material is licensed under this
|
||||
Public License, and include the text of, or the URI or
|
||||
hyperlink to, this Public License.
|
||||
|
||||
2. You may satisfy the conditions in Section 3(a)(1) in any
|
||||
reasonable manner based on the medium, means, and context in
|
||||
which You Share the Licensed Material. For example, it may be
|
||||
reasonable to satisfy the conditions by providing a URI or
|
||||
hyperlink to a resource that includes the required
|
||||
information.
|
||||
|
||||
3. If requested by the Licensor, You must remove any of the
|
||||
information required by Section 3(a)(1)(A) to the extent
|
||||
reasonably practicable.
|
||||
|
||||
b. ShareAlike.
|
||||
|
||||
In addition to the conditions in Section 3(a), if You Share
|
||||
Adapted Material You produce, the following conditions also apply.
|
||||
|
||||
1. The Adapter's License You apply must be a Creative Commons
|
||||
license with the same License Elements, this version or
|
||||
later, or a BY-SA Compatible License.
|
||||
|
||||
2. You must include the text of, or the URI or hyperlink to, the
|
||||
Adapter's License You apply. You may satisfy this condition
|
||||
in any reasonable manner based on the medium, means, and
|
||||
context in which You Share Adapted Material.
|
||||
|
||||
3. You may not offer or impose any additional or different terms
|
||||
or conditions on, or apply any Effective Technological
|
||||
Measures to, Adapted Material that restrict exercise of the
|
||||
rights granted under the Adapter's License You apply.
|
||||
|
||||
|
||||
Section 4 -- Sui Generis Database Rights.
|
||||
|
||||
Where the Licensed Rights include Sui Generis Database Rights that
|
||||
apply to Your use of the Licensed Material:
|
||||
|
||||
a. for the avoidance of doubt, Section 2(a)(1) grants You the right
|
||||
to extract, reuse, reproduce, and Share all or a substantial
|
||||
portion of the contents of the database;
|
||||
|
||||
b. if You include all or a substantial portion of the database
|
||||
contents in a database in which You have Sui Generis Database
|
||||
Rights, then the database in which You have Sui Generis Database
|
||||
Rights (but not its individual contents) is Adapted Material,
|
||||
|
||||
including for purposes of Section 3(b); and
|
||||
c. You must comply with the conditions in Section 3(a) if You Share
|
||||
all or a substantial portion of the contents of the database.
|
||||
|
||||
For the avoidance of doubt, this Section 4 supplements and does not
|
||||
replace Your obligations under this Public License where the Licensed
|
||||
Rights include other Copyright and Similar Rights.
|
||||
|
||||
|
||||
Section 5 -- Disclaimer of Warranties and Limitation of Liability.
|
||||
|
||||
a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
|
||||
EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
|
||||
AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
|
||||
ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
|
||||
IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
|
||||
WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
||||
PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
|
||||
ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
|
||||
KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
|
||||
ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
|
||||
|
||||
b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
|
||||
TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
|
||||
NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
|
||||
INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
|
||||
COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
|
||||
USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
|
||||
ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
|
||||
DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
|
||||
IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
|
||||
|
||||
c. The disclaimer of warranties and limitation of liability provided
|
||||
above shall be interpreted in a manner that, to the extent
|
||||
possible, most closely approximates an absolute disclaimer and
|
||||
waiver of all liability.
|
||||
|
||||
|
||||
Section 6 -- Term and Termination.
|
||||
|
||||
a. This Public License applies for the term of the Copyright and
|
||||
Similar Rights licensed here. However, if You fail to comply with
|
||||
this Public License, then Your rights under this Public License
|
||||
terminate automatically.
|
||||
|
||||
b. Where Your right to use the Licensed Material has terminated under
|
||||
Section 6(a), it reinstates:
|
||||
|
||||
1. automatically as of the date the violation is cured, provided
|
||||
it is cured within 30 days of Your discovery of the
|
||||
violation; or
|
||||
|
||||
2. upon express reinstatement by the Licensor.
|
||||
|
||||
For the avoidance of doubt, this Section 6(b) does not affect any
|
||||
right the Licensor may have to seek remedies for Your violations
|
||||
of this Public License.
|
||||
|
||||
c. For the avoidance of doubt, the Licensor may also offer the
|
||||
Licensed Material under separate terms or conditions or stop
|
||||
distributing the Licensed Material at any time; however, doing so
|
||||
will not terminate this Public License.
|
||||
|
||||
d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
|
||||
License.
|
||||
|
||||
|
||||
Section 7 -- Other Terms and Conditions.
|
||||
|
||||
a. The Licensor shall not be bound by any additional or different
|
||||
terms or conditions communicated by You unless expressly agreed.
|
||||
|
||||
b. Any arrangements, understandings, or agreements regarding the
|
||||
Licensed Material not stated herein are separate from and
|
||||
independent of the terms and conditions of this Public License.
|
||||
|
||||
|
||||
Section 8 -- Interpretation.
|
||||
|
||||
a. For the avoidance of doubt, this Public License does not, and
|
||||
shall not be interpreted to, reduce, limit, restrict, or impose
|
||||
conditions on any use of the Licensed Material that could lawfully
|
||||
be made without permission under this Public License.
|
||||
|
||||
b. To the extent possible, if any provision of this Public License is
|
||||
deemed unenforceable, it shall be automatically reformed to the
|
||||
minimum extent necessary to make it enforceable. If the provision
|
||||
cannot be reformed, it shall be severed from this Public License
|
||||
without affecting the enforceability of the remaining terms and
|
||||
conditions.
|
||||
|
||||
c. No term or condition of this Public License will be waived and no
|
||||
failure to comply consented to unless expressly agreed to by the
|
||||
Licensor.
|
||||
|
||||
d. Nothing in this Public License constitutes or may be interpreted
|
||||
as a limitation upon, or waiver of, any privileges and immunities
|
||||
that apply to the Licensor or You, including from the legal
|
||||
processes of any jurisdiction or authority.
|
||||
|
||||
|
||||
=======================================================================
|
||||
|
||||
Creative Commons is not a party to its public
|
||||
licenses. Notwithstanding, Creative Commons may elect to apply one of
|
||||
its public licenses to material it publishes and in those instances
|
||||
will be considered the “Licensor.” The text of the Creative Commons
|
||||
public licenses is dedicated to the public domain under the CC0 Public
|
||||
Domain Dedication. Except for the limited purpose of indicating that
|
||||
material is shared under a Creative Commons public license or as
|
||||
otherwise permitted by the Creative Commons policies published at
|
||||
creativecommons.org/policies, Creative Commons does not authorize the
|
||||
use of the trademark "Creative Commons" or any other trademark or logo
|
||||
of Creative Commons without its prior written consent including,
|
||||
without limitation, in connection with any unauthorized modifications
|
||||
to any of its public licenses or any other arrangements,
|
||||
understandings, or agreements concerning use of licensed material. For
|
||||
the avoidance of doubt, this paragraph does not form part of the
|
||||
public licenses.
|
||||
|
||||
Creative Commons may be contacted at creativecommons.org.
|
||||
|
||||
Binary file not shown.
Binary file not shown.
BIN
app/qml/fonts/cozette/CozetteVector.ttf
Normal file
BIN
app/qml/fonts/cozette/CozetteVector.ttf
Normal file
Binary file not shown.
BIN
app/qml/fonts/fira-code/FiraCode-Medium.ttf
Normal file
BIN
app/qml/fonts/fira-code/FiraCode-Medium.ttf
Normal file
Binary file not shown.
@@ -1,97 +1,158 @@
|
||||
Copyright (c) 2010 Dimitar Toshkov Zhekov,
|
||||
with Reserved Font Name "Terminus Font".
|
||||
|
||||
Copyright (c) 2011 Tilman Blumenbach,
|
||||
with Reserved Font Name "Terminus (TTF)".
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
http://scripts.sil.org/OFL
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
Copyright (c) 2014, The Fira Code Project Authors (https://github.com/tonsky/FiraCode)
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
http://scripts.sil.org/OFL
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
|
||||
About
|
||||
|
||||
Free monospaced font with programming ligatures
|
||||
Topics
|
||||
font ligatures programming-ligatures
|
||||
Resources
|
||||
Readme
|
||||
License
|
||||
OFL-1.1 license
|
||||
Activity
|
||||
Stars
|
||||
80.8k stars
|
||||
Watchers
|
||||
704 watching
|
||||
Forks
|
||||
3.2k forks
|
||||
Report repository
|
||||
Releases 29
|
||||
6.2 Latest
|
||||
on Dec 6, 2021
|
||||
+ 28 releases
|
||||
Used by 457
|
||||
|
||||
@bolabaden
|
||||
@utkarshkrsingh
|
||||
@elkozmon
|
||||
@DVSB
|
||||
@virtualtam
|
||||
@techplayz32
|
||||
@mecattaf
|
||||
@MrTato
|
||||
|
||||
+ 449
|
||||
Contributors 124
|
||||
|
||||
@tonsky
|
||||
@thundernixon
|
||||
@jsoref
|
||||
@joshka
|
||||
@davelab6
|
||||
@thaliaarchi
|
||||
@drify
|
||||
@eltociear
|
||||
@j-f1
|
||||
@ollicle
|
||||
@vorburger
|
||||
@gjvnq
|
||||
@Dominionized
|
||||
@ShalokShalom
|
||||
|
||||
+ 110 contributors
|
||||
Languages
|
||||
|
||||
Clojure 47.3%
|
||||
Shell 22.4%
|
||||
Python 18.5%
|
||||
HTML 7.4%
|
||||
CSS 2.5%
|
||||
PureBasic 1.1%
|
||||
|
||||
Other 0.8%
|
||||
|
||||
Footer
|
||||
|
||||
BIN
app/qml/fonts/greybeard/Greybeard-12px.ttf
Normal file
BIN
app/qml/fonts/greybeard/Greybeard-12px.ttf
Normal file
Binary file not shown.
BIN
app/qml/fonts/greybeard/Greybeard-16px.ttf
Normal file
BIN
app/qml/fonts/greybeard/Greybeard-16px.ttf
Normal file
Binary file not shown.
@@ -1,7 +1,7 @@
|
||||
ProFont
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2014 Carl Osterwald, Stephen C. Gilardi, Andrew Welch
|
||||
Copyright (c) 2012-2015 Uwe Waldmann
|
||||
Modified work Copyright 2018 Andy Walker
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -10,13 +10,13 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
BIN
app/qml/fonts/hack/Hack-Regular.ttf
Normal file
BIN
app/qml/fonts/hack/Hack-Regular.ttf
Normal file
Binary file not shown.
31
app/qml/fonts/hack/LICENSE.txt
Normal file
31
app/qml/fonts/hack/LICENSE.txt
Normal file
@@ -0,0 +1,31 @@
|
||||
The work in the Hack project is Copyright 2018 Source Foundry Authors and licensed under the MIT License
|
||||
|
||||
The work in the DejaVu project was committed to the public domain.
|
||||
|
||||
Bitstream Vera Sans Mono Copyright 2003 Bitstream Inc. and licensed under the Bitstream Vera License with Reserved Font Names "Bitstream" and "Vera"
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2018 Source Foundry Authors
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
BITSTREAM VERA LICENSE
|
||||
|
||||
Copyright (c) 2003 by Bitstream, Inc. All Rights Reserved. Bitstream Vera is a trademark of Bitstream, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of the fonts accompanying this license ("Fonts") and associated documentation files (the "Font Software"), to reproduce and distribute the Font Software, including without limitation the rights to use, copy, merge, publish, distribute, and/or sell copies of the Font Software, and to permit persons to whom the Font Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright and trademark notices and this permission notice shall be included in all copies of one or more of the Font Software typefaces.
|
||||
|
||||
The Font Software may be modified, altered, or added to, and in particular the designs of glyphs or characters in the Fonts may be modified and additional glyphs or characters may be added to the Fonts, only if the fonts are renamed to names not containing either the words "Bitstream" or the word "Vera".
|
||||
|
||||
This License becomes null and void to the extent applicable to Fonts or Font Software that has been modified and is distributed under the "Bitstream Vera" names.
|
||||
|
||||
The Font Software may be sold as part of a larger software package but no copy of one or more of the Font Software typefaces may be sold by itself.
|
||||
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL BITSTREAM OR THE GNOME FOUNDATION BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
|
||||
Except as contained in this notice, the names of Gnome, the Gnome Foundation, and Bitstream Inc., shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Font Software without prior written authorization from the Gnome Foundation or Bitstream Inc., respectively. For further information, contact: fonts at gnome dot org.
|
||||
BIN
app/qml/fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf
Normal file
BIN
app/qml/fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf
Normal file
Binary file not shown.
110
app/qml/fonts/iosevka/LICENSE.txt
Normal file
110
app/qml/fonts/iosevka/LICENSE.txt
Normal file
@@ -0,0 +1,110 @@
|
||||
Copyright (c) 2015-2025, Renzhi Li (aka. Belleve Invis, belleve@typeof.net)
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
http://scripts.sil.org/OFL
|
||||
|
||||
--------------------------
|
||||
|
||||
|
||||
SIL Open Font License v1.1
|
||||
====================================================
|
||||
|
||||
|
||||
Preamble
|
||||
----------
|
||||
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
|
||||
Definitions
|
||||
-------------
|
||||
|
||||
`"Font Software"` refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
`"Reserved Font Name"` refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
`"Original Version"` refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
`"Modified Version"` refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
`"Author"` refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
|
||||
Permission & Conditions
|
||||
------------------------
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1. Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2. Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3. No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4. The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5. The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
|
||||
|
||||
Termination
|
||||
-----------
|
||||
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
|
||||
DISCLAIMER
|
||||
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
BIN
app/qml/fonts/jetbrains-mono/JetBrainsMono-Medium.ttf
Normal file
BIN
app/qml/fonts/jetbrains-mono/JetBrainsMono-Medium.ttf
Normal file
Binary file not shown.
187
app/qml/fonts/modern-hermit/LICENSE → app/qml/fonts/jetbrains-mono/LICENSE.txt
Executable file → Normal file
187
app/qml/fonts/modern-hermit/LICENSE → app/qml/fonts/jetbrains-mono/LICENSE.txt
Executable file → Normal file
@@ -1,94 +1,93 @@
|
||||
Copyright (c) 2013, Pablo Caro <me AT pcaro DOT es> - http://pcaro.es/
|
||||
with Reserved Font Name Hermit.
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
http://scripts.sil.org/OFL
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
Copyright 2020 The JetBrains Mono Project Authors (https://github.com/JetBrains/JetBrainsMono)
|
||||
|
||||
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
||||
This license is copied below, and is also available with a FAQ at:
|
||||
https://scripts.sil.org/OFL
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1 +0,0 @@
|
||||
dopustz:-480
|
||||
Binary file not shown.
@@ -1,31 +0,0 @@
|
||||
WHAT IS THIS?
|
||||
|
||||
This is ProFont TrueType, converted to Windows TrueType format
|
||||
by Mike Smith, with some tweaks added by "ardu".
|
||||
|
||||
Modifications include:
|
||||
- A Euro character
|
||||
- Missing characters from the Latin 1 code page
|
||||
- Full support for CodePage 850. These are mostly the famous
|
||||
block/box characters you know from DOS. Very useful if you use
|
||||
Mightnight Commander through PuTTY.
|
||||
- Fixed metrics so that point size of 9 works correctly. Until now
|
||||
you had to select 7 to obtain the native point size of 9.
|
||||
- Added some quick&dirty hinting for point size of 9. Most characters
|
||||
now match closely the look of the bitmap version.
|
||||
Don't expect it to look good on anything else than Windows...
|
||||
|
||||
|
||||
|
||||
To get the full original Distribution, other ProFont builds
|
||||
and more information
|
||||
go to <http://tobiasjung.name/profont/>
|
||||
|
||||
|
||||
DISCLAIMER
|
||||
See LICENSE file
|
||||
|
||||
|
||||
Tobias Jung
|
||||
January 2014
|
||||
profont@tobiasjung.name
|
||||
@@ -1,7 +0,0 @@
|
||||
Copyright (c) 2004, 2005 Tristan Grimmer
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
Binary file not shown.
Binary file not shown.
BIN
app/qml/fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf
Normal file
BIN
app/qml/fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf
Normal file
Binary file not shown.
BIN
app/qml/fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf
Normal file
BIN
app/qml/fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
app/qml/fonts/pet-me/PetMe64.ttf
Normal file
BIN
app/qml/fonts/pet-me/PetMe64.ttf
Normal file
Binary file not shown.
127
app/qml/fonts/terminus/LICENSE
Normal file
127
app/qml/fonts/terminus/LICENSE
Normal file
@@ -0,0 +1,127 @@
|
||||
This package was debianized by Anton Zinoviev <zinoviev@debian.ort>.
|
||||
|
||||
It was downloaded from http://terminus-font.sourceforge.net/
|
||||
|
||||
Terminus Font is licensed under the SIL Open Font License, Version 1.1.
|
||||
|
||||
Copyright (c) 2010-2014 Dimitar Toshkov Zhekov,
|
||||
with Reserved Font Name "Terminus Font".
|
||||
|
||||
To avoid name conflicts with other products named "Terminus", the
|
||||
archive should be distributed as "Terminus Font", not "Terminus".
|
||||
|
||||
|
||||
-----------------------------------------------------------
|
||||
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
||||
-----------------------------------------------------------
|
||||
|
||||
PREAMBLE
|
||||
The goals of the Open Font License (OFL) are to stimulate worldwide
|
||||
development of collaborative font projects, to support the font creation
|
||||
efforts of academic and linguistic communities, and to provide a free and
|
||||
open framework in which fonts may be shared and improved in partnership
|
||||
with others.
|
||||
|
||||
The OFL allows the licensed fonts to be used, studied, modified and
|
||||
redistributed freely as long as they are not sold by themselves. The
|
||||
fonts, including any derivative works, can be bundled, embedded,
|
||||
redistributed and/or sold with any software provided that any reserved
|
||||
names are not used by derivative works. The fonts and derivatives,
|
||||
however, cannot be released under any other type of license. The
|
||||
requirement for fonts to remain under this license does not apply
|
||||
to any document created using the fonts or their derivatives.
|
||||
|
||||
DEFINITIONS
|
||||
"Font Software" refers to the set of files released by the Copyright
|
||||
Holder(s) under this license and clearly marked as such. This may
|
||||
include source files, build scripts and documentation.
|
||||
|
||||
"Reserved Font Name" refers to any names specified as such after the
|
||||
copyright statement(s).
|
||||
|
||||
"Original Version" refers to the collection of Font Software components as
|
||||
distributed by the Copyright Holder(s).
|
||||
|
||||
"Modified Version" refers to any derivative made by adding to, deleting,
|
||||
or substituting -- in part or in whole -- any of the components of the
|
||||
Original Version, by changing formats or by porting the Font Software to a
|
||||
new environment.
|
||||
|
||||
"Author" refers to any designer, engineer, programmer, technical
|
||||
writer or other person who contributed to the Font Software.
|
||||
|
||||
PERMISSION & CONDITIONS
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
||||
redistribute, and sell modified and unmodified copies of the Font
|
||||
Software, subject to the following conditions:
|
||||
|
||||
1) Neither the Font Software nor any of its individual components,
|
||||
in Original or Modified Versions, may be sold by itself.
|
||||
|
||||
2) Original or Modified Versions of the Font Software may be bundled,
|
||||
redistributed and/or sold with any software, provided that each copy
|
||||
contains the above copyright notice and this license. These can be
|
||||
included either as stand-alone text files, human-readable headers or
|
||||
in the appropriate machine-readable metadata fields within text or
|
||||
binary files as long as those fields can be easily viewed by the user.
|
||||
|
||||
3) No Modified Version of the Font Software may use the Reserved Font
|
||||
Name(s) unless explicit written permission is granted by the corresponding
|
||||
Copyright Holder. This restriction only applies to the primary font name as
|
||||
presented to the users.
|
||||
|
||||
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
||||
Software shall not be used to promote, endorse or advertise any
|
||||
Modified Version, except to acknowledge the contribution(s) of the
|
||||
Copyright Holder(s) and the Author(s) or with their explicit written
|
||||
permission.
|
||||
|
||||
5) The Font Software, modified or unmodified, in part or in whole,
|
||||
must be distributed entirely under this license, and must not be
|
||||
distributed under any other license. The requirement for fonts to
|
||||
remain under this license does not apply to any document created
|
||||
using the Font Software.
|
||||
|
||||
TERMINATION
|
||||
This license becomes null and void if any of the above conditions are
|
||||
not met.
|
||||
|
||||
DISCLAIMER
|
||||
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
||||
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
||||
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
||||
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
||||
OTHER DEALINGS IN THE FONT SOFTWARE.
|
||||
|
||||
=================================================================
|
||||
|
||||
The fonts from the package xfonts-terminus-oblique are automatically
|
||||
generated from the fonts in xfonts-terminus using the script
|
||||
bdfslant.pl. This script has the following copyright:
|
||||
|
||||
Copyright (C) 1994-95 Cronyx Ltd, author: Serge Vakulenko, <vak@cronyx.ru>
|
||||
Changes Copyright (C) 1995-1997 by Andrey A. Chernov, Moscow, Russia.
|
||||
Changes (C) 2000 by Serge Winitzki
|
||||
|
||||
This software may be used, modified, copied, distributed, and sold,
|
||||
in both source and binary form provided that the above copyright
|
||||
and these terms are retained. Under no circumstances is the author
|
||||
responsible for the proper functioning of this software, nor does
|
||||
the author assume any responsibility for damages incurred with its use.
|
||||
|
||||
=================================================================
|
||||
|
||||
The source package includes the bdftopsf.pl and ucstoany.pl utilities.
|
||||
These are not used in order to build the binary Debian packages. They
|
||||
are distributed under the GNU General Public License version 2.0 or
|
||||
(at your choice) any later version. You should have received a copy
|
||||
of the GNU General Public License with your Debian GNU/Linux system,
|
||||
in /usr/share/common-licenses/GPL. If not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
|
||||
USA
|
||||
|
||||
BIN
app/qml/fonts/terminus/TerminusTTF-4.49.3.ttf
Normal file
BIN
app/qml/fonts/terminus/TerminusTTF-4.49.3.ttf
Normal file
Binary file not shown.
1
app/qml/fonts/unscii/LICENSE
Normal file
1
app/qml/fonts/unscii/LICENSE
Normal file
@@ -0,0 +1 @@
|
||||
You can consider it Public Domain (or CC-0) except for the files derived from or containing parts of Roman Czyborra's Unifont project (unifont.hex, hex2bdf.pl, unscii-16-full.*) which fall under GPL. See https://savannah.gnu.org/projects/unifont/ for more.
|
||||
BIN
app/qml/fonts/unscii/unscii-16-full.ttf
Normal file
BIN
app/qml/fonts/unscii/unscii-16-full.ttf
Normal file
Binary file not shown.
BIN
app/qml/fonts/unscii/unscii-8-thin.ttf
Normal file
BIN
app/qml/fonts/unscii/unscii-8-thin.ttf
Normal file
Binary file not shown.
BIN
app/qml/fonts/unscii/unscii-8.ttf
Normal file
BIN
app/qml/fonts/unscii/unscii-8.ttf
Normal file
Binary file not shown.
@@ -79,11 +79,10 @@ Menu {
|
||||
text: model.text
|
||||
onTriggered: {
|
||||
appSettings.loadProfileString(obj_string)
|
||||
appSettings.handleFontChanged()
|
||||
}
|
||||
}
|
||||
onObjectAdded: profilesMenu.insertItem(index, object)
|
||||
onObjectRemoved: profilesMenu.removeItem(object)
|
||||
onObjectAdded: function(index, object) { profilesMenu.insertItem(index, object) }
|
||||
onObjectRemoved: function(object) { profilesMenu.removeItem(object) }
|
||||
}
|
||||
}
|
||||
Menu {
|
||||
|
||||
@@ -72,11 +72,10 @@ MenuBar {
|
||||
text: model.text
|
||||
onTriggered: {
|
||||
appSettings.loadProfileString(obj_string)
|
||||
appSettings.handleFontChanged()
|
||||
}
|
||||
}
|
||||
onObjectAdded: profilesMenu.insertItem(index, object)
|
||||
onObjectRemoved: profilesMenu.removeItem(object)
|
||||
onObjectAdded: function(index, object) { profilesMenu.insertItem(index, object) }
|
||||
onObjectRemoved: function(object) { profilesMenu.removeItem(object) }
|
||||
}
|
||||
}
|
||||
Menu {
|
||||
|
||||
@@ -69,11 +69,10 @@ MenuBar {
|
||||
text: model.text
|
||||
onTriggered: {
|
||||
appSettings.loadProfileString(obj_string)
|
||||
appSettings.handleFontChanged()
|
||||
}
|
||||
}
|
||||
onObjectAdded: profilesMenu.insertItem(index, object)
|
||||
onObjectRemoved: profilesMenu.removeItem(object)
|
||||
onObjectAdded: function(index, object) { profilesMenu.insertItem(index, object) }
|
||||
onObjectRemoved: function(object) { profilesMenu.removeItem(object) }
|
||||
}
|
||||
}
|
||||
Menu {
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
<file>ApplicationSettings.qml</file>
|
||||
<file>SettingsWindow.qml</file>
|
||||
<file>Fonts.qml</file>
|
||||
<file>FontPixels.qml</file>
|
||||
<file>SettingsGeneralTab.qml</file>
|
||||
<file>PreprocessedTerminal.qml</file>
|
||||
<file>TimeManager.qml</file>
|
||||
@@ -17,34 +16,45 @@
|
||||
<file>SettingsEffectsTab.qml</file>
|
||||
<file>main.qml</file>
|
||||
<file>SettingsTerminalTab.qml</file>
|
||||
<file>FontScanlines.qml</file>
|
||||
<file>fonts/1977-apple2/PrintChar21.ttf</file>
|
||||
<file>fonts/1971-ibm-3278/3270-Regular.ttf</file>
|
||||
<file>fonts/apple2/PrintChar21.ttf</file>
|
||||
<file>fonts/ibm-3278/3270-Regular.ttf</file>
|
||||
<file>Storage.qml</file>
|
||||
<file>SettingsAdvancedTab.qml</file>
|
||||
<file>TerminalContainer.qml</file>
|
||||
<file>images/crt256.png</file>
|
||||
<file>utils.js</file>
|
||||
<file>images/allNoise512.png</file>
|
||||
<file>fonts/modern-proggy-tiny/ProggyTiny.ttf</file>
|
||||
<file>fonts/modern-pro-font-win-tweaked/ProFontWindows.ttf</file>
|
||||
<file>fonts/modern-hermit/Hermit-medium.otf</file>
|
||||
<file>fonts/modern-inconsolata/Inconsolata.otf</file>
|
||||
<file>fonts/modern-fixedsys-excelsior/FSEX301-L2.ttf</file>
|
||||
<file>fonts/fixedsys-excelsior/FSEX301-L2.ttf</file>
|
||||
<file>fonts/cozette/CozetteVector.ttf</file>
|
||||
<file>fonts/greybeard/Greybeard-16px.ttf</file>
|
||||
<file>fonts/hack/Hack-Regular.ttf</file>
|
||||
<file>fonts/fira-code/FiraCode-Medium.ttf</file>
|
||||
<file>fonts/iosevka/IosevkaTerm-ExtendedMedium.ttf</file>
|
||||
<file>fonts/jetbrains-mono/JetBrainsMono-Medium.ttf</file>
|
||||
<file>../icons/32x32/cool-retro-term.png</file>
|
||||
<file>Components/SizedLabel.qml</file>
|
||||
<file>fonts/1979-atari-400-800/AtariClassic-Regular.ttf</file>
|
||||
<file>fonts/1982-commodore64/C64_Pro_Mono-STYLE.ttf</file>
|
||||
<file>fonts/1981-ibm-pc/PxPlus_IBM_BIOS.ttf</file>
|
||||
<file>fonts/1985-ibm-pc-vga/PxPlus_IBM_VGA8.ttf</file>
|
||||
<file>fonts/1977-commodore-pet/PetMe.ttf</file>
|
||||
<file>fonts/atari-400-800/AtariClassic-Regular.ttf</file>
|
||||
<file>fonts/pet-me/PetMe64.ttf</file>
|
||||
<file>fonts/pet-me/PetMe.ttf</file>
|
||||
<file>BurnInEffect.qml</file>
|
||||
<file>fonts/modern-terminus/TerminusTTF-4.46.0.ttf</file>
|
||||
<file>fonts/terminus/TerminusTTF-4.49.3.ttf</file>
|
||||
<file>TerminalFrame.qml</file>
|
||||
<file>menus/WindowMenu.qml</file>
|
||||
<file>menus/FullContextMenu.qml</file>
|
||||
<file>menus/ShortContextMenu.qml</file>
|
||||
<file>ShaderLibrary.qml</file>
|
||||
<file>menus/OSXMenu.qml</file>
|
||||
<file>../shaders/terminal_dynamic.vert.qsb</file>
|
||||
<file>../shaders/terminal_dynamic.frag.qsb</file>
|
||||
<file>../shaders/passthrough.vert.qsb</file>
|
||||
<file>../shaders/terminal_static.frag.qsb</file>
|
||||
<file>../shaders/terminal_frame.frag.qsb</file>
|
||||
<file>../shaders/burn_in.frag.qsb</file>
|
||||
<file>fonts/unscii/unscii-8-thin.ttf</file>
|
||||
<file>fonts/unscii/unscii-16-full.ttf</file>
|
||||
<file>fonts/unscii/unscii-8.ttf</file>
|
||||
<file>fonts/oldschool-pc-fonts/PxPlus_IBM_EGA_8x8.ttf</file>
|
||||
<file>fonts/oldschool-pc-fonts/PxPlus_IBM_VGA8.ttf</file>
|
||||
<file>fonts/oldschool-pc-fonts/PxPlus_IBM_VGA_8x16.ttf</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
||||
63
app/shaders/burn_in.frag
Normal file
63
app/shaders/burn_in.frag
Normal file
@@ -0,0 +1,63 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec2 qt_TexCoord0;
|
||||
layout(location = 0) out vec4 fragColor;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
layout(binding = 1) uniform sampler2D txt_source;
|
||||
layout(binding = 2) uniform sampler2D burnInSource;
|
||||
|
||||
float rgb2grey(vec3 v) {
|
||||
return dot(v, vec3(0.21, 0.72, 0.04));
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 coords = qt_TexCoord0;
|
||||
|
||||
vec3 txtColor = texture(txt_source, coords).rgb;
|
||||
vec4 accColor = texture(burnInSource, coords);
|
||||
|
||||
float prevMask = accColor.a;
|
||||
float currMask = rgb2grey(txtColor);
|
||||
|
||||
float blurDecay = clamp((burnInLastUpdate - prevLastUpdate) * burnInTime, 0.0, 1.0);
|
||||
blurDecay = max(0.0, blurDecay - prevMask);
|
||||
vec3 blurColor = accColor.rgb - vec3(blurDecay);
|
||||
vec3 color = max(blurColor, txtColor);
|
||||
|
||||
fragColor = vec4(color, currMask) * qt_Opacity;
|
||||
}
|
||||
BIN
app/shaders/burn_in.frag.qsb
Normal file
BIN
app/shaders/burn_in.frag.qsb
Normal file
Binary file not shown.
46
app/shaders/passthrough.vert
Normal file
46
app/shaders/passthrough.vert
Normal file
@@ -0,0 +1,46 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec4 qt_Vertex;
|
||||
layout(location = 1) in vec2 qt_MultiTexCoord0;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
layout(location = 0) out vec2 qt_TexCoord0;
|
||||
|
||||
void main() {
|
||||
qt_TexCoord0 = qt_MultiTexCoord0;
|
||||
gl_Position = qt_Matrix * qt_Vertex;
|
||||
}
|
||||
BIN
app/shaders/passthrough.vert.qsb
Normal file
BIN
app/shaders/passthrough.vert.qsb
Normal file
Binary file not shown.
163
app/shaders/terminal_dynamic.frag
Normal file
163
app/shaders/terminal_dynamic.frag
Normal file
@@ -0,0 +1,163 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec2 qt_TexCoord0;
|
||||
layout(location = 1) in float vBrightness;
|
||||
layout(location = 2) in float vDistortionScale;
|
||||
layout(location = 3) in float vDistortionFreq;
|
||||
|
||||
layout(location = 0) out vec4 fragColor;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
layout(binding = 0) uniform sampler2D noiseSource;
|
||||
layout(binding = 1) uniform sampler2D screenBuffer;
|
||||
layout(binding = 2) uniform sampler2D burnInSource;
|
||||
layout(binding = 3) uniform sampler2D frameSource;
|
||||
|
||||
float min2(vec2 v) { return min(v.x, v.y); }
|
||||
float prod2(vec2 v) { return v.x * v.y; }
|
||||
float sum2(vec2 v) { return v.x + v.y; }
|
||||
float rgb2grey(vec3 v) { return dot(v, vec3(0.21, 0.72, 0.04)); }
|
||||
|
||||
vec3 applyRasterization(vec2 screenCoords, vec3 texel, vec2 virtualRes, float intensity, int mode) {
|
||||
if (intensity <= 0.0 || mode == 0) {
|
||||
return texel;
|
||||
}
|
||||
|
||||
const float INTENSITY = 0.30;
|
||||
const float BRIGHTBOOST = 0.30;
|
||||
|
||||
if (mode == 1) { // scanline
|
||||
vec3 pixelHigh = ((1.0 + BRIGHTBOOST) - (0.2 * texel)) * texel;
|
||||
vec3 pixelLow = ((1.0 - INTENSITY) + (0.1 * texel)) * texel;
|
||||
|
||||
vec2 coords = fract(screenCoords * virtualRes) * 2.0 - vec2(1.0);
|
||||
float mask = 1.0 - abs(coords.y);
|
||||
|
||||
vec3 rasterizationColor = mix(pixelLow, pixelHigh, mask);
|
||||
return mix(texel, rasterizationColor, intensity);
|
||||
} else if (mode == 2) { // pixel
|
||||
vec3 pixelHigh = ((1.0 + BRIGHTBOOST) - (0.2 * texel)) * texel;
|
||||
vec3 pixelLow = ((1.0 - INTENSITY) + (0.1 * texel)) * texel;
|
||||
|
||||
vec2 coords = fract(screenCoords * virtualRes) * 2.0 - vec2(1.0);
|
||||
coords = coords * coords;
|
||||
float mask = 1.0 - coords.x - coords.y;
|
||||
|
||||
vec3 rasterizationColor = mix(pixelLow, pixelHigh, mask);
|
||||
return mix(texel, rasterizationColor, intensity);
|
||||
} else if (mode == 3) { // subpixel
|
||||
const float SUBPIXELS = 3.0;
|
||||
vec3 offsets = vec3(3.141592654) * vec3(0.5, 0.5 - 2.0 / 3.0, 0.5 - 4.0 / 3.0);
|
||||
|
||||
vec2 omega = vec2(3.141592654) * vec2(2.0) * virtualRes;
|
||||
vec2 angle = screenCoords * omega;
|
||||
vec3 xfactors = (SUBPIXELS + sin(angle.x + offsets)) / (SUBPIXELS + 1.0);
|
||||
|
||||
vec3 result = texel * xfactors;
|
||||
vec3 pixelHigh = ((1.0 + BRIGHTBOOST) - (0.2 * result)) * result;
|
||||
vec3 pixelLow = ((1.0 - INTENSITY) + (0.1 * result)) * result;
|
||||
|
||||
vec2 coords = fract(screenCoords * virtualRes) * 2.0 - vec2(1.0);
|
||||
float mask = 1.0 - abs(coords.y);
|
||||
|
||||
vec3 rasterizationColor = mix(pixelLow, pixelHigh, mask);
|
||||
return mix(texel, rasterizationColor, intensity);
|
||||
}
|
||||
|
||||
return texel;
|
||||
}
|
||||
|
||||
float randomPass(vec2 coords){
|
||||
return fract(smoothstep(-120.0, 0.0, coords.y - (virtualResolution.y + 120.0) * fract(time * 0.15)));
|
||||
}
|
||||
|
||||
vec2 barrel(vec2 v, vec2 cc) {
|
||||
float distortion = dot(cc, cc) * screenCurvature;
|
||||
return (v - cc * (1.0 + distortion) * distortion);
|
||||
}
|
||||
|
||||
vec3 convertWithChroma(vec3 inColor) {
|
||||
vec3 outColor = fontColor.rgb * rgb2grey(inColor);
|
||||
if (chromaColor != 0.0) {
|
||||
outColor = fontColor.rgb * mix(vec3(rgb2grey(inColor)), inColor, chromaColor);
|
||||
}
|
||||
return outColor;
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 cc = vec2(0.5) - qt_TexCoord0;
|
||||
float distance = length(cc);
|
||||
|
||||
vec2 staticCoords = barrel(qt_TexCoord0, cc);
|
||||
vec2 coords = qt_TexCoord0;
|
||||
|
||||
float dst = sin((coords.y + time) * vDistortionFreq);
|
||||
coords.x += dst * vDistortionScale;
|
||||
|
||||
vec4 noiseTexel = texture(noiseSource, scaleNoiseSize * coords + vec2(fract(time / 0.051), fract(time / 0.237)));
|
||||
|
||||
vec2 txt_coords = coords + (noiseTexel.ba - vec2(0.5)) * jitterDisplacement * jitter;
|
||||
|
||||
float color = 0.0001;
|
||||
color += noiseTexel.a * staticNoise * (1.0 - distance * 1.3);
|
||||
color += randomPass(coords * virtualResolution) * glowingLine;
|
||||
|
||||
vec3 txt_color = texture(screenBuffer, txt_coords).rgb;
|
||||
|
||||
if (burnIn > 0.0) {
|
||||
vec4 txt_blur = texture(burnInSource, staticCoords);
|
||||
float blurDecay = clamp((time - burnInLastUpdate) * burnInTime, 0.0, 1.0);
|
||||
vec3 burnInColor = 0.65 * (txt_blur.rgb - vec3(blurDecay));
|
||||
txt_color = max(txt_color, convertWithChroma(burnInColor));
|
||||
}
|
||||
|
||||
txt_color += fontColor.rgb * vec3(color);
|
||||
txt_color = applyRasterization(staticCoords, txt_color, virtualResolution, rasterizationIntensity, rasterizationMode);
|
||||
|
||||
vec3 finalColor = txt_color;
|
||||
float brightness = mix(1.0, vBrightness, step(0.0, flickering));
|
||||
finalColor *= brightness;
|
||||
|
||||
finalColor += vec3(ambientLight) * (1.0 - distance) * (1.0 - distance);
|
||||
|
||||
if (displayTerminalFrame > 0.0) {
|
||||
vec4 frameColor = texture(frameSource, qt_TexCoord0);
|
||||
finalColor = mix(finalColor, frameColor.rgb, frameColor.a);
|
||||
}
|
||||
|
||||
fragColor = vec4(finalColor, qt_Opacity);
|
||||
}
|
||||
BIN
app/shaders/terminal_dynamic.frag.qsb
Normal file
BIN
app/shaders/terminal_dynamic.frag.qsb
Normal file
Binary file not shown.
61
app/shaders/terminal_dynamic.vert
Normal file
61
app/shaders/terminal_dynamic.vert
Normal file
@@ -0,0 +1,61 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec4 qt_Vertex;
|
||||
layout(location = 1) in vec2 qt_MultiTexCoord0;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
layout(binding = 0) uniform sampler2D noiseSource;
|
||||
|
||||
layout(location = 0) out vec2 qt_TexCoord0;
|
||||
layout(location = 1) out float vBrightness;
|
||||
layout(location = 2) out float vDistortionScale;
|
||||
layout(location = 3) out float vDistortionFreq;
|
||||
|
||||
void main() {
|
||||
qt_TexCoord0 = qt_MultiTexCoord0;
|
||||
|
||||
vec2 coords = vec2(fract(time / 2.048), fract(time / 1048.576));
|
||||
vec4 initialNoiseTexel = texture(noiseSource, coords);
|
||||
|
||||
vBrightness = 1.0 + (initialNoiseTexel.g - 0.5) * flickering;
|
||||
|
||||
float randval = horizontalSyncStrength - initialNoiseTexel.r;
|
||||
vDistortionScale = step(0.0, randval) * randval * horizontalSyncStrength * horizontalSync;
|
||||
vDistortionFreq = mix(4.0, 40.0, initialNoiseTexel.g) * step(0.0, horizontalSync);
|
||||
|
||||
gl_Position = qt_Matrix * qt_Vertex;
|
||||
}
|
||||
BIN
app/shaders/terminal_dynamic.vert.qsb
Normal file
BIN
app/shaders/terminal_dynamic.vert.qsb
Normal file
Binary file not shown.
77
app/shaders/terminal_frame.frag
Normal file
77
app/shaders/terminal_frame.frag
Normal file
@@ -0,0 +1,77 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec2 qt_TexCoord0;
|
||||
layout(location = 0) out vec4 fragColor;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
float min2(vec2 v) { return min(v.x, v.y); }
|
||||
float max2(vec2 v) { return max(v.x, v.y); }
|
||||
float prod2(vec2 v) { return v.x * v.y; }
|
||||
float sum2(vec2 v) { return v.x + v.y; }
|
||||
|
||||
vec2 distortCoordinates(vec2 coords){
|
||||
vec2 cc = (coords - vec2(0.5));
|
||||
float dist = dot(cc, cc) * screenCurvature;
|
||||
return (coords + cc * (1.0 + dist) * dist);
|
||||
}
|
||||
|
||||
vec2 positiveLog(vec2 x) {
|
||||
return clamp(log(x), vec2(0.0), vec2(100.0));
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 staticCoords = qt_TexCoord0;
|
||||
vec2 coords = distortCoordinates(staticCoords) * (vec2(1.0) + margin * 2.0) - margin;
|
||||
|
||||
vec2 vignetteCoords = staticCoords * (1.0 - staticCoords.yx);
|
||||
float vignette = pow(prod2(vignetteCoords) * 15.0, 0.25);
|
||||
|
||||
vec3 color = frameColor.rgb * vec3(1.0 - vignette);
|
||||
float alpha = 0.0;
|
||||
|
||||
float frameShadow = max2(positiveLog(-coords * frameShadowCoeff + vec2(1.0)) + positiveLog(coords * frameShadowCoeff - (vec2(frameShadowCoeff) - vec2(1.0))));
|
||||
frameShadow = max(sqrt(frameShadow), 0.0);
|
||||
color *= frameShadow;
|
||||
alpha = sum2(1.0 - step(vec2(0.0), coords) + step(vec2(1.0), coords));
|
||||
alpha = clamp(alpha, 0.0, 1.0);
|
||||
alpha *= mix(1.0, 0.9, frameShadow);
|
||||
|
||||
float screenShadow = 1.0 - prod2(positiveLog(coords * screenShadowCoeff + vec2(1.0)) * positiveLog(-coords * screenShadowCoeff + vec2(screenShadowCoeff + 1.0)));
|
||||
alpha = max(0.8 * screenShadow, alpha);
|
||||
|
||||
fragColor = vec4(color * alpha, alpha) * qt_Opacity;
|
||||
}
|
||||
BIN
app/shaders/terminal_frame.frag.qsb
Normal file
BIN
app/shaders/terminal_frame.frag.qsb
Normal file
Binary file not shown.
104
app/shaders/terminal_static.frag
Normal file
104
app/shaders/terminal_static.frag
Normal file
@@ -0,0 +1,104 @@
|
||||
#version 440
|
||||
|
||||
layout(location = 0) in vec2 qt_TexCoord0;
|
||||
layout(location = 0) out vec4 fragColor;
|
||||
|
||||
layout(std140, binding = 0) uniform ubuf {
|
||||
mat4 qt_Matrix;
|
||||
float qt_Opacity;
|
||||
float time;
|
||||
vec4 fontColor;
|
||||
vec4 backgroundColor;
|
||||
float shadowLength;
|
||||
vec2 virtualResolution;
|
||||
float rasterizationIntensity;
|
||||
int rasterizationMode;
|
||||
float burnInLastUpdate;
|
||||
float burnInTime;
|
||||
float burnIn;
|
||||
float staticNoise;
|
||||
float screenCurvature;
|
||||
float glowingLine;
|
||||
float chromaColor;
|
||||
vec2 jitterDisplacement;
|
||||
float ambientLight;
|
||||
float jitter;
|
||||
float horizontalSync;
|
||||
float horizontalSyncStrength;
|
||||
float flickering;
|
||||
float displayTerminalFrame;
|
||||
vec2 scaleNoiseSize;
|
||||
float screen_brightness;
|
||||
float bloom;
|
||||
float rbgShift;
|
||||
float screenShadowCoeff;
|
||||
float frameShadowCoeff;
|
||||
vec4 frameColor;
|
||||
vec2 margin;
|
||||
float prevLastUpdate;
|
||||
};
|
||||
|
||||
layout(binding = 1) uniform sampler2D source;
|
||||
layout(binding = 2) uniform sampler2D bloomSource;
|
||||
|
||||
float sum2(vec2 v) { return v.x + v.y; }
|
||||
float rgb2grey(vec3 v) { return dot(v, vec3(0.21, 0.72, 0.04)); }
|
||||
|
||||
vec3 convertWithChroma(vec3 inColor) {
|
||||
vec3 outColor = fontColor.rgb * rgb2grey(inColor);
|
||||
if (chromaColor != 0.0) {
|
||||
outColor = fontColor.rgb * mix(vec3(rgb2grey(inColor)), inColor, chromaColor);
|
||||
}
|
||||
return outColor;
|
||||
}
|
||||
|
||||
void main() {
|
||||
vec2 cc = vec2(0.5) - qt_TexCoord0;
|
||||
|
||||
vec2 txt_coords = qt_TexCoord0;
|
||||
if (screenCurvature != 0.0) {
|
||||
float distortion = dot(cc, cc) * screenCurvature;
|
||||
vec2 curvatureCoords = (qt_TexCoord0 - cc * (1.0 + distortion) * distortion);
|
||||
txt_coords = -2.0 * curvatureCoords + 3.0 * step(vec2(0.0), curvatureCoords) * curvatureCoords - 3.0 * step(vec2(1.0), curvatureCoords) * curvatureCoords;
|
||||
}
|
||||
|
||||
vec3 txt_color = texture(source, txt_coords).rgb;
|
||||
|
||||
if (rbgShift != 0.0) {
|
||||
vec2 displacement = vec2(12.0, 0.0) * rbgShift;
|
||||
vec3 rightColor = texture(source, txt_coords + displacement).rgb;
|
||||
vec3 leftColor = texture(source, txt_coords - displacement).rgb;
|
||||
txt_color.r = leftColor.r * 0.10 + rightColor.r * 0.30 + txt_color.r * 0.60;
|
||||
txt_color.g = leftColor.g * 0.20 + rightColor.g * 0.20 + txt_color.g * 0.60;
|
||||
txt_color.b = leftColor.b * 0.30 + rightColor.b * 0.10 + txt_color.b * 0.60;
|
||||
}
|
||||
|
||||
txt_color += vec3(0.0001);
|
||||
float greyscale_color = rgb2grey(txt_color);
|
||||
|
||||
float reflectionMask = 1.0;
|
||||
if (screenCurvature != 0.0) {
|
||||
float distortion = dot(cc, cc) * screenCurvature;
|
||||
vec2 curvatureCoords = (qt_TexCoord0 - cc * (1.0 + distortion) * distortion);
|
||||
reflectionMask = sum2(step(vec2(0.0), curvatureCoords) - step(vec2(1.0), curvatureCoords));
|
||||
reflectionMask = clamp(reflectionMask, 0.0, 1.0);
|
||||
}
|
||||
|
||||
vec3 finalColor;
|
||||
if (chromaColor != 0.0) {
|
||||
vec3 foregroundColor = mix(fontColor.rgb, txt_color * fontColor.rgb / greyscale_color, chromaColor);
|
||||
finalColor = mix(backgroundColor.rgb, foregroundColor, greyscale_color * reflectionMask);
|
||||
} else {
|
||||
finalColor = mix(backgroundColor.rgb, fontColor.rgb, greyscale_color * reflectionMask);
|
||||
}
|
||||
|
||||
if (bloom != 0.0) {
|
||||
vec4 bloomFullColor = texture(bloomSource, txt_coords);
|
||||
vec3 bloomColor = convertWithChroma(bloomFullColor.rgb);
|
||||
float bloomAlpha = bloomFullColor.a;
|
||||
finalColor += clamp(bloomColor * bloom * bloomAlpha, 0.0, 0.5);
|
||||
}
|
||||
|
||||
finalColor *= screen_brightness;
|
||||
fragColor = vec4(finalColor, qt_Opacity);
|
||||
}
|
||||
BIN
app/shaders/terminal_static.frag.qsb
Normal file
BIN
app/shaders/terminal_static.frag.qsb
Normal file
Binary file not shown.
Submodule qmltermwidget updated: 63228027e1...290f542d23
36
scripts/list_glyph_counts.py
Normal file
36
scripts/list_glyph_counts.py
Normal file
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
Print glyph counts for all font files under app/qml/fonts.
|
||||
Requires fontTools (already available in this environment).
|
||||
"""
|
||||
from pathlib import Path
|
||||
from fontTools.ttLib import TTFont
|
||||
|
||||
|
||||
def count_glyphs(font_path: Path) -> int:
|
||||
"""Return the number of glyphs in the font."""
|
||||
with TTFont(str(font_path), lazy=False, fontNumber=0) as font:
|
||||
return len(font.getGlyphOrder())
|
||||
|
||||
|
||||
def main() -> None:
|
||||
fonts_root = Path(__file__).resolve().parents[1] / "app" / "qml" / "fonts"
|
||||
font_files = sorted(
|
||||
p for p in fonts_root.rglob("*") if p.suffix.lower() in {".ttf", ".otf", ".otb"}
|
||||
)
|
||||
|
||||
if not font_files:
|
||||
print(f"No font files found under {fonts_root}")
|
||||
return
|
||||
|
||||
for font_path in font_files:
|
||||
rel = font_path.relative_to(fonts_root.parent.parent)
|
||||
try:
|
||||
count = count_glyphs(font_path)
|
||||
print(f"{rel}: {count} glyphs")
|
||||
except Exception as exc: # noqa: BLE001
|
||||
print(f"{rel}: error reading font ({exc})")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in New Issue
Block a user