LoginSignup
108
118

More than 5 years have passed since last update.

Windows環境にRictyフォントをインストールする

Last updated at Posted at 2014-07-12

文字の視認性を高めて快適に作業したい

モチベーション

  • 目が悪いので、とにかく文字の視認性を高めたい
    • [0,O],[1,l,I]とか区別つかない
  • 文字幅を揃えたい
    • 矩形選択のときとか等幅になっていると何かと便利

Rictyフォントを入れることにした

  • 世の中にはプログラミング用フォントってのがあって、はじめは「Source Code Pro」を入れてた
  • なんでか忘れたけど、「Ricty」に乗り換えた
  • Rictyフォントはライセンス上の問題で配布はできず、自分で生成しないといけない
  • 生成するのが面倒な人は、「Ricty Diminished」を入れよう
    • ただし、使用可能な漢字グリフが少ないので、漢字によっては表示できない

1. 準備ーとにもかくにも必要なファイルを揃えるところから

1.1 必要なファイルをダウンロードする

    Rictyフォント生成生成スクリプト

  • unofficial fontforge
    • 「fontforge-cygwin_2014_01_04.zip」を使うと有効なフォントファイルが生成できなかったので、旧バージョンの「fontforge-cygwin_2012_08_02.zip」を使った

    unofficial fontforge

    no valid font file

    Inconsolata

    Migu 1M

1.2 ダウンロードしてきたファイルを作業フォルダ(E:\Ricty\)につっこむ

解凍フォルダ 移動対象ファイル、フォルダ
Rictyフォント生成生成スクリプト ricty_generator.sh,ricty_discord_patch.pe,miscフォルダ
unofficial fontforge fontforge.bat,_image.7z,7zr.exe
Inconsolata Inconsolata.otf
Migu 1M migu-1m-regular.ttf,migu-1m-bold.ttf
  • 作業フォルダ(E:\Ricty\)配下はこんな感じ
コマンドプロンプト(cmd.exe)
E:\Ricty>dir /B
7zr.exe
fontforge.bat
Inconsolata.otf
migu-1m-bold.ttf
migu-1m-regular.ttf
misc
ricty_discord_patch.pe
ricty_generator.sh
_image.7z

1.3 fontforge.batの書き換え

  • fontforge.bat内でRictyフォント生成スクリプトを呼び出すようにする

  • 変更前

fontforge.bat
xwin-close.exe -wait
fontforge.exe -nosplash %file0% %1 %2 %3 %4 %5 %6 %7
xwin-close.exe -close
  • 変更後
fontforge.bat
xwin-close.exe -wait
sh ricty_generator.sh auto
sh misc/os2version_reviser.sh Ricty-*.ttf RictyDiscord-*.ttf
xwin-close.exe -close

2. Rictyフォントの生成

  • 書き換えたfontforge.batを実行してしばらく待つ
  • カレントフォルダに4つのフォントファイルが生成される
    • Ricty-Regular.ttf
    • Ricty-Bold.ttf
    • RictyDiscord-Regular.ttf
    • RictyDiscord-Bold.ttf
  • あとはこのフォントファイルをインストールするだけ

3. さらにフォントレンダラのMacTypeを導入しとく

  • MacType
  • 以下に設定ファイルMacType.iniをさらしとく
MacType.ini
[General]
HintingMode=2
AntiAliasMode=0
NormalWeight=3
BoldWeight=2
ItalicSlant=6
EnableKerning=0
GammaMode=0
LcdFilter=2
BolderMode=1
TextTuning=-1
TextTuningR=-1
TextTuningG=-1
TextTuningB=-1
GammaValue=1.4
Contrast=2.0
RenderWeight=1.3
Fontlink=1
HookChildProcesses=1
FontLoader=0
FontSubstitutes=1
Shadow=1,1,1,0x0,0,0x0
MaxBitmap=0
CacheMaxFaces=256
CacheMaxSizes=12554432
CacheMaxBytes=12108864
Name=win7.drk7

[UnloadDll]
fontview.exe
MainType.exe
AxureRP.exe
FontCreator.exe
FontCreator.cn.exe
notecaselauncher.exe
notecase.exe
gnucash-bin.exe
bleachbit.exe
Fontforge_TC.exe
Fontforge_SC.exe
Fontforge_EN.exe
dwm.exe
Fetion.exe
xdict.exe
ollyice.exe
sc2.exe
avgnt.exe
PlantsVsZombies.exe
SynTPHelper.exe
SynTPEnh.exe
war3.exe
SearchFilterHost.exe
SearchProtocolHost.exe
mspdbsrv.exe

[exclude]

[FontSubstitutes]

[Individual]
Consolas=0,4,6,,,
Lucida Grande=0,4,16,12,12,
Verdana=0,4,6,,,
MS Shell Dlg=0,4,6,,,
gHK-ZhongHei=0,4,6,,,

[excludeSub]
javaw.exe
PPLive.exe
QQGame.exe
devenv.exe

[General@chrome.exe]
HintingMode=1
AntiAliasMode=4
FontLoader=1
Fontlink=2
FontSubstitutes=0
NormalWeight=5
BoldWeight=3
RenderWeight=1.7
[MacType]
Language=4
AutoRun=1

108
118
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
108
118