Temp fix for #1

This commit is contained in:
Laura Hausmann 2023-01-18 02:57:08 +01:00
parent e00a4c793d
commit 65b83a6cd9
Signed by: zotan
GPG key ID: D044E84C5BE01605

View file

@ -198,7 +198,7 @@ namespace tgcli {
var prefixlen = GetActualStringWidth(output);
output += TruncateMessageStart(currentInputLine, Console.LargestWindowWidth - GetActualStringWidth(output));
Console.Write(output);
Console.Write($"\u001b[{currentInputPos + prefixlen + 1}G");
Console.Write($"\u001b[{Math.Min(currentInputPos + prefixlen + 1, Console.LargestWindowWidth)}G");
}
}