lemonade 0.3.3 → 0.3.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,14 @@
1
1
  Changelog
2
2
  =========
3
3
 
4
+ 0.3.4
5
+ -----
6
+
7
+ * Updated to chunky_png 0.8.0 (PNG color issues have been fixed there)
8
+
9
+
4
10
  0.3.3
11
+ -----
5
12
 
6
13
  * Fixed Rails 3.0 integration (Beta 4)
7
14
 
data/README.md CHANGED
@@ -1,7 +1,10 @@
1
1
  Lemonade—On the fly sprite generator for Sass/Compass
2
2
  =====================================================
3
3
 
4
- Usage ([SCSS or Sass](http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html)):
4
+ Please read my [blog post on CSS sprites for Sass/Compass](http://www.hagenburger.net/BLOG/Lemonade-CSS-Sprites-for-Sass-Compass.html) or have a look at the presentation [3 steps to make better and faster frontends](http://www.slideshare.net/hagenburger/3-steps-to-make-better-faster-frontends) (slides 23—37).
5
+
6
+
7
+ **Usage ([SCSS or Sass](http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html)):**
5
8
 
6
9
  .fanta {
7
10
  background: sprite-image("bottles/fanta.png");
@@ -13,7 +16,7 @@ Usage ([SCSS or Sass](http://sass-lang.com/docs/yardoc/file.SASS_REFERENCE.html)
13
16
  background: sprite-image("cans/coke.png") no-repeat;
14
17
  }
15
18
 
16
- Output (CSS):
19
+ **Output (CSS):**
17
20
 
18
21
  .fanta {
19
22
  background: url('/images/bottles.png');
data/Rakefile CHANGED
@@ -12,7 +12,7 @@ begin
12
12
  gem.authors = ["Nico Hagenburger"]
13
13
  gem.add_dependency "haml", ">= 3.0.0"
14
14
  gem.add_dependency "compass", ">= 0.10.0"
15
- gem.add_dependency "chunky_png", ">= 0.7.3"
15
+ gem.add_dependency "chunky_png", ">= 0.8.0"
16
16
  gem.add_development_dependency "rspec", ">= 1.2.9"
17
17
  end
18
18
  Jeweler::GemcutterTasks.new
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.3
1
+ 0.3.4
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{lemonade}
8
- s.version = "0.3.3"
8
+ s.version = "0.3.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Nico Hagenburger"]
@@ -55,18 +55,18 @@ Gem::Specification.new do |s|
55
55
  if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
56
56
  s.add_runtime_dependency(%q<haml>, [">= 3.0.0"])
57
57
  s.add_runtime_dependency(%q<compass>, [">= 0.10.0"])
58
- s.add_runtime_dependency(%q<chunky_png>, [">= 0.7.3"])
58
+ s.add_runtime_dependency(%q<chunky_png>, [">= 0.8.0"])
59
59
  s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
60
60
  else
61
61
  s.add_dependency(%q<haml>, [">= 3.0.0"])
62
62
  s.add_dependency(%q<compass>, [">= 0.10.0"])
63
- s.add_dependency(%q<chunky_png>, [">= 0.7.3"])
63
+ s.add_dependency(%q<chunky_png>, [">= 0.8.0"])
64
64
  s.add_dependency(%q<rspec>, [">= 1.2.9"])
65
65
  end
66
66
  else
67
67
  s.add_dependency(%q<haml>, [">= 3.0.0"])
68
68
  s.add_dependency(%q<compass>, [">= 0.10.0"])
69
- s.add_dependency(%q<chunky_png>, [">= 0.7.3"])
69
+ s.add_dependency(%q<chunky_png>, [">= 0.8.0"])
70
70
  s.add_dependency(%q<rspec>, [">= 1.2.9"])
71
71
  end
72
72
  end
@@ -8,14 +8,7 @@ module Lemonade
8
8
  file = File.join(Compass.configuration.images_path, image[:file])
9
9
  single_image = ChunkyPNG::Image.from_file(file)
10
10
  x = (sprite[:width] - image[:width]) * image[:x]
11
- # The following line is buggy (too dark anti-aliasing):
12
- # sprite_image.compose single_image, x, image[:y]
13
- # This works as expected:
14
- 0.upto image[:width] - 1 do |xx|
15
- 0.upto image[:height] - 1 do |yy|
16
- sprite_image[x + xx, image[:y] + yy] = single_image[xx, yy]
17
- end
18
- end
11
+ sprite_image.replace single_image, x, image[:y]
19
12
  end
20
13
  file = File.join(Compass.configuration.images_path, "#{ sprite_name }.png")
21
14
  sprite_image.save file
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 3
8
- - 3
9
- version: 0.3.3
8
+ - 4
9
+ version: 0.3.4
10
10
  platform: ruby
11
11
  authors:
12
12
  - Nico Hagenburger
@@ -54,9 +54,9 @@ dependencies:
54
54
  - !ruby/object:Gem::Version
55
55
  segments:
56
56
  - 0
57
- - 7
58
- - 3
59
- version: 0.7.3
57
+ - 8
58
+ - 0
59
+ version: 0.8.0
60
60
  type: :runtime
61
61
  version_requirements: *id003
62
62
  - !ruby/object:Gem::Dependency