showcase: use correct width&height vars

Fixes #179
This commit is contained in:
Andy Meneely
2016-11-15 20:28:22 -05:00
parent e18084d963
commit c9440ec57c
6 changed files with 20 additions and 12 deletions
+5 -1
View File
@@ -52,7 +52,11 @@ module Squib
end
def finish!
@cairo_surface.finish
begin
@cairo_surface.finish
rescue Cairo::SurfaceFinishedError
# do nothin - if it's already finished that's fine
end
end
########################
+1 -1
View File
@@ -33,7 +33,7 @@ module Squib
# :nodoc:
# @api private
def trim_rounded(src, trim, radius)
trim_cc = Cairo::Context.new(Cairo::ImageSurface.new(src.width - 2.0 * trim, src.height - 2.0 * trim))
trim_cc = Cairo::Context.new(Cairo::ImageSurface.new(@width - 2.0 * trim, @height - 2.0 * trim))
trim_cc.rounded_rectangle(0, 0, trim_cc.target.width, trim_cc.target.height, radius, radius)
trim_cc.set_source(src, -1 * trim, -1 * trim)
trim_cc.clip
+1 -1
View File
@@ -6,5 +6,5 @@ module Squib
# Most of the time this is in the alpha of the next release.
# e.g. v0.0.5a is on its way to becoming v0.0.5
#
VERSION = '0.12.0a'
VERSION = '0.12.0b'
end