Class: Compass::SassExtensions::Functions::ImageSize::JPEG
- Inherits:
-
Object
- Object
- Compass::SassExtensions::Functions::ImageSize::JPEG
- Defined in:
- lib/compass/sass_extensions/functions/image_size.rb
Instance Attribute Summary collapse
-
#bits ⇒ Object
readonly
Returns the value of attribute bits.
-
#height ⇒ Object
readonly
Returns the value of attribute height.
-
#width ⇒ Object
readonly
Returns the value of attribute width.
Instance Method Summary collapse
-
#initialize(file) ⇒ JPEG
constructor
A new instance of JPEG.
Constructor Details
#initialize(file) ⇒ JPEG
Returns a new instance of JPEG.
72 73 74 75 76 77 78 |
# File 'lib/compass/sass_extensions/functions/image_size.rb', line 72 def initialize(file) if file.kind_of? IO examine(file) else File.open(file, 'rb') { |io| examine(io) } end end |
Instance Attribute Details
#bits ⇒ Object (readonly)
Returns the value of attribute bits.
70 71 72 |
# File 'lib/compass/sass_extensions/functions/image_size.rb', line 70 def bits @bits end |
#height ⇒ Object (readonly)
Returns the value of attribute height.
70 71 72 |
# File 'lib/compass/sass_extensions/functions/image_size.rb', line 70 def height @height end |
#width ⇒ Object (readonly)
Returns the value of attribute width.
70 71 72 |
# File 'lib/compass/sass_extensions/functions/image_size.rb', line 70 def width @width end |