Class: Utopia::Tags::Gallery::Processes::DocumentThumbnail
- Defined in:
- lib/utopia/tags/gallery.rb
Instance Method Summary collapse
Methods inherited from Thumbnail
Constructor Details
This class inherits a constructor from Utopia::Tags::Gallery::Processes::Thumbnail
Instance Method Details
#call(img) ⇒ Object
62 63 64 65 66 67 68 69 70 71 72 73 74 |
# File 'lib/utopia/tags/gallery.rb', line 62 def call(img) img = super(img) shadow = img.dup shadow = shadow.colorize(1, 1, 1, 'gray50') shadow.background_color = 'transparent' shadow.border!(10, 10, 'transparent') shadow = shadow.gaussian_blur_channel(5, 5, Magick::AlphaChannel) shadow.composite(img, 5, 5, Magick::OverCompositeOp) end |
#default_extension(path) ⇒ Object
76 77 78 |
# File 'lib/utopia/tags/gallery.rb', line 76 def default_extension(path) return "png" end |