Skip to content

Instantly share code, notes, and snippets.

@9bic
Created December 8, 2014 01:22
Show Gist options
  • Save 9bic/5a3ecc2c9f2e4ef38065 to your computer and use it in GitHub Desktop.
Save 9bic/5a3ecc2c9f2e4ef38065 to your computer and use it in GitHub Desktop.
フォントの英語名を取得する
Add-Type -AssemblyName System.Globalization
Add-Type -AssemblyName System.Drawing
# get en-US Culture ID
$enCultureId = [System.Globalization.CultureInfo]::GetCultureInfo("en-US").LCID
(New-Object System.Drawing.Text.InstalledFontCollection).Families | % { ("{0} - {1}" -f $_.Name, $_.GetName($enCultureId)) }
@9bic
Copy link
Author

9bic commented Dec 8, 2014

Vimで源真ゴシックを楽に指定するために書いたが、源真ゴシックには英語名が存在しなかった

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment