Make sure gears.color.create_png_pattern are being repeated

This commit is contained in:
Emmanuel Lepage Vallee 2014-03-15 18:53:01 -04:00 committed by Uli Schlachter
parent 5fdce4d845
commit 7349f3b902
1 changed files with 3 additions and 1 deletions

View File

@ -71,7 +71,9 @@ function color.create_png_pattern(file)
file = file.file file = file.file
end end
local image = surface.load(file) local image = surface.load(file)
return cairo.Pattern.create_for_surface(image) local pattern = cairo.Pattern.create_for_surface(image)
pattern:set_extend(cairo.Extend.REPEAT)
return pattern
end end
-- Add stops to the given pattern. -- Add stops to the given pattern.