OmniFocusのフォントサイズを大きくする
OmniFocusでフォントを変更するには.plistファイルを変更する必要がある。
code: omnifocus-fontsize-enlarge.rb
#!/usr/bin/env ruby
require 'json'
require 'plist'
require 'pp'
font_name = 'Ricty'
min_font_size = 14
p = '/Applications/OmniFocus.app/Contents/Resources/OFIFontRegistry.plist'
h = Plist::parse_xml(p)
h'font-name-aliases'.each_key do |k|
h'font-name-aliases'k = font_name
end
h'fixed-styles'.each_key do |k|
if h'fixed-styles'k'font-name' == 'system-font' then
h'fixed-styles'k'font-name' = font_name
end
if h'fixed-styles'k'font-size'.to_i < min_font_size then
h'fixed-styles'k'font-size' = min_font_size.to_s
end
end
s = Plist::Emit.dump(h)
File.write File.expand_path('~/Desktop/OFIFontRegistry.plist'), s