Sha256: 1b5955c9523a387186ebf292157ac9958af9de6b8132ee636c42ceb923b723e3
Contents?: true
Size: 678 Bytes
Versions: 30
Compression:
Stored size: 678 Bytes
Contents
#! /usr/local/bin/ruby -w require 'RMagick' imgl = Magick::ImageList.new imgl.new_image(275, 170) { self.background_color = "white" } gc = Magick::Draw.new gc.fill('black') gc.stroke('transparent') gc.font_family('courier') gc.font_weight(Magick::BoldWeight) gc.pointsize(200) # Turn off antialiasing gc.text_antialias(false) gc.text(15, 145, 'A') # Turn it back on gc.text_antialias(true) gc.text(145, 145, 'A') gc.draw(imgl) # Blow up the image so we can # easily see the image, then # crop to a representative portion. imgl.resize!(3).crop!(235,270, 365,180) imgl.page = Magick::Rectangle.new(365, 180) imgl.border!(1,1,"black") imgl.write("text_antialias.gif") exit
Version data entries
30 entries across 30 versions & 1 rubygems