让我们使用powershell命令,Write-Host "red text" -Fore red
该命令在红色前景中显示“红色文本”。
但是,您希望以较浅的字体颜色(浅红色)显示文本。
有没有办法做到这一点,并使用powershell获得RGB光谱中的任何前景色(和背景)?
$PSVersionTable.PSVersion
Major Minor Patch PreReleaseLabel BuildLabel
----- ----- ----- --------------- ----------
7 1 0
(0..256).ForEach{write-host "`e[38;5;$($_)m[$_]"}
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句