en/WindowsConsoleFonts-Help.xml
<?xml version="1.0" encoding="utf-8"?>
<helpItems schema="maml" xmlns="http://msh"> <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"> <command:details> <command:name>Add-Font</command:name> <command:verb>Add</command:verb> <command:noun>Font</command:noun> <maml:description> <maml:para>Install a font from a font file (.ttf, .otf, etc) for the current session, even without elevation</maml:para> </maml:description> </command:details> <maml:description> <maml:para>Add-Font allows non-administrator users to install fonts for use within a session. Note that when the system restarts, the font will not be available. To have the font stay installed even after restarting the system, the font must be copied to `${Env:windir}\fonts` and listed in the registry in `HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts` -- which requires elevation.</maml:para> </maml:description> <command:syntax> <command:syntaxItem> <maml:name>Add-Font</maml:name> <command:parameter required="true" variableLength="true" globbing="true" pipelineInput="True (ByPropertyName)" position="0" aliases="PSPath"> <maml:name>Path</maml:name> <maml:Description> <maml:para>The path to the font(s)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:syntaxItem> </command:syntax> <command:parameters> <command:parameter required="true" variableLength="true" globbing="true" pipelineInput="True (ByPropertyName)" position="0" aliases="PSPath"> <maml:name>Path</maml:name> <maml:Description> <maml:para>The path to the font(s)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:parameters> <command:inputTypes> <command:inputType> <dev:type> <maml:name>System.String</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:inputType> </command:inputTypes> <command:returnValues> <command:returnValue> <dev:type> <maml:name>System.Object</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:returnValue> </command:returnValues> <maml:alertSet> <maml:alert> <maml:para></maml:para> </maml:alert> </maml:alertSet> <command:examples> <command:example> <maml:title>-------------------------- Example 1 --------------------------</maml:title> <dev:code>PS C:\> Add-Font .\Fonts\*</dev:code> <dev:remarks> <maml:para>Adds all of the fonts in the Fonts folder to the system temporarily. Note that the WindowsConsoleFonts ships a few of my favorite console fonts in it's Fonts folder!</maml:para> </dev:remarks> </command:example> </command:examples> <command:relatedLinks> <maml:navigationLink> <maml:linkText>Online Version:</maml:linkText> <maml:uri>https://github.com/Jaykul/WindowsConsoleFonts/blob/master/Docs/Add-Font.md</maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Remove-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Set-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Get-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> </command:relatedLinks> </command:command> <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"> <command:details> <command:name>Get-ConsoleFont</command:name> <command:verb>Get</command:verb> <command:noun>ConsoleFont</command:noun> <maml:description> <maml:para>Get the current console font or a list of available console fonts.</maml:para> </maml:description> </command:details> <maml:description> <maml:para>Get the current console font or a list of available console fonts, optionally including TrueType fonts which could be used, even if they wouldn't show up in the console's property dialog.</maml:para> </maml:description> <command:syntax> <command:syntaxItem> <maml:name>Get-ConsoleFont</maml:name> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Extended</maml:name> <maml:Description> <maml:para>Includes fonts where "iii" is the same width as "WWW" -- regardless of whether they are marked FixedPitch or VariablePitch (and even if they are not "Modern" fonts).</maml:para> </maml:Description> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>ListAvailable</maml:name> <maml:Description> <maml:para>List all available fonts. By default this includes monospace fonts which are marked `FixedPitch` and `Modern` (which are the ones which show up in the font dialog).</maml:para> </maml:Description> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> </command:syntaxItem> <command:syntaxItem> <maml:name>Get-ConsoleFont</maml:name> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="0" aliases="none"> <maml:name>Name</maml:name> <maml:Description> <maml:para>Returns available fonts which match the specified name, regardless of whether or not they're monospaced, etc.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:syntaxItem> </command:syntax> <command:parameters> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Extended</maml:name> <maml:Description> <maml:para>Includes fonts where "iii" is the same width as "WWW" -- regardless of whether they are marked FixedPitch or VariablePitch (and even if they are not "Modern" fonts).</maml:para> </maml:Description> <command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>ListAvailable</maml:name> <maml:Description> <maml:para>List all available fonts. By default this includes monospace fonts which are marked `FixedPitch` and `Modern` (which are the ones which show up in the font dialog).</maml:para> </maml:Description> <command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="0" aliases="none"> <maml:name>Name</maml:name> <maml:Description> <maml:para>Returns available fonts which match the specified name, regardless of whether or not they're monospaced, etc.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:parameters> <command:inputTypes> <command:inputType> <dev:type> <maml:name>System.String</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:inputType> </command:inputTypes> <command:returnValues> <command:returnValue> <dev:type> <maml:name>PoshCode.Fonts.FontFamily</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:returnValue> </command:returnValues> <maml:alertSet> <maml:alert> <maml:para></maml:para> </maml:alert> </maml:alertSet> <command:examples> <command:example> <maml:title>-------------------------- Example 1 --------------------------</maml:title> <dev:code>PS C:\> Get-ConsoleFont</dev:code> <dev:remarks> <maml:para>Returns the current console font</maml:para> </dev:remarks> </command:example> <command:example> <maml:title>-------------------------- Example 2 --------------------------</maml:title> <dev:code>PS C:\> Get-ConsoleFont -ListAvailable -Extended</dev:code> <dev:remarks> <maml:para>Lists all of the available fonts which might work as console fonts. That is, if they seem to be monospaced fonts, regardless of having the `Fixed` or `Modern` properties set to true -- which is required to show up in the console property dialog.</maml:para> </dev:remarks> </command:example> <command:example> <maml:title>-------------------------- Example 3 --------------------------</maml:title> <dev:code>PS C:\> Get-ConsoleFont -ListAvailable</dev:code> <dev:remarks> <maml:para>Lists the fonts which would be available in the font dialog (or in tab-completion for Set-ConsoleFont)</maml:para> </dev:remarks> </command:example> </command:examples> <command:relatedLinks> <maml:navigationLink> <maml:linkText>Online Version:</maml:linkText> <maml:uri>https://github.com/Jaykul/WindowsConsoleFonts/blob/master/Docs/Get-ConsoleFont.md</maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Add-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Remove-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Set-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> </command:relatedLinks> </command:command> <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"> <command:details> <command:name>Remove-Font</command:name> <command:verb>Remove</command:verb> <command:noun>Font</command:noun> <maml:description> <maml:para>Removes fonts added by Add-Font</maml:para> </maml:description> </command:details> <maml:description> <maml:para>Removes fonts added by Add-Font. The documentation for AddFontResource (https://docs.microsoft.com/en-us/windows/desktop/api/wingdi/nf-wingdi-addfontresourcea)suggests that any application which adds a font and no longer needs it should remove it -- however, it's not actually necessary unless you want to remove the font file, as the fonts will be removed when your Windows session ends.</maml:para> </maml:description> <command:syntax> <command:syntaxItem> <maml:name>Remove-Font</maml:name> <command:parameter required="true" variableLength="true" globbing="true" pipelineInput="True (ByPropertyName)" position="0" aliases="PSPath"> <maml:name>Path</maml:name> <maml:Description> <maml:para>The path to the font(s)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:syntaxItem> </command:syntax> <command:parameters> <command:parameter required="true" variableLength="true" globbing="true" pipelineInput="True (ByPropertyName)" position="0" aliases="PSPath"> <maml:name>Path</maml:name> <maml:Description> <maml:para>The path to the font(s)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:parameters> <command:inputTypes> <command:inputType> <dev:type> <maml:name>System.String</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:inputType> </command:inputTypes> <command:returnValues> <command:returnValue> <dev:type> <maml:name>System.Object</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:returnValue> </command:returnValues> <maml:alertSet> <maml:alert> <maml:para></maml:para> </maml:alert> </maml:alertSet> <command:examples> <command:example> <maml:title>-------------------------- Example 1 --------------------------</maml:title> <dev:code>PS C:\> Remove-Font .\Fonts\*</dev:code> <dev:remarks> <maml:para>Removes all of the fonts in the Fonts folder.</maml:para> </dev:remarks> </command:example> </command:examples> <command:relatedLinks> <maml:navigationLink> <maml:linkText>Online Version:</maml:linkText> <maml:uri>https://github.com/Jaykul/WindowsConsoleFonts/blob/master/Docs/Remove-Font.md</maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Add-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Set-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Get-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> </command:relatedLinks> </command:command> <command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10" xmlns:MSHelp="http://msdn.microsoft.com/mshelp"> <command:details> <command:name>Set-ConsoleFont</command:name> <command:verb>Set</command:verb> <command:noun>ConsoleFont</command:noun> <maml:description> <maml:para>Sets the font for the current console (including size and weight).</maml:para> </maml:description> </command:details> <maml:description> <maml:para>Sets the font name, size and weight for the console, ignoring the rules! Allows specifying any TrueType font name, even if it's not monospaced.</maml:para> </maml:description> <command:syntax> <command:syntaxItem> <maml:name>Set-ConsoleFont</maml:name> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByPropertyName, ByValue)" position="0" aliases="none"> <maml:name>Name</maml:name> <maml:Description> <maml:para>Specifies a partial font name. Note that Tab Completion here will loop through the fonts which would be available in the Windows Console property dialog.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Bold</maml:name> <maml:Description> <maml:para>Sets the font weight to 700 (on a scale from 100 to 1000).</maml:para> </maml:Description> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Passthru</maml:name> <maml:Description> <maml:para>Output the FontFamily object representing the font that was just set.</maml:para> </maml:Description> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Size</maml:name> <maml:Description> <maml:para>Specifies the font size for TrueType fonts (i.e. try even numbers between 10 and 14)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">Int16</command:parameterValue> <dev:type> <maml:name>Int16</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:syntaxItem> <command:syntaxItem> <maml:name>Set-ConsoleFont</maml:name> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByPropertyName, ByValue)" position="0" aliases="none"> <maml:name>Name</maml:name> <maml:Description> <maml:para>Specifies a partial font name. Note that Tab Completion here will loop through the fonts which would be available in the Windows Console property dialog.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Passthru</maml:name> <maml:Description> <maml:para>Output the FontFamily object representing the font that was just set.</maml:para> </maml:Description> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Size</maml:name> <maml:Description> <maml:para>Specifies the font size for TrueType fonts (i.e. try even numbers between 10 and 14)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">Int16</command:parameterValue> <dev:type> <maml:name>Int16</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Weight</maml:name> <maml:Description> <maml:para>Allows you to manually specify the font weight. Won't work well unless you have the actual weight represented for that font family.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">Int32</command:parameterValue> <dev:type> <maml:name>Int32</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:syntaxItem> </command:syntax> <command:parameters> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Bold</maml:name> <maml:Description> <maml:para>Sets the font weight to 700 (on a scale from 100 to 1000).</maml:para> </maml:Description> <command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="True (ByPropertyName, ByValue)" position="0" aliases="none"> <maml:name>Name</maml:name> <maml:Description> <maml:para>Specifies a partial font name. Note that Tab Completion here will loop through the fonts which would be available in the Windows Console property dialog.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">String</command:parameterValue> <dev:type> <maml:name>String</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Passthru</maml:name> <maml:Description> <maml:para>Output the FontFamily object representing the font that was just set.</maml:para> </maml:Description> <command:parameterValue required="false" variableLength="false">SwitchParameter</command:parameterValue> <dev:type> <maml:name>SwitchParameter</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>False</dev:defaultValue> </command:parameter> <command:parameter required="false" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Size</maml:name> <maml:Description> <maml:para>Specifies the font size for TrueType fonts (i.e. try even numbers between 10 and 14)</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">Int16</command:parameterValue> <dev:type> <maml:name>Int16</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> <command:parameter required="true" variableLength="true" globbing="false" pipelineInput="False" position="named" aliases="none"> <maml:name>Weight</maml:name> <maml:Description> <maml:para>Allows you to manually specify the font weight. Won't work well unless you have the actual weight represented for that font family.</maml:para> </maml:Description> <command:parameterValue required="true" variableLength="false">Int32</command:parameterValue> <dev:type> <maml:name>Int32</maml:name> <maml:uri /> </dev:type> <dev:defaultValue>None</dev:defaultValue> </command:parameter> </command:parameters> <command:inputTypes> <command:inputType> <dev:type> <maml:name>System.String</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:inputType> </command:inputTypes> <command:returnValues> <command:returnValue> <dev:type> <maml:name>PoshCode.Fonts.FontFamily</maml:name> </dev:type> <maml:description> <maml:para></maml:para> </maml:description> </command:returnValue> </command:returnValues> <maml:alertSet> <maml:alert> <maml:para></maml:para> </maml:alert> </maml:alertSet> <command:examples> <command:example> <maml:title>-------------------------- Example 1 --------------------------</maml:title> <dev:code>PS C:\> Set-ConsoleFont "Consolas"</dev:code> <dev:remarks> <maml:para>Sets the current font to Consolas without changing the font size.</maml:para> </dev:remarks> </command:example> <command:example> <maml:title>-------------------------- Example 2 --------------------------</maml:title> <dev:code>PS C:\> Set-ConsoleFont "Fura" -Size 14 -Passthru</dev:code> <dev:remarks> <maml:para>Sets the current font to the first font which matches "Fura" -- probably "FuraCode NF," the Windows Compatible name for the Fira Code font altered by Nerd Fonts to add dozens of icons and shapes like those used in powerline etc.</maml:para> <maml:para>Using the `-Passthru` parameter outputs the new font, which is particularly useful when you're using a partial name, because you tell whether it matched the font name you expected.</maml:para> </dev:remarks> </command:example> </command:examples> <command:relatedLinks> <maml:navigationLink> <maml:linkText>Online Version:</maml:linkText> <maml:uri>https://github.com/Jaykul/WindowsConsoleFonts/blob/master/Docs/Set-ConsoleFont.md</maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Add-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Remove-Font</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> <maml:navigationLink> <maml:linkText>Get-ConsoleFont</maml:linkText> <maml:uri></maml:uri> </maml:navigationLink> </command:relatedLinks> </command:command> </helpItems> |