mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2025-02-20 11:43:27 +08:00
Logo (Image): add --kitty-icat
; honor --logo-height
if set
This commit is contained in:
parent
9f37557177
commit
d58d786c83
@ -352,6 +352,14 @@
|
||||
"type": "path"
|
||||
}
|
||||
},
|
||||
{
|
||||
"long": "kitty-icat",
|
||||
"desc": "Short for --logo-type kitty-icat --logo <path>",
|
||||
"remark": "See \"--help logo-type\" for more info",
|
||||
"arg": {
|
||||
"type": "path"
|
||||
}
|
||||
},
|
||||
{
|
||||
"long": "iterm",
|
||||
"desc": "Short for --logo-type iterm --logo <path>",
|
||||
|
@ -190,17 +190,18 @@ static bool printImageKittyIcat(bool printError)
|
||||
{
|
||||
char place[64];
|
||||
snprintf(place,
|
||||
ARRAY_SIZE(place),
|
||||
"--place=%ux9999@%ux%u",
|
||||
options->width,
|
||||
options->paddingLeft + 1,
|
||||
options->paddingTop + 1);
|
||||
ARRAY_SIZE(place),
|
||||
"--place=%ux%u@%ux%u",
|
||||
options->width,
|
||||
options->height == 0 ? 9999 : options->height,
|
||||
options->paddingLeft + 1,
|
||||
options->paddingTop + 1);
|
||||
|
||||
error = ffProcessAppendStdOut(&buf, (char* []) {
|
||||
"kitten",
|
||||
"icat",
|
||||
"-n",
|
||||
"--align=left",
|
||||
"--align=center",
|
||||
place,
|
||||
"--scale-up",
|
||||
options->source.chars,
|
||||
|
@ -173,6 +173,11 @@ logoType:
|
||||
ffOptionParseString(key, value, &options->source);
|
||||
options->type = FF_LOGO_TYPE_IMAGE_KITTY_DIRECT;
|
||||
}
|
||||
else if(ffStrEqualsIgnCase(key, "--kitty-icat"))
|
||||
{
|
||||
ffOptionParseString(key, value, &options->source);
|
||||
options->type = FF_LOGO_TYPE_IMAGE_KITTY_ICAT;
|
||||
}
|
||||
else if(ffStrEqualsIgnCase(key, "--iterm"))
|
||||
{
|
||||
ffOptionParseString(key, value, &options->source);
|
||||
|
Loading…
x
Reference in New Issue
Block a user