Functions/Private/Convert-Flag.ps1
|
function Convert-Flag { [CmdletBinding()] param ( [Parameter(Mandatory)] [string] $Flag ) switch -CaseSensitive ($Flag) { "b" { $Converted = ";1" } # Bold "f" { $Converted = ";2" } # Dim/Faint "i" { $Converted = ";3" } # Italic "u" { $Converted = ";4" } # Underline "B" { $Converted = ";5" } # Blinking "r" { $Converted = ";7" } # Inverse/Reverse "h" { $Converted = ";8" } # Hidden/Invisible "s" { $Converted = ";9" } # Strikethrough } return $Converted } |