mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-12 10:22:12 +02:00
Terminal: support yakuake
This commit is contained in:
@@ -32,6 +32,7 @@ Features:
|
||||
* Add module `Terminal Size` which prints the number of terminal width and height in charactors and pixels
|
||||
* Add new option `--temperature-unit`
|
||||
* Better CPU and Host detection for Android (Android)
|
||||
* Support yakuake terminal version & font detection (Terminal, Linux)
|
||||
|
||||
Bugfixes:
|
||||
* Fix possible hanging (TerminalFont, #493)
|
||||
|
||||
@@ -116,7 +116,7 @@ Budgie, Cinnamon, Gnome, KDE Plasma, LXQt, Mate, XFCE4
|
||||
|
||||
##### Terminal fonts
|
||||
```
|
||||
Alacritty, Apple Terminal, ConEmu, Deepin Terminal, foot, Gnome Terminal, iTerm2, Kitty, Konsole, LXTerminal, MATE Terminal, mintty, QTerminal, Tabby, Terminator, Termux, Tilix, TTY, Warp, WezTerm, Windows Terminal, XFCE4 Terminal
|
||||
Alacritty, Apple Terminal, ConEmu, Deepin Terminal, foot, Gnome Terminal, iTerm2, Kitty, Konsole, LXTerminal, MATE Terminal, mintty, QTerminal, Tabby, Terminator, Termux, Tilix, TTY, Warp, WezTerm, Windows Terminal, XFCE4 Terminal, Yakuake
|
||||
```
|
||||
|
||||
## Building
|
||||
|
||||
@@ -70,14 +70,18 @@ static void detectFromConfigFile(const char* configFile, const char* start, FFTe
|
||||
ffFontInitPango(&terminalFont->font, fontName.chars);
|
||||
}
|
||||
|
||||
static void detectKonsole(FFTerminalFontResult* terminalFont)
|
||||
static void detectKonsole(FFTerminalFontResult* terminalFont, const char* rcFile)
|
||||
{
|
||||
FF_STRBUF_AUTO_DESTROY profile = ffStrbufCreate();
|
||||
ffParsePropFileConfig("konsolerc", "DefaultProfile =", &profile);
|
||||
if(!ffParsePropFileConfig(rcFile, "DefaultProfile =", &profile))
|
||||
{
|
||||
ffStrbufAppendF(&terminalFont->error, "Configuration \".config/%s\" doesn't exist", rcFile);
|
||||
return;
|
||||
}
|
||||
|
||||
if(profile.length == 0)
|
||||
{
|
||||
ffStrbufAppendS(&terminalFont->error, "Couldn't find \"DefaultProfile=%[^\\n]\" in \".config/konsolerc\"");
|
||||
ffStrbufAppendS(&terminalFont->error, "Built-in profile is used");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -228,7 +232,9 @@ static void detectXterm(FFTerminalFontResult* terminalFont)
|
||||
void ffDetectTerminalFontPlatform(const FFTerminalShellResult* terminalShell, FFTerminalFontResult* terminalFont)
|
||||
{
|
||||
if(ffStrbufIgnCaseEqualS(&terminalShell->terminalProcessName, "konsole"))
|
||||
detectKonsole(terminalFont);
|
||||
detectKonsole(terminalFont, "konsolerc");
|
||||
else if(ffStrbufIgnCaseEqualS(&terminalShell->terminalProcessName, "yakuake"))
|
||||
detectKonsole(terminalFont, "yakuakerc");
|
||||
else if(ffStrbufIgnCaseEqualS(&terminalShell->terminalProcessName, "xfce4-terminal"))
|
||||
detectXFCETerminal(terminalFont);
|
||||
else if(ffStrbufIgnCaseEqualS(&terminalShell->terminalProcessName, "lxterminal"))
|
||||
|
||||
@@ -309,6 +309,9 @@ bool fftsGetTerminalVersion(FFstrbuf* processName, FF_MAYBE_UNUSED FFstrbuf* exe
|
||||
if(ffStrbufIgnCaseEqualS(processName, "konsole"))
|
||||
return getTerminalVersionKonsole(exe, version);
|
||||
|
||||
if(ffStrbufIgnCaseEqualS(processName, "yakuake"))
|
||||
return getExeVersionGeneral(exe, version);//yakuake 22.12.3
|
||||
|
||||
if(ffStrbufIgnCaseEqualS(processName, "xfce4-terminal"))
|
||||
return getExeVersionGeneral(exe, version);//xfce4-terminal 1.0.4 (Xfce 4.18)...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user