2007年 08月 11日

Cairo で描画


けっこうきれいなんだけど、hennda

fo.antialias         = :gray

してるのにサブピクセルレンダリングされているのはなんでだろ。というか :none にしてもなるし、無視されてる。pango のほうにオプションがあるんだろうか。

layout = context.create_pango_layout
layout.context.set_font_options(fo)

とかやらないとだめ

きれいになった。

RMagick の Pixel#to_color がうまくいかない

hex = color.to_color(Magick::ComplianceType::AllCompliance, false, 8)
test.rb:18:in `to_color': wrong enumeration type - expected Magick::ComplianceType, got Magick::AnchorType (TypeError)
        from test.rb:18